Authentication & Tokens

Vixzz uses OAuth 2.0 client credentials. Separate tokens must be requested for C2B collections and B2C disbursements. Tokens expire after 3,600 seconds (1 hour).

POST/v1/oauth2/tokenLive & Sandbox

Request Headers

HeaderTypeStatusDescription
AuthorizationstringRequiredBasic <base64(consumer_key:consumer_secret)>
Content-TypestringRequiredapplication/json

Body Parameters (JSON)

ParameterTypeStatusDescription
grantTypestringRequiredOAuth grant type. Set to client_credentials.
businessKeystringConditionalYour registered business key (e.g. bz_live_882190). Required for B2C disbursement and float management tokens.

Request Code Snippets (cURL, Node, Python, PHP, Go)

C2B Token Request
curl -X POST https://developer.vixzz.com/v1/oauth2/token \
  -H "Authorization: Basic Base64(C2B_Consumer_Key:C2B_Secret_Key)" \
  -H "Content-Type: application/json" \
  -d '{
    "grantType": "client_credentials"
  }'

JSON Return Response Body (200 OK)

C2B Token Response
{
  "accessToken": "vxz_tok_c2b_8f9k3m9s2a1l",
  "tokenType": "Bearer",
  "expiresIn": 3600,
  "scope": "c2b.collect"
}
B2C Token Request
curl -X POST https://developer.vixzz.com/v1/oauth2/token \
  -H "Authorization: Basic Base64(B2C_Consumer_Key:B2C_Secret_Key)" \
  -H "Content-Type: application/json" \
  -d '{
    "grantType": "client_credentials",
    "businessKey": "bz_live_your_business_key"
  }'
B2C Token Response
{
  "accessToken": "vxz_tok_b2c_0a5l1n3m8x2z",
  "tokenType": "Bearer",
  "expiresIn": 3600,
  "scope": "b2c.payout"
}