v1

latestOpenAPI 3.0.02026-07-14135106116.2 KB
auth

Create a new JWT Token

This endpoint is deprecated : use /auth/ephemeral and /auth/token instead

This endpoint requires authentication and requires the user to have the role edit_users: you can then request a JWT on behalf of another user, specified in the request username attribute.

This endpoint has 2 modes depending on the presence or absence of the roles attribute in the request data:

Regular token

When sending only a username: a regular JWT Token bound to the given user is created and returned.

Temporary token

When sending username AND a list roles of role (defined by the UID, optional the inbox to restrict access to): a temporary token is created that will behave like a regular user with the given roles until the access token expires.

Permission required: edit_users

post/auth/get_JWT

Headers

X-Fieldsstring mask

An optional fields mask

Request body

usernamestring required

the user username

Example request

{
  "roles": [
    {
      "inbox": "abcdef123456789abcdef123",
      "role": "abcdef123456789abcdef123"
    }
  ]
}

Response

Success

authentication_tokenstring required