Authentication - Generate Access Token

To begin the authentication process, you need to first issue an Access Token. This token will authenticate your requests to our API.

Once the Access Token is generated, store it securely in a Redis cache or your database, and reuse this token for each API request instead of generating a new one every time.

Make sure to use the OAuth URL provided by your Account Executive to ensure proper access to the API.

Below is the API documentation for generating an Access Token:

Issue Access Token

POST/oauth/token

This endpoint allows you to generate an Access Token that will be used to authenticate your API requests.

Headers

Name
Value

Accept

application/json

Body

Name
Type
Description

grant_type

string

Type of authentication grant. Use password to authenticate with a username and password.

client_id

string

Unique identifier of client

client_secret

string

Secret Key of client

username

string

The username of the account accessing the API.

password

string

The password of the account accessing the API.

Response

{
    "token_type": "Bearer",
    "expires_in": 2592000,
    "access_token": "eyJ0eXAiOiJKV1QiLCJhbGciOiJSUzI1NiIsImp0aSI6Ijc1ZjQwOTA3NmQ5MTI0NGNkM2NiYzUyMzhkNjdiZTNiYmIxNzJjMjcwZTk4ZDk2MDRlZDg2OWE2ZmJkZmVmNzNkNmRhMWFkOWMxNGMwNDk2In0.eyJhdWQiOiIzIiwianRpIjoiNzVmNDA5MDc2ZDkxMjQ0Y2QzY2JjNTIzOGQ2N2JlM2JiYjE3MmMyNzBlOThkOTYwNGVkODY5YTZmYmRmZWY3M2Q2ZGExYWQ5YzE0YzA0OTYiLCJpYXQiOjE1MjMwMDM1ODEsIm5iZiI6MTUyMzAwMzU4MSwiZXhwIjoxNTI1NTk1NTgxLCJzdWIiOiIxIiwic2NvcGVzIjpbXX0.ebKevmVUAyv_USlyUN94ptv5w0WSel5taf0rqKliI6EW1dI4whKXNx6El9rpj0lzuilWbDQHbmZansyR4_e7QbmoNrCUAu4IrgsK48TxA2OC-DyYvEWXrw4fJvt6aA-dGjw2wDqpcBZ_6cc_mfLaHafrfjP9gDEYjnVQJedT4ltdQtN6BAoC8XB18dY1LC_uBLWmYpkDUK_erO7ZG1pQO-68NB72tN-8k70rzR1mvybJju6HfS1HKsM42MuTxS4D3yJPWrtvCEIrnWcHjy35lHoiHGpv-v3fuuxrCCyPqPnjX9KfNTGhFxGvpab-ceeDfz49TBJJbYgJ9mCyNdVMkSwrQN5irmGBXabjGQPO1fs3SsLqNnjOqRLWokPhm1m_f_SfoJ0_1AVxky8gKvkp-PUIMOmFZdsUhmOUeILV44aZukpSyAQMQOWZeADVIEKZoGjYo_9h673OeuXf0B2Umcx777qHi5gXe0fbD8TktMZJK3hgDCGVvmOmeJ0gQsMylgfX_mzrJJ2cDxf-AyZGXSQPAv2tIO52RRqBvBRRbak7VPnAKm43Q0-Zyh5VVusirxjeTZICh-o-ZaQQyySQ7N9AQt0ejFWNry2E3XbDe6tSiVu1u5NdTdtltYtfBWGS5nVTcEAC4ViuhiKdQJ76SsMfghTEiuKSE04vDEBwX_s",
    "refresh_token": "def50200aea9e9a7e3a68600f34e2abe5eb89dbe3a71b0bddf833d099c075a8db8f483a95d1fff2f17d6962a2e8b1daf236ea62a563f28983ef6a0a85c3f8a00d9b2b0013a89dac7e66f724e20fd1774d368ea53b2774e4a789042bdc18daebf4ba7570bfa4c9d57f4fcb06d19f2945eb50ae8b71e7b4240010ccb457edbfb5b23e40651e5b972a0306378e26cec0f3cabc4636d11925e0cd3f24678fe39c062d96c63f71d38c76b2c0a3415600106fe54792ed018104710b46538fac2cefd5d4ae0cd4c8a07514c3658601d8c99e8f6b1d037c89f416ea006a24c1d7eb7debc9f98a8de2ad54602161e44d0e0b6f2da289da6b82b3f50dd708a3ee42bc37e4e749234854be866ce1e824d173ce4c74ead1ec92778cc29dc17b852c9112fd226fccb2f8f13f2a376e6dd747be26f3958011340db4a4e38882b06d90d51b1e7dff94163313292c437e5306eac44464581b4f0319bd2cd605c23a945cd1bb5227aa8"
}

Once you have obtained the token, you can proceed to the next step, where we will cover how to handle Access Token expiration.

Last updated