master
Chakib Benziane 5 years ago
parent 7e416ad8c2
commit 88ede6fa65

@ -47,3 +47,30 @@ The go server will be find in the server folder. To Run it use:
> make
> ./bit4sat
```
## API
These are the currently available API endpoints:
- `POST` on `/upload`:
Accept a form with content type `application/json` with following structure:
``` json
{
"files": {
"name": "this is the name/path of file (required)",
"size": "size of file (not required)",
"sha256": "sha256 (not required)"
},
"timestamp": "timestamp as in Date().toJSON() in js"
}
```
Example API call:
``` bash
curl -sX POST \ Fri 19:10
--header 'content-type: application/json' 'localhost:8880/upload/' \
--data '{"files":[], "timestamp": "2012-04-23T18:25:43.511Z" }'
```

@ -1 +1 @@
Subproject commit e449299304a972916662b67a2cec98f9f5156e87
Subproject commit 0515af012932878cd637bb7b9ee871f263cf4359
Loading…
Cancel
Save