mirror of
https://github.com/glimpse-app/server.git
synced 2025-04-02 10:52:45 -04:00
api documentation will be done in comments not here
This commit is contained in:
parent
7e3ba5abd9
commit
d7c2314733
1 changed files with 3 additions and 10 deletions
13
README.md
13
README.md
|
@ -18,20 +18,13 @@ nimble run --verbose -d:normDebug
|
||||||
|
|
||||||
## API Endpoints
|
## API Endpoints
|
||||||
|
|
||||||
### /api/register
|
Each endpoint has comments describing what type of request it is and what parameters it takes.
|
||||||
|
Example requests using `cURL`:
|
||||||
Arguments required: `username` `password`
|
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
curl -s -X POST http://localhost:5000/api/register -d 'username=Array' -d 'password=i8Vl8XZaVRiZFsZ'
|
curl -s -X POST http://localhost:5000/api/register -d 'username=Array' -d 'password=i8Vl8XZaVRiZFsZ'
|
||||||
```
|
```
|
||||||
|
|
||||||
### /api/upload
|
|
||||||
|
|
||||||
Arguments required: `file` `token`
|
|
||||||
|
|
||||||
Example:
|
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
curl -i -X POST -H "Content-Type: multipart/form-data" -F "file=@image.png" -F "token=SkNaeltRR2RPS3FXTUlvVkdBZ154S3Bjam5iZllkWnlxeVN3cUtfTVQ=" http://localhost:5000/api/upload
|
curl -s -X POST -H "Content-Type: multipart/form-data" -F "file=@image.png" -F "token=<some long hash here>" http://localhost:5000/api/upload
|
||||||
```
|
```
|
||||||
|
|
Loading…
Add table
Reference in a new issue