Skip to content

Direct API

  • Endpoint: POST /aggregate-pay/api/gateway/orderAndPay/delSuffixStart1(Auth-capture)
  • Tags: Collection Service/Auth Capture

Description

Merchants want to integrate the payment flow on their cashier page, PayerMax provides Direct API access. For the Direct API interface, merchants need to have PCI-DSS certification if they process card number information by themselves.

Parameters

FieldInTypeRequiredConstraintsDescription
Content-TypeheaderstringYes
signheaderstringYes签名信息请参考技术文档

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

FieldTypeRequiredConstraintsDescriptionEnum
versionstringYesAPI version. Current value: 1.5
keyVersionstringYesSignature Algorithm Version, Current value: 1
requestTimestringYesRequest time, compliant with rfc3339 specification, format: yyyy-MM-dd'T'HH:mm:ss.SSSXXX The time must be within two minutes of the current time
appIdstringYesMerchant AppId,The unique identifier assigned to the merchant app by PayerMax
merchantNostringNomaxLength: 32Merchant Id, the unique identifier generated when the merchant signs the contract with PayerMax
dataobjectYesRequest data body.
data.outTradeNostringYesmaxLength: 64Merchant order id, which uniquely identifies a transaction of the merchant, cannot be repeated, and can only contain letters (Case sensitivity not supported), numbers, and underlines.For example, AAA and AAa are considered the same.
data.integratestringYesmaxLength: 16The merchant collects the payer's payment information by itself and sends it to PayerMax for transaction processing. Incoming parameter: Direct_Payment
data.captureModestringNoThe Capture Mode:MANUAL
data.authorizationTypestringNoThe Authorization type: FINAL_AUTH
data.subjectstringYesmaxLength: 256Order title or product information, which will be displayed on the user payment page, please avoid using pure numbers.  Note: it cannot exceed 43 digits for Brazil Pix.
data.totalAmountnumberYesThe order amount is passed in by the merchant. The decimal point supported by the currency of each country.See【Supported Country/Region and Currency】,Risk control limit list.See【Risk control limit list
data.currencystringYesmaxLength: 3Currency code, capital letter see【Supported Country/Region and Currency
data.countrystringYesmaxLength: 2Country code, capital letters,If the passed country code does not match the currency, the cashier will be displayed in the region corresponding to the currency code. If a payment method is specified, the country must be sent, see【Supported Country/Region and Currency
data.userIdstringYesmaxLength: 64The user ID of the merchant, needs to ensure the uniqueness of each user ID. After the payment method is bound, the payment method will be recommended according to the userId.
data.expireTimestringNomaxLength: 16Define the payment duration in seconds, If the order has not been completed within the duration, it will be closed. The range is 1800~86400.
data.paymentDetailobjectYesPayment method information 1. Specify a certain type of payment method, such as BANK_TRANSFER, CARRIER_BILLING 2. Specify designated paymentMethodType + targetOrg.
data.paymentDetail.paymentMethodTypestringYesmaxLength: 16payment method, mandatory, see【Direct API - Payment Method List
data.paymentDetail.targetOrgstringNomaxLength: 32The target institution is mandatory except when the paymentMethodType is card.
data.paymentDetail.tokenForFutureUsebooleanNotrue means that the user has been authorized to bind payment information for subsequent use, the default is false
data.paymentDetail.paymentTokenIDstringNomaxLength: 64PMMax token,pay after successful authorization
data.paymentDetail.payAccountInfoarray[object]NoTarget institutions under some payment methods need to upload the user’s payment account information in the target institution. Please refer to the list of account types supported for uploading under【Direct API - Payment Method List
data.paymentDetail.payAccountInfo[].accountNostringNomaxLength: 32The payment account registered by the user in the target institution under this payment method.
data.paymentDetail.payAccountInfo[].accountNoTypestringNomaxLength: 255account type:EMAIL,PHONE,ACCOUNT.
data.paymentDetail.cardInfoobjectNoCard information.
data.paymentDetail.cardInfo.cardIdentifierNostringNomaxLength: 19card ID, card number.
data.paymentDetail.cardInfo.cardHolderFullNamestringNomaxLength: 64Cardholder’s Name.
data.paymentDetail.cardInfo.cardExpirationMonthstringNomaxLength: 2Card Expiration Date - month, two digits.
data.paymentDetail.cardInfo.cardExpirationYearstringNomaxLength: 2Card Expiration Date - year, only the last two years are taken.
data.paymentDetail.cardInfo.cvvstringNomaxLength: 4Card cvv, three digits for Visa and Master, four digits for AMEX.
data.paymentDetail.cardInfo.storedstringNoIndicates whether the card payment transaction has been saved. Saved card: Y Not saved card: Leave blank or other value
data.paymentDetail.cardInfo.dynamic3DSstringNomaxLength: 64dynamic 3ds (case insensitive) do3DS: Perform 3D Secure for this order. no3DS: Do not perform 3D Secure for this order. ext3DS: Use external 3DS results, suitable for merchants who have integrated 3DS services. The info3DSecure object is required when using this value. If no value is passed or other values are passed in, PayerMax will determine whether to initiate 3ds
data.paymentDetail.buyerInfoobjectYesbuyer information.
data.paymentDetail.buyerInfo.firstNamestringNomaxLength: 64first name of the user.
data.paymentDetail.buyerInfo.middleNamestringNomaxLength: 64middle name of the user.
data.paymentDetail.buyerInfo.lastNamestringNomaxLength: 64last name of the user.
data.paymentDetail.buyerInfo.emailstringNomaxLength: 255user email
data.paymentDetail.buyerInfo.phoneNostringNomaxLength: 32phone number of the user.
data.paymentDetail.buyerInfo.phoneNoRegionstringNomaxLength: 16phone no region.
data.paymentDetail.buyerInfo.idTypestringNomaxLength: 32Id type.
data.paymentDetail.buyerInfo.idNostringNomaxLength: 64Id NO.
data.paymentDetail.buyerInfo.taxTypestringNomaxLength: 32For tax types, please refer to 【Personal Identification
data.paymentDetail.buyerInfo.taxNostringNomaxLength: 64For tax number, please refer to 【Personal Identification
data.paymentDetail.buyerInfo.addressstringNomaxLength: 1024user’s address.
data.paymentDetail.buyerInfo.citystringNomaxLength: 64user’s city.
data.paymentDetail.buyerInfo.regionstringNomaxLength: 64user’s region.
data.paymentDetail.buyerInfo.zipCodestringNomaxLength: 32post code.
data.paymentDetail.buyerInfo.clientIpstringYesThe user's IP address. Must be in standard IPv4 or IPv6 format.
data.paymentDetail.buyerInfo.userAgentstringYesUser browser information.
data.paymentDetail.info3DSecureobjectNoWhen merchants use ext3DS, the external 3DS information sent.Note: You must contact technical support in advance to activate related functions
data.paymentDetail.info3DSecure.threeDSVersionstringNo3ds version number
data.paymentDetail.info3DSecure.ecistringNoeci value
data.paymentDetail.info3DSecure.cavvstringNocavv value
data.paymentDetail.info3DSecure.dsTransactionIdstringNodsTransactionId value
data.paymentDetail.info3DSecure.xidstringNoxid value
data.paymentDetail.merchantInitiatedbooleanNoIndicates whether it is a MIT transaction. If not passed, it defaults to false.
data.paymentDetail.mitTypestringNomit typeSCHEDULED, UNSCHEDULED
data.goodsDetailsarray[object]NoThe goods that the user buys. A list can be submitted. Note:E-commerce industy needs to send.If the object is passed in, the inner required fields must be passed in
data.goodsDetails[].goodsIdstringYesmaxLength: 64goods ID.
data.goodsDetails[].goodsNamestringYesmaxLength: 128goods name.
data.goodsDetails[].quantitystringYesmaxLength: 16goods amount.
data.goodsDetails[].pricestringYesmaxLength: 20Price set by the merchant system.
data.goodsDetails[].goodsCurrencystringNomaxLength: 3goods currency, capital letters,see【Supported Country/Region and Currency
data.goodsDetails[].showUrlstringNomaxLength: 128goods URL.
data.goodsDetails[].goodsCategorystringNomaxLength: 128goods Category.
data.subMerchantobjectNoSubmerchant Information, Platform merchants need to submit sub-merchant information.
data.subMerchant.subMerchantNostringNomaxLength: 64Submerchant ID.
data.shippingInfoobjectNoshipping info. Note:E-commerce industy needs to send.If the object is passed in, the inner required fields must be passed in
data.shippingInfo.firstNamestringYesmaxLength: 64shipping first name.
data.shippingInfo.middleNamestringNomaxLength: 64shipping middle name.
data.shippingInfo.lastNamestringYesmaxLength: 64shipping last name.
data.shippingInfo.phoneNostringYesmaxLength: 32shipping phone no.
data.shippingInfo.emailstringYesmaxLength: 255shipping email address.
data.shippingInfo.address1stringYesmaxLength: 1024shipping address 1.
data.shippingInfo.address2stringNomaxLength: 1024shipping address 2.
data.shippingInfo.address3stringNomaxLength: 1024shipping address 3.
data.shippingInfo.citystringYesmaxLength: 64city of the shipping address
data.shippingInfo.regionstringNomaxLength: 64region of the shipping address.
data.shippingInfo.statestringNomaxLength: 32State of the shipping address Required for shipping to Canada, US, UK, Australia.
data.shippingInfo.countrystringYesmaxLength: 2country of the shipping address.
data.shippingInfo.zipCodestringYesmaxLength: 32zipcode of the shipping address.
data.billingInfoobjectNoBilling Information.Note: If the object is passed in, the inner required fields must be passed in
data.billingInfo.firstNamestringNomaxLength: 64biller name.
data.billingInfo.middleNamestringNomaxLength: 64biller middle name.
data.billingInfo.lastNamestringNomaxLength: 64biller last name.
data.billingInfo.phoneNostringNomaxLength: 32biller phone no.
data.billingInfo.emailstringYesmaxLength: 255biller email address.
data.billingInfo.address1stringYesmaxLength: 1024Billing Address 1.
data.billingInfo.address2stringNomaxLength: 1024Billing Address 2.
data.billingInfo.address3stringNomaxLength: 1024Billing Address 3.
data.billingInfo.citystringYesmaxLength: 64City of billing address.
data.billingInfo.countrystringYesmaxLength: 2Country of billing address.
data.billingInfo.regionstringNomaxLength: 64Region of billing address.
data.billingInfo.statestringNomaxLength: 32State of billing address Shipping is required in Canada, USA, UK, Australia.
data.billingInfo.zipCodestringNomaxLength: 16Billing Address Zip Code.
data.envInfoobjectNoenvironmental information
data.envInfo.deviceIdstringNoMerchant device unique identifier
data.envInfo.deviceLanguagestringNoDevice default language
data.envInfo.screenHeightstringNodevice height
data.envInfo.screenWidthstringNodevice width
data.languagestringNomaxLength: 16Cashier page language.【Supported Country/Region and Currency】 The priority is: the language last used by the user > the language of the user's browser > the country language of the user's IP > the language of the merchant's order > Default EN
data.riskParamsobjectNoRisk control business data,see:【Risk Information】. This part of information is usually used as supplementary information for customized risk control. If customized risk control is not enabled, it can be left blank.
data.terminalTypestringYesmaxLength: 3Device terminal, WEB, WAP, APP.
data.osTypestringNoDevice operating system, when the device terminal is Wap and App, the device operating system can be ANDROID or IOS.
data.referencestringNomaxLength: 512Merchant custom additional data, which can support merchant customization and return in the response.
data.frontCallbackUrlstringYesmaxLength: 1024The redirect URL specified by the merchant, the user will be redirected to this address after completing the payment, starting with http/https or the scheme address of the merchant’s application. FrontCallbackUrl is mandated for API-only payment to support callback transactions that need to redirect to external links.
data.notifyUrlstringNomaxLength: 256Server-side callback notification URL, starting with http/https The merchant notification address can be configured through the MerchantDashboard platform. If the transaction is uploaded, the transaction shall prevail.Note: If the merchant platform does not configure a notifyUrl and the transaction does not have a sending notifyUrl, callback notification cannot be made.
data.subscriptionPlanobjectNosubscription plan info
data.subscriptionPlan.subscriptionNostringYesmaxLength: 64, minLength: 1The subscription order number generated after creating a subscription plan through PayerMax, it is necessary when activating the subscription plan.

