# README
Token-Service Example
This example illustrates how Dockpit can help in development of an idomatic microservices. The token-service has the following behaviour:
- It returns access tokens over HTTP to users who are able to authenticate using their username and password.
- In order to do so, the service will need to retrieve data from a PostgreSQL database.
- The location of the database instance will need to be retrieved from the etcd service registry
- New accounts are created by another service in the system, upon creation the token-service will receive a new message on a NSQ message queue, after which a new token is generated for this user.
- The returned token also contains permission data, these permissions are fetched through the HTTP API of another microservice in the system.