Refresh Maya Mini App Token

POST https://op-sandbox.paymaya.com/tokens


This API endpoint uses Bearer Authentication, which relies on the Client Credentials Token (access_token) generated during OAuth 2.0 Authentication using the client_credentials grant type. You must provide this token as part of the Authorization header.

--header Authorization: Bearer <access_token>

Recipes


Technical Guide:

Related Guide:


Request Payload

Request Header

AttributeTypeFormatDescription
Accept REQUIREDstringapplication/json
Content-Type REQUIREDstringapplication/jsonSpecifies the media type of the request
Request-Reference-No REQUIREDstringUUIDv4Unique reference identifier for tracking the request
Authorization REQUIREDstringJWSThe Client Credentials Token (access_token) generated by Maya during OAuth 2.0 Authentication using the client_credentials grant type

Example: Bearer {access_token}

Request Body

AttributeTypeFormatDescription
refreshToken REQUIREDstringapplication/jsonThe valid Customer Refresh Token obtained from Maya through either your session URL or acquired by refreshing the tokens , whichever is the most recent or valid value

Response Payload

Response Body

AttributeTypeFormatDescription
accessToken REQUIREDstringJWEThe Customer Access Token; Your application should store this securely while also considering the expiration
refreshToken REQUIREDstringJWTToken for getting a new access token; Your application should store this securely while also considering the expiration
expiresAt REQUIREDintegerTimestamp of the session expiration, in seconds since the epoch (UNIX timestamp)