Result Notification
- Endpoint:
POST /collectResultNotifyUrl - Tags: Collection Service
Description
After the payment is completed, PayerMax will send the payment result to the merchant in the form of a data stream. The merchant needs to receive and process it and return the response according to the document specification. It is not necessary to actively requested this address for the merchant. The following request.body is the callback content of payermax for the order status. The merchant needs to respond {"msg": "Success","code": "SUCCESS"} after receiving the callback.
Parameters
| Field | In | Type | Required | Constraints | Description |
|---|---|---|---|---|---|
Content-Type | header | string | Yes | ||
sign | header | string | Yes | 签名信息请参考技术文档 |
Parameter Examples
Content-Type:"application/json"sign:"FPFVT3o227JrFRbqu19boZCpVVTF9KznxyRawUmxpfXilHV/0yK46haPhAjNu1hPUMy7Vw/ILXhfzffNm4Fj0apWknlTY9OJxnSoQxS9BTFtc61tn5yV1q69x/kkBl82/qwg+XTJ4fOzy7Mar3VaC1E2PlDA6RkkKBUyNE6RYgsdB+Su7an4+4HVTNAnoe74WyvBgxTLMNg28igBTdqxaO3w/UBY6ObVp7vkqkQGdL1Y+HgmMYaAVwrM3+ALWGId0sJ+YqTY4WJ+0xCRGhaSnybiIjZsQEYyID68WNUfuavDLDsEhaMm/HfQvf5p0R1Ltovp3wwJnEbQcjY458iX5A=="
Request Body
Content-Type: application/json
| Field | Type | Required | Constraints | Description | Enum |
|---|---|---|---|---|---|
code | string | Yes | maxLength: 32 | Return Code. When the transaction is successful, code: APPLY_SUCCESS and status: SUCCESS; If the transaction fails, the code will return a transaction failure error code and the status is FAILED or CLOSED. | |
keyVersion | string | Yes | Signature Algorithm Version, Current value: 1 | ||
appId | string | Yes | Merchant AppId,The unique identifier assigned to the merchant app by PayerMax | ||
merchantNo | string | No | maxLength: 32 | Merchant Id, the unique identifier generated when the merchant signs the contract with PayerMax | |
msg | string | Yes | maxLength: 256 | Return Message. When the transaction is successful, msg:Success. and status: SUCCESS; If the transaction fails, msg will return the transaction failure error msg and the status is FAILED or CLOSED. | |
notifyTime | string | Yes | maxLength: 32 | Notification time,Compliant with rfc3339 specification, format:yyyy-MM-dd’T’HH:mm:ss.SSSXXX | |
notifyType | string | Yes | maxLength: 16 | Notification Type PAYMENT | |
data | object | Yes | Notify data body | ||
data.outTradeNo | string | Yes | maxLength: 64 | Merchant order id | |
data.tradeToken | string | Yes | maxLength: 64 | PayerMax order id | |
data.totalAmount | number | Yes | The order amount sent by the merchant. The unit of the amount is yuan, and it is returned according to the decimal point supported by the currency of each country. | ||
data.currency | string | Yes | maxLength: 3 | Order Currency | |
data.country | string | No | maxLength: 2 | The country code the user paid for, in capital letters | |
data.status | string | Yes | maxLength: 32 | Transaction Status | SUCCESS, FAILED, CLOSED |
data.completeTime | string | Yes | Complete Time | ||
data.paymentDetails | array[object] | No | Payment Details | ||
data.paymentDetails[].paymentMethodType | string | Yes | maxLength: 16 | The payment method type selected by the user for payment, which will only be returned if the transaction is successful | |
data.paymentDetails[].targetOrg | string | No | maxLength: 32 | The target organisation chosen by the user, which will only be returned if the transaction is successful.When the payment method is CARD, see card information | |
data.paymentDetails[].cardInfo | object | No | Card Info (If you need to return, please contact the technical support.) | ||
data.paymentDetails[].cardInfo.cardOrg | string | No | maxLength: 32 | Card Scheme, will return when the user chooses card scheme to pay | |
data.paymentDetails[].cardInfo.country | string | No | maxLength: 2 | Card issuing country | |
data.paymentDetails[].cardInfo.cardType | string | No | maxLength: 32 | Card funding type, such as DEBIT、CREDIT and so on. | |
data.paymentDetails[].cardInfo.totalCardOrg | array[string] | No | Brand of the card.Dual-standard card returns two brands. | ||
data.paymentDetails[].cardInfo.type | string | No | maxLength: 32 | Type of the card. PAN is a full pan; NETWORK_TOKEN is not a full pan, such as APPLEPAY. | |
data.paymentDetails[].cardInfo.source | string | No | maxLength: 32 | Source of the card. CARD、APPLEPAY、GOOGLEPAY_PAN、GOOGLEPAY_CRYPTOGRAM、NETWORK_TOKEN | |
data.paymentDetails[].cardInfo.cardBinNo | string | No | maxLength: 16 | Card BIN number. | |
data.paymentDetails[].cardInfo.cardNumber | string | No | maxLength: 32 | Masked card number. | |
data.paymentDetails[].cardInfo.cardHolderName | string | No | maxLength: 128 | Masked cardholder name. | |
data.paymentDetails[].cardInfo.cardLast4 | string | No | maxLength: 4 | The last four digits of the card. | |
data.paymentDetails[].cardInfo.cardExpirationYear | string | No | maxLength: 2 | Two-digit number representing the card’s expiration year. | |
data.paymentDetails[].cardInfo.cardExpirationMonth | string | No | maxLength: 2 | Two-digit number representing the card’s expiration month. | |
data.paymentDetails[].cardInfo.cardIdentifierNo ⚠️ | string | No | maxLength: 19 | Card number, the ciphertext is returned when paymentMethod is CARD | |
data.paymentDetails[].cardInfo.cardIdentifierName ⚠️ | string | No | maxLength: 192 | Card name, returned as a mask when paymentMethod is CARD | |
data.paymentDetails[].cardInfo.paymentTokenID ⚠️ | string | No | maxLength: 64 | In the card payment scenario, the authorization ID used for payment.The default validity period is the card validity period, which can be passed【removePaymentToken】 interface is set to invalid. | |
data.paymentDetails[].cardInfo.threeDSResult | object | No | 3ds result | ||
data.paymentDetails[].cardInfo.threeDSResult.threeDSVersion | string | No | maxLength: 16 | 3ds version 1.0.2, 2.1.0, 2.2.0 | |
data.paymentDetails[].cardInfo.threeDSResult.enrolled | string | No | maxLength: 1 | Status of Authentication eligibility. Y - Yes, Bank is participating in 3-D Secure protocol and will return the ACSUrl N - No, Bank is not participating in 3-D Secure protocol U - Unavailable, The DS or ACS is not available for authentication at the time of the request B - Bypass, Merchant authentication rule is triggered to bypass authentication in this use case. (3DS Flex premium only) | Y, U, B |
data.paymentDetails[].cardInfo.threeDSResult.authenticationStatus | string | No | maxLength: 1 | Transactions status result identifier. Y - Successful Authentication N - Failed Authentication U - Unable to Complete Authentication A - Successful Attempts Transaction R - Authentication Rejected (Merchant must not submit for authorisation) | Y, N , U , A , R |
data.paymentDetails[].cardInfo.threeDSResult.eci | string | Yes | maxLength: 2 | Electronic Commerce Indicator (ECI). Possible Values: 02 or 05 - Fully Authenticated Transaction 01 or 06 - Attempted Authentication Transaction 00 or 07 - Non 3-D Secure Transaction Mastercard - 02, 01, 00 Visa - 05, 06, 07 | |
data.paymentDetails[].cardInfo.threeDSResult.dsTransactionId | string | No | maxLength: 64 | the Directory Server (DS)Assigned Unique ID | |
data.paymentDetails[].cardInfo.threeDSResult.cavv | string | No | maxLength: 24 | Cardholder Authentication Verification Value (CAVV) Authentication Verification Value (AVV) Universal Cardholder Authentication Field (UCAF) | |
data.paymentDetails[].cardInfo.threeDSResult.xid | string | No | maxLength: 64 | Authentication result ID | |
data.paymentDetails[].cardInfo.avsResult | string | No | avs result | ||
data.paymentDetails[].paymentTokenID | string | No | maxLength: 64 | In the card payment scenario, the authorization ID used for payment.The default validity period is the card validity period, which can be passed【removePaymentToken】 interface is set to invalid. | |
data.paymentDetails[].exchangeRate | string | No | The exchange rate for converting the price currency into the payment currency | ||
data.paymentDetails[].payAmount | number | No | user pay amount | ||
data.paymentDetails[].payCurrency | string | No | maxLength: 3 | user pay currency | |
data.paymentDetails[].additionalData | object | No | Contains additional information about the payment | ||
data.paymentDetails[].additionalData.rrn | string | No | Retrieval Reference Number | ||
data.paymentDetails[].additionalData.authCode | string | No | Authorization Code | ||
data.fees | object | No | Fee information, returned only when payment is successful and fees exist | ||
data.fees.merFee | object | Yes | merchant tax fee | ||
data.fees.merFee.url | string | Yes | maxLength: 256 | Invoice URL, open the URL to preview the invoice | |
data.fees.merFee.amount | string | Yes | maxLength: 20 | fee amount | |
data.fees.merFee.currency | string | Yes | maxLength: 3 | fee currency | |
data.reference | string | No | maxLength: 512 | Customized data for merchant, will be returned in Callback Notification and Inquiry | |
data.channelNo | string | No | maxLength: 64 | Channel Order No. | |
data.thirdChannelNo | string | No | maxLength: 64 | third channel No | |
data.paymentCode | string | No | maxLength: 64 | VA No | |
data.cashierCountry | string | No | maxLength: 2 | Country where payment is initiated at the checkout. | |
data.issuerResponseCode | string | No | issuer response code | ||
data.issuerResponseMsg | string | No | issuer response message |
Example
json
{
"code": "APPLY_SUCCESS",
"msg": "",
"keyVersion": "1",
"appId": "3b242b56a8b64274bcc37dac281120e3",
"merchantNo": "020213827212251",
"notifyTime": "2022-01-17T09:33:54.540+00:00",
"notifyType": "PAYMENT",
"data": {
"outTradeNo": "P1642410680681",
"tradeToken": "T2024062702289232000001",
"totalAmount": 10000,
"currency": "IDR",
"channelNo": "DMCP000000000177005",
"thirdChannelNo": "4ikqJ6ktEqyRawE1dvqb9c",
"paymentCode": "2312121212",
"country": "ID",
"status": "SUCCESS",
"completeTime": "2023-10-20T03:28:23.092Z",
"paymentDetails": [
{
"paymentMethodType": "WALLET",
"targetOrg": "DANA",
"paymentTokenID": "PMTOKEN20230710080439571142400031000"
}
],
"reference": "020213827524152"
}
}Responses
200
| Field | Type | Required | Constraints | Description | Enum |
|---|---|---|---|---|---|
code | string | Yes | maxLength: 32 | Response ‘SUCCESS’(Only means that the callback response is successful) | |
msg | string | No | maxLength: 256 | Response’Success’(Only means that the callback response is successful) |
Response Example
json
{
"code": "SUCCESS",
"msg": "Success"
}Enum Reference
data.status
SUCCESSFAILEDCLOSED
data.paymentDetails[].cardInfo.threeDSResult.enrolled
YUB
data.paymentDetails[].cardInfo.threeDSResult.authenticationStatus
YNUAR
