An open API service indexing awesome lists of open source software.

https://github.com/cartesiancs-dev/devent-imageserver

NodeJS Image Server API
https://github.com/cartesiancs-dev/devent-imageserver

Last synced: 3 months ago
JSON representation

NodeJS Image Server API

Awesome Lists containing this project

README

          

![head](./head.png)

# devent-imageserver
이미지 서버

## To-Do

* [x] 이미지 업로드
* [x] 업로드 제한
* [ ] 사용자 권한에 따른 업로드 제한
* [x] 도커 배포 적용
* [x] 이미지 파일 리스트 출력

## 실행

**의존성 설치**

```
npm install
```
**실행**

```
npm run start
```

## 요청

post /api/images

**Headers**

| Key | Value | Description |
| --- | --- | --- |
| x-access-token | {{JWT TOKEN}} | registration.js의 콜백주소로 요청될 토큰 |

**Body**

| Key | Value | Description |
| --- | --- | --- |
| image | {{FROM DATA}} | 폼 데이터 이미지 파일 |

## 응답

**성공 (예시)**


{
"status": 1,
"filename": "1644997335705.png",
"filesize": 184914
}

**실패**


{
"status": 0
}

## 파일 주소

```
http://host.host/file/{filename}
```