Example: 1

json
{
  "version": "1.5",
  "keyVersion": "1",
  "requestTime": "2022-02-25T09:23:06.473+00:00",
  "appId": "6666c8b036a24579974497c2f9800001",
  "merchantNo": "020213834421284",
  "data": {
    "outTradeNo": "Test1645780876511",
    "subject": "this is subject",
    "totalAmount": 1,
    "captureMode": "MANUAL",
    "authorizationType": "FINAL_AUTH",
    "currency": "AED",
    "country": "AE",
    "userId": "userId001",
    "integrate": "Direct_Payment",
    "paymentDetail": {
      "paymentMethodType": "CARD",
      "cardInfo": {
        "cardIdentifierNo": "4001563861135570",
        "cardHolderFullName": "James Smith",
        "cardExpirationMonth": "05",
        "cardExpirationYear": "25",
        "cvv": "123"
      },
      "buyerInfo": {
        "firstName": "James",
        "lastName": "Smith",
        "phoneNo": "903124360628",
        "email": "james@google.com",
        "clientIp": "124.156.108.193",
        "userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36"
      }
    },
    "goodsDetails": [
      {
        "goodsId": "D002",
        "goodsName": "Key buckle",
        "quantity": "2",
        "price": "0.5",
        "goodsCurrency": "AED",
        "showUrl": "http://xxx.com",
        "goodsCategory": "goods"
      }
    ],
    "envInfo": {
      "deviceId": "eYOIkvFpZzztg00Yu6USdprBQZCWxDhiUAHCiK&K/cH9mT6wMaMOzAKe",
      "deviceLanguage": "zh_CN",
      "screenHeight": 768,
      "screenWidth": 1024
    },
    "shippingInfo": {
      "firstName": "James",
      "lastName": "Smith",
      "phoneNo": "903124360628",
      "email": "James@google.com",
      "address1": "GOLGELI SOKAK NO.34, 06700",
      "city": "GAZIOSMANPASA/ANKAR",
      "country": "TR",
      "zipCode": "06700"
    },
    "billingInfo": {
      "firstName": "James",
      "lastName": "Smith",
      "phoneNo": "903124360628",
      "email": "James@google.com",
      "address1": "GOLGELI SOKAK NO.34, 06700",
      "city": "GAZIOSMANPASA/ANKAR",
      "country": "TR",
      "zipCode": "06700"
    },
    "language": "en",
    "reference": "020213827524152",
    "frontCallbackURL": "https://www.payermax.com",
    "notifyUrl": "https://www.payermax.com"
  }
}

