- POST /v1/signup
{
"username": "gvolpe",
"email": "gvolpe@github.com",
"password": "123456" // optional
}
- GET /v1/users
- GET /v1/users/{id}
- PATCH /v1/users/{id}
{
"email": "gvolpe@gmail.com"
}
- PATCH /v1/users/{id}
{
"password: "gvolpe@gmail.com"
}
- POST /v1/users/{id}/forgotpassword
- POST /v1/signin
{
"username": "gvolpe",
"password": "123456"
}
Requires Authentication (/v1/signin)
- GET /v1/admin/users
- DELETE /v1/admin/users/{id}
- POST /v1/admin/users/{id}/block
- POST /v1/admin/users/{id}/unblock
For the sake of simplicity in this example the user with username = "gvolpe" and password = "" will be the only one authenticated as an administrator. Any other user will not be authorized to perform requests that require authentication.
Start the server by executing sbt run
. The server will be listening at http://localhost:8080.