⚠️ DISCLAIMER: This project isdevelopment only
version, it won't be deployed to any production environment. Thus, any sensitive data may freely live in the repo.
Simple web application, which has a single endpoint, dedicated to annotation parsing and conversion.
- Easiest way if you have
docker
anddocker-compose
installed is to runmake
command, which will run the docker container at the background:
make start
Server will be available at http://0.0.0.0:5000/
- Similarly, server can be stopped with another
make
command:
make stop
- Use any API tool/platform of your chose.
- While application running, make a
POST
request:- endpoint:
http://0.0.0.0:5000/export
- auth: Basic. Username:
myUser123
, Password:secretSecret
- send raw json body:
{ "annotation_id": 9142612, "queue_id": 136373 }
- endpoint:
Complete CURL command
curl --location --request POST 'http://0.0.0.0:5000/export' \ --header 'Authorization: Basic bXlVc2VyMTIzOnNlY3JldFNlY3JldA==' \ --header 'Content-Type: application/json' \ --data-raw '{ "annotation_id": 9142612, "queue_id": 136373 }'
- Should return following json response:
{
"success": true
}
- Python3.9
- docker and docker-compose
- make
Run tests from the root folder with pytest --cov
command.
This project uses none, since it is not required by the task.