Authentication tokens API Resource

DELETE /authtokens

Revoke authentication token

Example of request:

{"token":"existing token"}

Request Body
media type data type
application/json object
Response Body
media type data type description
application/json object JSON Response with information, whether the revoking has or has not been succeeded.

POST /authtokens

Create new authentication token

Example of request:

{"userId":user_id,"context":[list of contexts]}

Request Body
media type data type
application/json object
Response Body
media type data type description
application/json object JSON Response with information, whether the creation has or has not been succeeded.

PUT /authtokens

Update authentication token

Example of request:

{"token":"existing token","userId":user_id,"context":[list of contexts]}

Request Body
media type data type
application/json object
Response Body
media type data type description
application/json object JSON Response with information, whether the updating has or has not been succeeded.

GET /authtokens/json

Get all authentication tokens.

Response Body
media type data type description
application/json object JSON Response with the list of tokens.

Example of response:

{"list":[{"context": [{"name": "Context name","code": context_code}],"userId":user_id,"userFullName":"User Full Name","token":"alphanumeric_token"}]}

GET /authtokens/context/json

Get all possible contexts for authentication tokens.

Response Body
media type data type description
application/json object JSON Response with the list of contexts with possible endpoints.

Example of response:

{list: [{"code": 1,"name": "contextName1"},{"code":2,"name":"contextName2"}]}