Description

Use this API to register a new user. It needs a JSON containing at least two fields: username and password (optionally you can pass it firstName and lastName). It will return a JSON message containing the registration confirmation with the access_token and the refresh_token or an error message.

Example Query

POST Query URI
http://danteweb.lnf.infn.it:8000/auth/registration


POST Query Payload
{
	"username": "myUser",
	"password": "myPassword",
	"firstName": "Name",
	"lastName": "Surname"
}


API Response
{
	"message": "User myUser was created",
	"access_token": "eyJ0eXAiOiJKV1QiLCJhbGci...ES42k",
	"refresh_token": "eyJ0eXAiOi...5yN6zUM8tQ"
}
  • No labels