Example: 2

Card Pay

json
{
  "requestTime": "2025-06-26T20:11:22.895+08:00",
  "keyVersion": "1",
  "data": {
    "country": "SA",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "orderAndPayUserIdF4aiPqY3VG",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100",
    "paymentDetail": {
      "cardInfo": {
        "cvv": "123",
        "cardIdentifierNo": "4444333322221111",
        "cardExpirationMonth": "03",
        "cardExpirationYear": "30",
        "cardHolderFullName": "James Smith"
      },
      "buyerInfo": {
        "userAgent": "userAgent",
        "clientIp": "182.11.22.22"
      },
      "paymentMethodType": "CARD"
    },
    "outTradeNo": "orderAndPayOutTradeNo1750939882895u76ofjW6PQ",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "SAR"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Example: 3

googlePay

json
{
  "requestTime": "2025-06-26T20:11:21.891+08:00",
  "keyVersion": "1",
  "data": {
    "country": "SA",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "orderAndPayUserId5Sc3VW3Xlv",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100",
    "paymentDetail": {
      "googlePayDetails": {
        "expirationYear": "2026",
        "expirationMonth": "01",
        "pan": "4336680020191751",
        "authMethod": "CRYPTOGRAM_3DS",
        "eciIndicator": "02",
        "cryptogram": "AAAAAA..."
      },
      "buyerInfo": {
        "userAgent": "userAgent",
        "clientIp": "182.11.22.22"
      },
      "paymentMethodType": "GOOGLEPAY"
    },
    "outTradeNo": "orderAndPayOutTradeNo1750939881891mqkJIYHAD8",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "SAR"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Example: 4

applePay

json
{
  "requestTime": "2025-06-26T20:11:19.422+08:00",
  "keyVersion": "1",
  "data": {
    "country": "SA",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "orderAndPayUserIdoFRPz2kYvr",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100",
    "paymentDetail": {
      "applePayPaymentData": {
        "deviceManufacturerIdentifier": "040010030273",
        "applicationPrimaryAccountNumber": "4761209400215743",
        "transactionAmount": "100",
        "paymentData": {
          "onlinePaymentCryptogram": "AqhVFUwAAuM69WEZxe+OMAACAAA=",
          "eciIndicator": "7"
        },
        "paymentDataType": "3DSecure",
        "currencyCode": "344",
        "applicationExpirationDate": "231231"
      },
      "buyerInfo": {
        "userAgent": "userAgent",
        "clientIp": "182.11.22.22"
      },
      "paymentMethodType": "APPLEPAY"
    },
    "outTradeNo": "orderAndPayOutTradeNo1750939879422YKdAj2nTzV",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "SAR"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Example: 5

token-first

json
{
  "requestTime": "2025-06-26T20:11:35.336+08:00",
  "keyVersion": "1",
  "data": {
    "country": "SA",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "TokenPay_USERIDCDd6W14OLi",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100",
    "paymentDetail": {
      "cardInfo": {
        "cvv": "123",
        "cardIdentifierNo": "4444333322221111",
        "cardExpirationMonth": "03",
        "cardExpirationYear": "30",
        "cardHolderFullName": "James Smith"
      },
      "tokenForFutureUse": true,
      "buyerInfo": {
        "userAgent": "userAgent",
        "clientIp": "182.11.22.22"
      },
      "paymentMethodType": "CARD"
    },
    "outTradeNo": "orderAndPayOutTradeNo1750939895336PuVDesFayU",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "SAR"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Example: 6

token-follow up

json
{
  "requestTime": "2025-06-26T20:11:36.206+08:00",
  "keyVersion": "1",
  "data": {
    "country": "SA",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "TokenPay_USERIDCDd6W14OLi",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100",
    "paymentDetail": {
      "tokenForFutureUse": false,
      "buyerInfo": {
        "userAgent": "userAgent",
        "clientIp": "182.11.22.22"
      },
      "paymentTokenID": "PMTOKEN20250626121135955468420000003",
      "paymentMethodType": "CARD"
    },
    "outTradeNo": "TokenPay_outTradeNo1Yfx63ylWs",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "SAR"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Example: 7

apm-redirect

json
{
  "requestTime": "2025-06-26T20:11:18.336+08:00",
  "keyVersion": "1",
  "data": {
    "country": "DE",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "orderAndPayUserIdiwJYCnF0m7",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100",
    "paymentDetail": {
      "targetOrg": "KLARNA",
      "buyerInfo": {
        "userAgent": "userAgent",
        "clientIp": "182.11.22.22"
      },
      "paymentMethodType": "PAY_LATER"
    },
    "outTradeNo": "orderAndPayOutTradeNo1750939878336UokUa96TMY",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "EUR"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Example: 8

token-direct

json
{
  "requestTime": "2025-06-26T20:11:17.568+08:00",
  "keyVersion": "1",
  "data": {
    "country": "ID",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "orderAndPayUserIdzwE3HzfblB",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100000",
    "paymentDetail": {
      "targetOrg": "BCA",
      "buyerInfo": {
        "userAgent": "userAgent",
        "clientIp": "182.11.22.22"
      },
      "paymentMethodType": "BANK_TRANSFER"
    },
    "outTradeNo": "orderAndPayOutTradeNo1750939877568AcCRKeNm72",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "IDR"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Example: 9

apm-qrcode

json
{
  "requestTime": "2025-06-26T20:11:16.895+08:00",
  "keyVersion": "1",
  "data": {
    "country": "ID",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "orderAndPayUserIdWIzHxQEHtR",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100000",
    "paymentDetail": {
      "targetOrg": "GOPAY",
      "buyerInfo": {
        "userAgent": "userAgent",
        "clientIp": "182.11.22.22"
      },
      "paymentMethodType": "WALLET"
    },
    "outTradeNo": "orderAndPayOutTradeNo1750939876895m7AiFoV1nt",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "IDR"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Example: 10

apm-cpf

json
{
  "requestTime": "2025-06-26T20:11:16.008+08:00",
  "keyVersion": "1",
  "data": {
    "country": "BR",
    "frontCallbackUrl": "http://www.frontCallbackUrl.example.com",
    "subject": "MacPro14 and Mouse",
    "userId": "orderAndPayUserIdUDqUvvX50y",
    "integrate": "Direct_Payment",
    "terminalType": "WEB",
    "totalAmount": "100",
    "paymentDetail": {
      "targetOrg": "MERCADOPAGO",
      "buyerInfo": {
        "clientIp": "182.11.22.22",
        "userAgent": "userAgent",
        "taxNo": "17943231554",
        "taxType": "CPF"
      },
      "paymentMethodType": "WALLET"
    },
    "outTradeNo": "orderAndPayOutTradeNo1750939876008MIdEpXyvN4",
    "notifyUrl": "http://www.notifyUrl.example.com",
    "currency": "BRL"
  },
  "appId": "d27183b7f2ea4822aa722d9efa8e7a8b",
  "version": "1.5",
  "merchantNo": "SDP01010115045982"
}

Responses

200

FieldTypeRequiredConstraintsDescriptionEnum
codestringYesReturn code, ‘APPLY_SUCCESS’ means success.It only represents the success of the interface request, not the order status.
msgstringYesReturn message, ‘Success.’.It only represents the success of the interface request, not the order status.
dataobjectNoReturn data body.
data.outTradeNostringYesmaxLength: 64Merchant order id. order id.
data.tradeTokenstringYesmaxLength: 64PayerMax order id.
data.statusstringYesmaxLength: 32transaction status.
data.redirectUrlstringNomaxLength: 1024redirect link; Some payment methods need to jump to the outside to complete the payment.

Response Example: 1

成功示例

json
{
  "code": "APPLY_SUCCESS",
  "msg": " Success.",
  "data": {
    "outTradeNo": "Test1645780876511",
    "tradeToken": "T2024062702289232000001",
    "status": "SUCCESS"
  }
}

Response Example: 2

apm-redirect-response

json
{
  "msg": "Success.",
  "code": "APPLY_SUCCESS",
  "data": {
    "redirectUrl": "https://cashier-n-uat.payermax.com/v2/index.html#/mocks?simulatorType=payment&pmaxUrlMock=1&referenceNo=UPC594700175093987893951000031&merchantId=SDP01010115045982&merchantAppId=d27183b7f2ea4822aa722d9efa8e7a8b&tradeToken=T2025062612594747000086&payRequestNo=20250626121118EP2094594711153204T05&token=8cfe3859f5f04c5783481a26089c6416",
    "outTradeNo": "orderAndPayOutTradeNo1750939878336UokUa96TMY",
    "tradeToken": "T2025062612594747000086",
    "status": "PENDING"
  }
}

Response Example: 3

apm-direct-response

json
{
  "msg": "Success.",
  "code": "APPLY_SUCCESS",
  "data": {
    "vaCode": "TEST***001",
    "outTradeNo": "orderAndPayOutTradeNo1751265358900gHyeC8LHpb",
    "tradeToken": "T2025063006003647012140",
    "status": "PENDING"
  }
}

Response Example: 4

apm-qrcode-response

json
{
  "msg": "Success.",
  "code": "APPLY_SUCCESS",
  "data": {
    "redirectUrl": "https://gopay.co.id/app/merchanttransfer?tref=A120240108055206Yf6o5risurID&amount=15000&activity=GP:RR&callback_url=https%3A%2F%2Fchannel.payermax.com%2Fin-pay-channel%2Fc%2FoutService%2FfrontCallbackV1%2FmidTrans%2FPPC788800170469312633195812771%2Fredirect%3Forder_id%3DPPC788800170469312633195812771",
    "qrCodeUrl": "https://api.midtrans.com/v2/gopay/b54f6b26-c3b8-4756-acb8-4c53097ab8ca/qr-code",
    "outTradeNo": "orderAndPayOutTradeNo17512653582106DuKJbyYzW",
    "tradeToken": "T2025063006734147012136",
    "status": "PENDING"
  }
}

Enum Reference

data.paymentDetail.mitType

  • SCHEDULED
  • UNSCHEDULED

Was this page helpful?

Thank you for your help in improving PayerMax Product Docs!

Released under the MIT License.