Manage Tokenizations API
Use Case
This API is used to manage a tokenizations.
CANCEL: The tokenization cannot be restored after it has been cancelled.
DEACTIVE: The tokenization can be restored after it has been cancelled.
ACTIVE: used to active token after Deactive.
Request
POST/v2/tokenizations/manage
| Parameter | Type | Required | Description |
|---|---|---|---|
| merchantId | Fundiin provides MID as a unique identifier to each merchant. | ||
| referenceId | The reference id send in API Confirm Tokenizations. | ||
| tokenization | user tokenization want to cancel | ||
| merchantUserId | merchantUserId want to cancel | ||
| requestType | CANCEL, DEACTIVE, ACTIVE | ||
| lang | Language of returned message (vi or en) |
Example Request
{
"merchantId": "Your merchant code",
"referenceId": "Your order number",
"tokenization": "Your token",
"requestType": "CANCEL",
"merchantUserId": "merchantUserId",
"lang": "vi",
}
Response
| Parameter | Type | Required | Description |
|---|---|---|---|
| merchantId | Fundiin provides MID as a unique identifier to each merchant. | ||
| referenceId | The reference id send in API Confirm Tokenizations. | ||
| responseTime | Date & Time of response: Format: YYYY-MM-DD hh:mm:ss | ||
| resultStatus | Result Status | ||
| resultMsg | The result message which contains information about the result. |
{
"merchantId": "FundiinVN",
"referenceId": "Your order number",
"responseTime": 1689315609,
"resultMsg": "Thành công",
"resultStatus": "APPROVED"
}
Result Status & Messages
| Status code | Description | Action to take |
|---|---|---|
| APPROVED | Cancel transaction was approved | |
| ACCESS_DENIED | Access denied. | Please check your settings in merchant portal, or contact Fundiin for configurations. |
| INVALID_TOKEN | The token is invalid. | Please provide a valid token. |
| INVALID_MERCHANT_USER_ID | The merchantUserId is required | Please send Fundiin merchantUserId because this is required, or verify the user's linking status. |
| INVALID_REQUEST | Invalid request. e.g. Invalid merchantUserId etc. | |
| INVALID_REFERENCE_ID | The referenceId is invalid | Please provide a valid referenceId. |
| INVALID_CLIENT_ID | The cliendId is not registered | |
| INVALID_SIGNATURE | The signature is invalid. | |
| INVALID_MERCHANT_ID | The merchant is not registered. | |
| INVALID_HTTP_METHOD | The server does not implement the requested HTTPS method. | |
| INVALID_API | API is not defined. | Check whether the request URL is correct. Ensure that the endpoint of the called API is correct. |
| STATUS_UNCHANGED | The status is already set to the requested value. | Please provide a different status value. |
| REQUEST_PROCESSING | The request already processed or in progress | |
| DOWNSTREAM_ERROR | Partner downstream timeout. (Retriable) | |
| ERROR_GENERAL | Declined due to general reasons other than the specific decline error codes provided. |