regenerate

Available Since: V1

Regenerate the authentication token, this has the effect of logging the user out of locations other than the calling location. 

Request

POST api/1/user/regenerate/
Parameter Description
uid The user ID to regenerate the authentication token for, this is the uid returned from the authenticate method.

Successful Response (200)

{
	"uid": "1",
	"username": "theuser",
	"email": "user@example.com",
	"tz": "Australia/Perth",
	"token": "ffcc6bf60959c373589938cdc493de2b",
	"authState": 1
}
Parameter Description
uid The ID of the user within the system.
username The username of the user.
email The users email address.
tz The users timezone.
token The authentication token which is used with the validate method.
authState The authentication state:
  • 0 - Unknown.
  • 1 - Ok.
  • 2 - Bad username or password.
  • 3 - Failed.
  • 4 - The client IP has been blocked for too many failed attempts.
  • 5 - User pending activation.
  • 6 - Disabled
  • 7 - Blocked

Unsuccessful Response (400)

{
	"authState": 2
}
Parameter Description
authState The authentication state:
  • 0 - Unknown.
  • 1 - Ok.
  • 2 - Bad username or password.
  • 3 - Failed.
  • 4 - The client IP has been blocked for too many failed attempts.
  • 5 - User pending activation.
  • 6 - Disabled
  • 7 - Blocked



TOP