You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

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).

Example Query

http://danteweb.lnf.infn.it:8000/auth/registration

JSON PAYLOAD:

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

It will return a JSON message containing the registration confirmation with the access_token and the refresh_token or an error message.

{
	"message": "User myUser was created",
	"access_token": "eyJ0eXAiOiJKV1QiLCJhbGci...ES42k",
	"refresh_token": "eyJ0eXAiOi...5yN6zUM8tQ"
}


  • No labels