Skip to main content

3. Get an access token

Use the authorization response code you got in step 2 to retrieve an access token as this user. Note: you're now acting on behalf of this user, using their access token.

POST /oauth/token#

info

As opposed to other API endpoints, the /oauth ones are not in the /api/v2 namespace, but on the /backend level directly. So please use this as your full url:

https://[env].convela.cloud/backend/oauth/token

Body#

parameterRequiredvalue
codeyescode you received in step 2
client_idyeswhich we passed to you
client_secretyeswhich we passed to you
grant_typeyesauthorization_code

Response#

{  "token_type": "Bearer",  "expires_in": 2591999,  "access_token": "eyJ0eXAmpcflwfUY6h7...rSJ7KnfGDTCciu4ASE",  "refresh_token": "def502001bab181ef9...b5c7cfvd27f66ce754e"}