Colyon Logo

Auth Token

POSThttps://api.monchain.ai/p/uss/api/v1/oauth2/token

Exchange client credentials for a short-lived bearer token.

Header parameters

Content-Type | string · requiredForm data encoding for OAuth2 token exchangee.g. application/x-www-form-urlencoded
x-api-key | string · requiredMonchain-issued API key authorizing this cliente.g. 92af4fee-e027-491a-bc95-8463e89a9cd8

Request body

grant_type | string · requiredOAuth2 grant type (only client_credentials)e.g. client_credentials
client_id | string · requiredMonchain org client identifiere.g. 55d3ce65-1f76-454b-ac4e-23617978131e
client_secret | string · requiredConfidential client secret issued to your orge.g. e255f998b4405cb6dc3a8bfec06de72c
scope | string · requiredSpace-delimited scopes enabling auth capabilitiese.g. client:read client:write

Responses

200Token issued
Client credentials valid and scopes authorized
access_token· string· required

Short-lived bearer token for downstream calls

e.g. eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9...

refresh_token· string· required

Long-lived token used to mint a new access token

expires_in· integer· optional

Token lifetime in seconds

e.g. 300

scope· string· optional

Scopes granted on this token

token_type· optional

Always Bearer

400Malformed request
Missing parameters or invalid scope
status· integer· required

HTTP status code returned by the API

message· string· required

Human-readable error details

path· string | null· optional

Request path that triggered the error

timestamp· string· required

UTC timestamp for when the error occurred

401Authentication failed
Invalid client secret or API key
status· integer· required

HTTP status code returned by the API

message· string· required

Human-readable error details

path· string | null· optional

Request path that triggered the error

timestamp· string· required

UTC timestamp for when the error occurred

429Rate limited
Too many token exchanges
status· integer· required

HTTP status code returned by the API

message· string· required

Human-readable error details

path· string | null· optional

Request path that triggered the error

timestamp· string· required

UTC timestamp for when the error occurred