Simple HTTP API for playing with User
model.
base.py
: base of all models of the API - handle serialization to fileuser.py
: user model
app.py
: entry point of the APIviews/index.py
: basic endpoints of the API:/status
and/stats
views/users.py
: all users endpoints
$ pip3 install -r requirements.txt
$ API_HOST=0.0.0.0 API_PORT=5000 python3 -m api.v1.app
GET /api/v1/status
: returns the status of the APIGET /api/v1/stats
: returns some stats of the APIGET /api/v1/users
: returns the list of usersGET /api/v1/users/:id
: returns an user based on the IDDELETE /api/v1/users/:id
: deletes an user based on the IDPOST /api/v1/users
: creates a new user (JSON parameters:email
,password
,last_name
(optional) andfirst_name
(optional))PUT /api/v1/users/:id
: updates an user based on the ID (JSON parameters:last_name
andfirst_name
)