POST
/
token
Obter access token
curl --request POST \
  --url https://sandbox.api.faciconnect.com/token \
  --header 'Authorization: Basic <encoded-value>' \
  --header 'Content-Type: application/x-www-form-urlencoded' \
  --data grant_type=client_credentials \
  --data validity_period=3600
{
  "access_token": "eyJhbGciOiJSUzI1NiIsInR5cCI6...",
  "token_type": "Bearer",
  "expires_in": 3600
}

Autorizações

Authorization
string
header
obrigatório

base64(clientId:clientSecret)

Corpo

application/x-www-form-urlencoded
grant_type
enum<string>
obrigatório
Opções disponíveis:
client_credentials
Exemplo:

"client_credentials"

validity_period
integer

Validade do token em segundos.

Exemplo:

3600

Resposta

Token emitido com sucesso.

access_token
string
obrigatório
Exemplo:

"eyJhbGciOiJSUzI1NiIsInR5cCI6..."

token_type
string
Exemplo:

"Bearer"

expires_in
integer
Exemplo:

3600