CRM Open API DocumentationCRM Open API Documentation
REST API
Webhooks
Client OAuth
PSP Open API
External Exchange Rates
REST API
Webhooks
Client OAuth
PSP Open API
External Exchange Rates
  • Client OAuth Flow
  • OAuth Applications
  • Authorization Code + PKCE

    • Authorization Code + PKCE Introduction
    • Redirect to Login
    • Get Token
    • Compute PKCE Code Challenge
  • Resource Owner Password Credentials (ROPC)

    • ROPC Introduction
    • Get Token
    • Verify MFA Code
    • Get MFA Secret
    • Send Email OTP for MFA
    • Bind MFA Method and enable MFA

Get Token by Authorization Code (PKCE)

POST {Client API Hostname}/oauth/token

Basic Authorization (retrieve credentials from OAuth Application)

  • Username: OAuth Client ID
  • Password: OAuth Client Secret
  • HTTP header: Authorization: Basic base64(client_id:client_secret)

Request Body

KeyTypeRequiredRuleDescription
grant_typestringMandatorymust be authorization_codeOAuth grant type
codestringMandatoryAuthorization code received from the Redirect to Login step
code_verifierstringMandatoryOriginal random string used to compute code_challenge

Expected HTTP status code

  • 200

Response

NameTypeDescription
access_tokenstringBearer access token
token_typestringAlways Bearer
expires_innumberToken lifetime in seconds
refresh_tokenstringRefresh token

Error

Codeerrorerror_description
400invalid_grantinvalid grant type
400invalid_grantAuthorization code is invalid or does not exist
400invalid_grantAuthorization code has expired
400invalid_grantCode verifier does not match code challenge
Last Updated: 10/28/25, 2:41 AM
Prev
Redirect to Login
Next
Compute PKCE Code Challenge