Getting Started
OAuth2

Endpoint to exchange tokens in the Authorization Code, Assertion Flow, Client Credentials and Refresh Token flows.

For backward compatibility, this endpoint returns 400 with invalid_grant in some cases where RFC 6749 would use invalid_client (invalid client credentials) or unauthorized_client (the integration is not allowed to use the grant type). Use error_description to tell these cases apart.

Authentication

This endpoint requires the following token type:

  • Basic authentication (BasicAuth) — using the CLIENT_ID as login and the CLIENT_SECRET as password. See Authentication for partners.
post/auth/oauth2/token

Request

  • Base URL: https://gateway.remote.com
  • URL: https://gateway.remote.com/auth/oauth2/token
  • Auth: HTTP basic

Request body

OR
OR
OR

Example request

{
  "code": "eyJhbG...xb6H0",
  "grant_type": "authorization_code"
}

Response

Success

OR
OR

Example response

{
  "access_token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.cThIIoDvwdueQB468K5xDc5633seEFoqwxjF_xSJyQQ",
  "company_id": "6e60f5f9-e6a6-4b04-b13c-84bced848bab",
  "expires_in": 7200,
  "refresh_token": "b480036a-d229-49ef-a606-7e8fba58a5eb",
  "token_type": "Bearer",
  "user_id": "6550e536-8655-4bce-8bd9-b295f786ad71"
}

Changes