Skip to main content
POST
/
auth
/
dev
/
token
Emite JWT local para desenvolvimento/teste
curl --request POST \
  --url http://localhost:3000/auth/dev/token \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "auth0Sub": "auth0|admin-user",
  "expiresInSeconds": 3600
}
'
{
  "accessToken": "<string>",
  "tokenType": "<string>",
  "expiresIn": 123,
  "user": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "tenantId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "accountId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "role": "ADMIN",
    "email": "<string>"
  },
  "idToken": "<string>",
  "refreshToken": "<string>",
  "scope": "<string>"
}
Disponivel apenas em ambientes development e test quando JWT_SECRET esta configurado.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
auth0Sub
string
required

Subject (sub) do usuário local cadastrado na tabela user

Example:

"auth0|admin-user"

expiresInSeconds
number

Tempo de expiração do JWT em segundos (padrão: 3600)

Example:

3600

Response

JWT local emitido com sucesso

accessToken
string
required
tokenType
string
required
expiresIn
number
required
user
object
required
idToken
string
refreshToken
string
scope
string