申请付款
curl --request POST \
--url https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay \
--header 'Content-Type: application/json' \
--header 'signature: <api-key>' \
--data '
{
"charset": "utf-8",
"memberId": "2022000000008454",
"merchantId": "2022000000008454",
"requestTime": "2025-10-24T15:00:00.500+08:00",
"signType": "RSA",
"transType": "PAY",
"version": "2.0.0",
"data": {
"outTradeNo": "394916B2ADFD4D6CAD6CC624C88990D0",
"country": "ID",
"sourceAccount": "PHP",
"destinationCurrency": "PHP",
"trade": {
"amount": "100",
"currency": "IDR"
},
"payeeInfo": {
"paymentMethodType": "WALLET",
"accountInfo": {
"accountNo": "0812323233332",
"accountType": "",
"checkDigit": ""
},
"targetOrg": "DANA",
"payeeType": "PERSONAL",
"bankInfo": {
"bankCode": "",
"bankName": "",
"bankBranch": "",
"bankCity": "",
"corAccountNo": ""
},
"name": {
"firstName": "James",
"middleName": "Shri Williams",
"lastName": "Kanta",
"fullName": "James Shri Williams Kanta"
},
"document": {
"documentType": "",
"documentId": "",
"documentIssueDate": "",
"documentExpireDate": ""
},
"address": {
"address": "",
"city": "",
"state": "",
"zipCode": ""
},
"payeePhone": "08123456789",
"birthDate": "1996-09-01",
"email": "example@gmail.com"
},
"chargeOption": "",
"clearingRail": "LOCAL",
"userId": "abc123456789",
"payerInfo": {
"subMerchantNo": "",
"businessLegalName": "",
"registrationCountry": "",
"merchantCategoryCode": "",
"payerId": "",
"name": {
"firstName": "James",
"middleName": "Shri Williams",
"lastName": "Kanta",
"fullName": "James Shri Williams Kanta"
}
},
"expiryDays": "3",
"remark": "this is remark",
"reference": "this is reference",
"notifyUrl": "http://example.com/callback/",
"notifyEmail": "example@gmail.com",
"notifyPhone": "",
"purpose": "GAME"
}
}
'import requests
url = "https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay"
payload = {
"charset": "utf-8",
"memberId": "2022000000008454",
"merchantId": "2022000000008454",
"requestTime": "2025-10-24T15:00:00.500+08:00",
"signType": "RSA",
"transType": "PAY",
"version": "2.0.0",
"data": {
"outTradeNo": "394916B2ADFD4D6CAD6CC624C88990D0",
"country": "ID",
"sourceAccount": "PHP",
"destinationCurrency": "PHP",
"trade": {
"amount": "100",
"currency": "IDR"
},
"payeeInfo": {
"paymentMethodType": "WALLET",
"accountInfo": {
"accountNo": "0812323233332",
"accountType": "",
"checkDigit": ""
},
"targetOrg": "DANA",
"payeeType": "PERSONAL",
"bankInfo": {
"bankCode": "",
"bankName": "",
"bankBranch": "",
"bankCity": "",
"corAccountNo": ""
},
"name": {
"firstName": "James",
"middleName": "Shri Williams",
"lastName": "Kanta",
"fullName": "James Shri Williams Kanta"
},
"document": {
"documentType": "",
"documentId": "",
"documentIssueDate": "",
"documentExpireDate": ""
},
"address": {
"address": "",
"city": "",
"state": "",
"zipCode": ""
},
"payeePhone": "08123456789",
"birthDate": "1996-09-01",
"email": "example@gmail.com"
},
"chargeOption": "",
"clearingRail": "LOCAL",
"userId": "abc123456789",
"payerInfo": {
"subMerchantNo": "",
"businessLegalName": "",
"registrationCountry": "",
"merchantCategoryCode": "",
"payerId": "",
"name": {
"firstName": "James",
"middleName": "Shri Williams",
"lastName": "Kanta",
"fullName": "James Shri Williams Kanta"
}
},
"expiryDays": "3",
"remark": "this is remark",
"reference": "this is reference",
"notifyUrl": "http://example.com/callback/",
"notifyEmail": "example@gmail.com",
"notifyPhone": "",
"purpose": "GAME"
}
}
headers = {
"signature": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {signature: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
charset: 'utf-8',
memberId: '2022000000008454',
merchantId: '2022000000008454',
requestTime: '2025-10-24T15:00:00.500+08:00',
signType: 'RSA',
transType: 'PAY',
version: '2.0.0',
data: {
outTradeNo: '394916B2ADFD4D6CAD6CC624C88990D0',
country: 'ID',
sourceAccount: 'PHP',
destinationCurrency: 'PHP',
trade: {amount: '100', currency: 'IDR'},
payeeInfo: {
paymentMethodType: 'WALLET',
accountInfo: {accountNo: '0812323233332', accountType: '', checkDigit: ''},
targetOrg: 'DANA',
payeeType: 'PERSONAL',
bankInfo: {bankCode: '', bankName: '', bankBranch: '', bankCity: '', corAccountNo: ''},
name: {
firstName: 'James',
middleName: 'Shri Williams',
lastName: 'Kanta',
fullName: 'James Shri Williams Kanta'
},
document: {
documentType: '',
documentId: '',
documentIssueDate: '',
documentExpireDate: ''
},
address: {address: '', city: '', state: '', zipCode: ''},
payeePhone: '08123456789',
birthDate: '1996-09-01',
email: 'example@gmail.com'
},
chargeOption: '',
clearingRail: 'LOCAL',
userId: 'abc123456789',
payerInfo: {
subMerchantNo: '',
businessLegalName: '',
registrationCountry: '',
merchantCategoryCode: '',
payerId: '',
name: {
firstName: 'James',
middleName: 'Shri Williams',
lastName: 'Kanta',
fullName: 'James Shri Williams Kanta'
}
},
expiryDays: '3',
remark: 'this is remark',
reference: 'this is reference',
notifyUrl: 'http://example.com/callback/',
notifyEmail: 'example@gmail.com',
notifyPhone: '',
purpose: 'GAME'
}
})
};
fetch('https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'charset' => 'utf-8',
'memberId' => '2022000000008454',
'merchantId' => '2022000000008454',
'requestTime' => '2025-10-24T15:00:00.500+08:00',
'signType' => 'RSA',
'transType' => 'PAY',
'version' => '2.0.0',
'data' => [
'outTradeNo' => '394916B2ADFD4D6CAD6CC624C88990D0',
'country' => 'ID',
'sourceAccount' => 'PHP',
'destinationCurrency' => 'PHP',
'trade' => [
'amount' => '100',
'currency' => 'IDR'
],
'payeeInfo' => [
'paymentMethodType' => 'WALLET',
'accountInfo' => [
'accountNo' => '0812323233332',
'accountType' => '',
'checkDigit' => ''
],
'targetOrg' => 'DANA',
'payeeType' => 'PERSONAL',
'bankInfo' => [
'bankCode' => '',
'bankName' => '',
'bankBranch' => '',
'bankCity' => '',
'corAccountNo' => ''
],
'name' => [
'firstName' => 'James',
'middleName' => 'Shri Williams',
'lastName' => 'Kanta',
'fullName' => 'James Shri Williams Kanta'
],
'document' => [
'documentType' => '',
'documentId' => '',
'documentIssueDate' => '',
'documentExpireDate' => ''
],
'address' => [
'address' => '',
'city' => '',
'state' => '',
'zipCode' => ''
],
'payeePhone' => '08123456789',
'birthDate' => '1996-09-01',
'email' => 'example@gmail.com'
],
'chargeOption' => '',
'clearingRail' => 'LOCAL',
'userId' => 'abc123456789',
'payerInfo' => [
'subMerchantNo' => '',
'businessLegalName' => '',
'registrationCountry' => '',
'merchantCategoryCode' => '',
'payerId' => '',
'name' => [
'firstName' => 'James',
'middleName' => 'Shri Williams',
'lastName' => 'Kanta',
'fullName' => 'James Shri Williams Kanta'
]
],
'expiryDays' => '3',
'remark' => 'this is remark',
'reference' => 'this is reference',
'notifyUrl' => 'http://example.com/callback/',
'notifyEmail' => 'example@gmail.com',
'notifyPhone' => '',
'purpose' => 'GAME'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"signature: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay"
payload := strings.NewReader("{\n \"charset\": \"utf-8\",\n \"memberId\": \"2022000000008454\",\n \"merchantId\": \"2022000000008454\",\n \"requestTime\": \"2025-10-24T15:00:00.500+08:00\",\n \"signType\": \"RSA\",\n \"transType\": \"PAY\",\n \"version\": \"2.0.0\",\n \"data\": {\n \"outTradeNo\": \"394916B2ADFD4D6CAD6CC624C88990D0\",\n \"country\": \"ID\",\n \"sourceAccount\": \"PHP\",\n \"destinationCurrency\": \"PHP\",\n \"trade\": {\n \"amount\": \"100\",\n \"currency\": \"IDR\"\n },\n \"payeeInfo\": {\n \"paymentMethodType\": \"WALLET\",\n \"accountInfo\": {\n \"accountNo\": \"0812323233332\",\n \"accountType\": \"\",\n \"checkDigit\": \"\"\n },\n \"targetOrg\": \"DANA\",\n \"payeeType\": \"PERSONAL\",\n \"bankInfo\": {\n \"bankCode\": \"\",\n \"bankName\": \"\",\n \"bankBranch\": \"\",\n \"bankCity\": \"\",\n \"corAccountNo\": \"\"\n },\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n },\n \"document\": {\n \"documentType\": \"\",\n \"documentId\": \"\",\n \"documentIssueDate\": \"\",\n \"documentExpireDate\": \"\"\n },\n \"address\": {\n \"address\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"zipCode\": \"\"\n },\n \"payeePhone\": \"08123456789\",\n \"birthDate\": \"1996-09-01\",\n \"email\": \"example@gmail.com\"\n },\n \"chargeOption\": \"\",\n \"clearingRail\": \"LOCAL\",\n \"userId\": \"abc123456789\",\n \"payerInfo\": {\n \"subMerchantNo\": \"\",\n \"businessLegalName\": \"\",\n \"registrationCountry\": \"\",\n \"merchantCategoryCode\": \"\",\n \"payerId\": \"\",\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n }\n },\n \"expiryDays\": \"3\",\n \"remark\": \"this is remark\",\n \"reference\": \"this is reference\",\n \"notifyUrl\": \"http://example.com/callback/\",\n \"notifyEmail\": \"example@gmail.com\",\n \"notifyPhone\": \"\",\n \"purpose\": \"GAME\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("signature", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay")
.header("signature", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"charset\": \"utf-8\",\n \"memberId\": \"2022000000008454\",\n \"merchantId\": \"2022000000008454\",\n \"requestTime\": \"2025-10-24T15:00:00.500+08:00\",\n \"signType\": \"RSA\",\n \"transType\": \"PAY\",\n \"version\": \"2.0.0\",\n \"data\": {\n \"outTradeNo\": \"394916B2ADFD4D6CAD6CC624C88990D0\",\n \"country\": \"ID\",\n \"sourceAccount\": \"PHP\",\n \"destinationCurrency\": \"PHP\",\n \"trade\": {\n \"amount\": \"100\",\n \"currency\": \"IDR\"\n },\n \"payeeInfo\": {\n \"paymentMethodType\": \"WALLET\",\n \"accountInfo\": {\n \"accountNo\": \"0812323233332\",\n \"accountType\": \"\",\n \"checkDigit\": \"\"\n },\n \"targetOrg\": \"DANA\",\n \"payeeType\": \"PERSONAL\",\n \"bankInfo\": {\n \"bankCode\": \"\",\n \"bankName\": \"\",\n \"bankBranch\": \"\",\n \"bankCity\": \"\",\n \"corAccountNo\": \"\"\n },\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n },\n \"document\": {\n \"documentType\": \"\",\n \"documentId\": \"\",\n \"documentIssueDate\": \"\",\n \"documentExpireDate\": \"\"\n },\n \"address\": {\n \"address\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"zipCode\": \"\"\n },\n \"payeePhone\": \"08123456789\",\n \"birthDate\": \"1996-09-01\",\n \"email\": \"example@gmail.com\"\n },\n \"chargeOption\": \"\",\n \"clearingRail\": \"LOCAL\",\n \"userId\": \"abc123456789\",\n \"payerInfo\": {\n \"subMerchantNo\": \"\",\n \"businessLegalName\": \"\",\n \"registrationCountry\": \"\",\n \"merchantCategoryCode\": \"\",\n \"payerId\": \"\",\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n }\n },\n \"expiryDays\": \"3\",\n \"remark\": \"this is remark\",\n \"reference\": \"this is reference\",\n \"notifyUrl\": \"http://example.com/callback/\",\n \"notifyEmail\": \"example@gmail.com\",\n \"notifyPhone\": \"\",\n \"purpose\": \"GAME\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["signature"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"charset\": \"utf-8\",\n \"memberId\": \"2022000000008454\",\n \"merchantId\": \"2022000000008454\",\n \"requestTime\": \"2025-10-24T15:00:00.500+08:00\",\n \"signType\": \"RSA\",\n \"transType\": \"PAY\",\n \"version\": \"2.0.0\",\n \"data\": {\n \"outTradeNo\": \"394916B2ADFD4D6CAD6CC624C88990D0\",\n \"country\": \"ID\",\n \"sourceAccount\": \"PHP\",\n \"destinationCurrency\": \"PHP\",\n \"trade\": {\n \"amount\": \"100\",\n \"currency\": \"IDR\"\n },\n \"payeeInfo\": {\n \"paymentMethodType\": \"WALLET\",\n \"accountInfo\": {\n \"accountNo\": \"0812323233332\",\n \"accountType\": \"\",\n \"checkDigit\": \"\"\n },\n \"targetOrg\": \"DANA\",\n \"payeeType\": \"PERSONAL\",\n \"bankInfo\": {\n \"bankCode\": \"\",\n \"bankName\": \"\",\n \"bankBranch\": \"\",\n \"bankCity\": \"\",\n \"corAccountNo\": \"\"\n },\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n },\n \"document\": {\n \"documentType\": \"\",\n \"documentId\": \"\",\n \"documentIssueDate\": \"\",\n \"documentExpireDate\": \"\"\n },\n \"address\": {\n \"address\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"zipCode\": \"\"\n },\n \"payeePhone\": \"08123456789\",\n \"birthDate\": \"1996-09-01\",\n \"email\": \"example@gmail.com\"\n },\n \"chargeOption\": \"\",\n \"clearingRail\": \"LOCAL\",\n \"userId\": \"abc123456789\",\n \"payerInfo\": {\n \"subMerchantNo\": \"\",\n \"businessLegalName\": \"\",\n \"registrationCountry\": \"\",\n \"merchantCategoryCode\": \"\",\n \"payerId\": \"\",\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n }\n },\n \"expiryDays\": \"3\",\n \"remark\": \"this is remark\",\n \"reference\": \"this is reference\",\n \"notifyUrl\": \"http://example.com/callback/\",\n \"notifyEmail\": \"example@gmail.com\",\n \"notifyPhone\": \"\",\n \"purpose\": \"GAME\"\n }\n}"
response = http.request(request)
puts response.read_body{
"msg": "Success.",
"code": "00000000",
"data": {
"tradeNo": "20220429052556PO71330000270184",
"outTradeNo": "ORDER123456",
"status": "success"
}
}付款
申请付款
POST
/
api
/
mapi
/
v1
/
payments
/
open
/
api
/
paymentOrderPay
申请付款
curl --request POST \
--url https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay \
--header 'Content-Type: application/json' \
--header 'signature: <api-key>' \
--data '
{
"charset": "utf-8",
"memberId": "2022000000008454",
"merchantId": "2022000000008454",
"requestTime": "2025-10-24T15:00:00.500+08:00",
"signType": "RSA",
"transType": "PAY",
"version": "2.0.0",
"data": {
"outTradeNo": "394916B2ADFD4D6CAD6CC624C88990D0",
"country": "ID",
"sourceAccount": "PHP",
"destinationCurrency": "PHP",
"trade": {
"amount": "100",
"currency": "IDR"
},
"payeeInfo": {
"paymentMethodType": "WALLET",
"accountInfo": {
"accountNo": "0812323233332",
"accountType": "",
"checkDigit": ""
},
"targetOrg": "DANA",
"payeeType": "PERSONAL",
"bankInfo": {
"bankCode": "",
"bankName": "",
"bankBranch": "",
"bankCity": "",
"corAccountNo": ""
},
"name": {
"firstName": "James",
"middleName": "Shri Williams",
"lastName": "Kanta",
"fullName": "James Shri Williams Kanta"
},
"document": {
"documentType": "",
"documentId": "",
"documentIssueDate": "",
"documentExpireDate": ""
},
"address": {
"address": "",
"city": "",
"state": "",
"zipCode": ""
},
"payeePhone": "08123456789",
"birthDate": "1996-09-01",
"email": "example@gmail.com"
},
"chargeOption": "",
"clearingRail": "LOCAL",
"userId": "abc123456789",
"payerInfo": {
"subMerchantNo": "",
"businessLegalName": "",
"registrationCountry": "",
"merchantCategoryCode": "",
"payerId": "",
"name": {
"firstName": "James",
"middleName": "Shri Williams",
"lastName": "Kanta",
"fullName": "James Shri Williams Kanta"
}
},
"expiryDays": "3",
"remark": "this is remark",
"reference": "this is reference",
"notifyUrl": "http://example.com/callback/",
"notifyEmail": "example@gmail.com",
"notifyPhone": "",
"purpose": "GAME"
}
}
'import requests
url = "https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay"
payload = {
"charset": "utf-8",
"memberId": "2022000000008454",
"merchantId": "2022000000008454",
"requestTime": "2025-10-24T15:00:00.500+08:00",
"signType": "RSA",
"transType": "PAY",
"version": "2.0.0",
"data": {
"outTradeNo": "394916B2ADFD4D6CAD6CC624C88990D0",
"country": "ID",
"sourceAccount": "PHP",
"destinationCurrency": "PHP",
"trade": {
"amount": "100",
"currency": "IDR"
},
"payeeInfo": {
"paymentMethodType": "WALLET",
"accountInfo": {
"accountNo": "0812323233332",
"accountType": "",
"checkDigit": ""
},
"targetOrg": "DANA",
"payeeType": "PERSONAL",
"bankInfo": {
"bankCode": "",
"bankName": "",
"bankBranch": "",
"bankCity": "",
"corAccountNo": ""
},
"name": {
"firstName": "James",
"middleName": "Shri Williams",
"lastName": "Kanta",
"fullName": "James Shri Williams Kanta"
},
"document": {
"documentType": "",
"documentId": "",
"documentIssueDate": "",
"documentExpireDate": ""
},
"address": {
"address": "",
"city": "",
"state": "",
"zipCode": ""
},
"payeePhone": "08123456789",
"birthDate": "1996-09-01",
"email": "example@gmail.com"
},
"chargeOption": "",
"clearingRail": "LOCAL",
"userId": "abc123456789",
"payerInfo": {
"subMerchantNo": "",
"businessLegalName": "",
"registrationCountry": "",
"merchantCategoryCode": "",
"payerId": "",
"name": {
"firstName": "James",
"middleName": "Shri Williams",
"lastName": "Kanta",
"fullName": "James Shri Williams Kanta"
}
},
"expiryDays": "3",
"remark": "this is remark",
"reference": "this is reference",
"notifyUrl": "http://example.com/callback/",
"notifyEmail": "example@gmail.com",
"notifyPhone": "",
"purpose": "GAME"
}
}
headers = {
"signature": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {signature: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
charset: 'utf-8',
memberId: '2022000000008454',
merchantId: '2022000000008454',
requestTime: '2025-10-24T15:00:00.500+08:00',
signType: 'RSA',
transType: 'PAY',
version: '2.0.0',
data: {
outTradeNo: '394916B2ADFD4D6CAD6CC624C88990D0',
country: 'ID',
sourceAccount: 'PHP',
destinationCurrency: 'PHP',
trade: {amount: '100', currency: 'IDR'},
payeeInfo: {
paymentMethodType: 'WALLET',
accountInfo: {accountNo: '0812323233332', accountType: '', checkDigit: ''},
targetOrg: 'DANA',
payeeType: 'PERSONAL',
bankInfo: {bankCode: '', bankName: '', bankBranch: '', bankCity: '', corAccountNo: ''},
name: {
firstName: 'James',
middleName: 'Shri Williams',
lastName: 'Kanta',
fullName: 'James Shri Williams Kanta'
},
document: {
documentType: '',
documentId: '',
documentIssueDate: '',
documentExpireDate: ''
},
address: {address: '', city: '', state: '', zipCode: ''},
payeePhone: '08123456789',
birthDate: '1996-09-01',
email: 'example@gmail.com'
},
chargeOption: '',
clearingRail: 'LOCAL',
userId: 'abc123456789',
payerInfo: {
subMerchantNo: '',
businessLegalName: '',
registrationCountry: '',
merchantCategoryCode: '',
payerId: '',
name: {
firstName: 'James',
middleName: 'Shri Williams',
lastName: 'Kanta',
fullName: 'James Shri Williams Kanta'
}
},
expiryDays: '3',
remark: 'this is remark',
reference: 'this is reference',
notifyUrl: 'http://example.com/callback/',
notifyEmail: 'example@gmail.com',
notifyPhone: '',
purpose: 'GAME'
}
})
};
fetch('https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'charset' => 'utf-8',
'memberId' => '2022000000008454',
'merchantId' => '2022000000008454',
'requestTime' => '2025-10-24T15:00:00.500+08:00',
'signType' => 'RSA',
'transType' => 'PAY',
'version' => '2.0.0',
'data' => [
'outTradeNo' => '394916B2ADFD4D6CAD6CC624C88990D0',
'country' => 'ID',
'sourceAccount' => 'PHP',
'destinationCurrency' => 'PHP',
'trade' => [
'amount' => '100',
'currency' => 'IDR'
],
'payeeInfo' => [
'paymentMethodType' => 'WALLET',
'accountInfo' => [
'accountNo' => '0812323233332',
'accountType' => '',
'checkDigit' => ''
],
'targetOrg' => 'DANA',
'payeeType' => 'PERSONAL',
'bankInfo' => [
'bankCode' => '',
'bankName' => '',
'bankBranch' => '',
'bankCity' => '',
'corAccountNo' => ''
],
'name' => [
'firstName' => 'James',
'middleName' => 'Shri Williams',
'lastName' => 'Kanta',
'fullName' => 'James Shri Williams Kanta'
],
'document' => [
'documentType' => '',
'documentId' => '',
'documentIssueDate' => '',
'documentExpireDate' => ''
],
'address' => [
'address' => '',
'city' => '',
'state' => '',
'zipCode' => ''
],
'payeePhone' => '08123456789',
'birthDate' => '1996-09-01',
'email' => 'example@gmail.com'
],
'chargeOption' => '',
'clearingRail' => 'LOCAL',
'userId' => 'abc123456789',
'payerInfo' => [
'subMerchantNo' => '',
'businessLegalName' => '',
'registrationCountry' => '',
'merchantCategoryCode' => '',
'payerId' => '',
'name' => [
'firstName' => 'James',
'middleName' => 'Shri Williams',
'lastName' => 'Kanta',
'fullName' => 'James Shri Williams Kanta'
]
],
'expiryDays' => '3',
'remark' => 'this is remark',
'reference' => 'this is reference',
'notifyUrl' => 'http://example.com/callback/',
'notifyEmail' => 'example@gmail.com',
'notifyPhone' => '',
'purpose' => 'GAME'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"signature: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay"
payload := strings.NewReader("{\n \"charset\": \"utf-8\",\n \"memberId\": \"2022000000008454\",\n \"merchantId\": \"2022000000008454\",\n \"requestTime\": \"2025-10-24T15:00:00.500+08:00\",\n \"signType\": \"RSA\",\n \"transType\": \"PAY\",\n \"version\": \"2.0.0\",\n \"data\": {\n \"outTradeNo\": \"394916B2ADFD4D6CAD6CC624C88990D0\",\n \"country\": \"ID\",\n \"sourceAccount\": \"PHP\",\n \"destinationCurrency\": \"PHP\",\n \"trade\": {\n \"amount\": \"100\",\n \"currency\": \"IDR\"\n },\n \"payeeInfo\": {\n \"paymentMethodType\": \"WALLET\",\n \"accountInfo\": {\n \"accountNo\": \"0812323233332\",\n \"accountType\": \"\",\n \"checkDigit\": \"\"\n },\n \"targetOrg\": \"DANA\",\n \"payeeType\": \"PERSONAL\",\n \"bankInfo\": {\n \"bankCode\": \"\",\n \"bankName\": \"\",\n \"bankBranch\": \"\",\n \"bankCity\": \"\",\n \"corAccountNo\": \"\"\n },\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n },\n \"document\": {\n \"documentType\": \"\",\n \"documentId\": \"\",\n \"documentIssueDate\": \"\",\n \"documentExpireDate\": \"\"\n },\n \"address\": {\n \"address\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"zipCode\": \"\"\n },\n \"payeePhone\": \"08123456789\",\n \"birthDate\": \"1996-09-01\",\n \"email\": \"example@gmail.com\"\n },\n \"chargeOption\": \"\",\n \"clearingRail\": \"LOCAL\",\n \"userId\": \"abc123456789\",\n \"payerInfo\": {\n \"subMerchantNo\": \"\",\n \"businessLegalName\": \"\",\n \"registrationCountry\": \"\",\n \"merchantCategoryCode\": \"\",\n \"payerId\": \"\",\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n }\n },\n \"expiryDays\": \"3\",\n \"remark\": \"this is remark\",\n \"reference\": \"this is reference\",\n \"notifyUrl\": \"http://example.com/callback/\",\n \"notifyEmail\": \"example@gmail.com\",\n \"notifyPhone\": \"\",\n \"purpose\": \"GAME\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("signature", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay")
.header("signature", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"charset\": \"utf-8\",\n \"memberId\": \"2022000000008454\",\n \"merchantId\": \"2022000000008454\",\n \"requestTime\": \"2025-10-24T15:00:00.500+08:00\",\n \"signType\": \"RSA\",\n \"transType\": \"PAY\",\n \"version\": \"2.0.0\",\n \"data\": {\n \"outTradeNo\": \"394916B2ADFD4D6CAD6CC624C88990D0\",\n \"country\": \"ID\",\n \"sourceAccount\": \"PHP\",\n \"destinationCurrency\": \"PHP\",\n \"trade\": {\n \"amount\": \"100\",\n \"currency\": \"IDR\"\n },\n \"payeeInfo\": {\n \"paymentMethodType\": \"WALLET\",\n \"accountInfo\": {\n \"accountNo\": \"0812323233332\",\n \"accountType\": \"\",\n \"checkDigit\": \"\"\n },\n \"targetOrg\": \"DANA\",\n \"payeeType\": \"PERSONAL\",\n \"bankInfo\": {\n \"bankCode\": \"\",\n \"bankName\": \"\",\n \"bankBranch\": \"\",\n \"bankCity\": \"\",\n \"corAccountNo\": \"\"\n },\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n },\n \"document\": {\n \"documentType\": \"\",\n \"documentId\": \"\",\n \"documentIssueDate\": \"\",\n \"documentExpireDate\": \"\"\n },\n \"address\": {\n \"address\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"zipCode\": \"\"\n },\n \"payeePhone\": \"08123456789\",\n \"birthDate\": \"1996-09-01\",\n \"email\": \"example@gmail.com\"\n },\n \"chargeOption\": \"\",\n \"clearingRail\": \"LOCAL\",\n \"userId\": \"abc123456789\",\n \"payerInfo\": {\n \"subMerchantNo\": \"\",\n \"businessLegalName\": \"\",\n \"registrationCountry\": \"\",\n \"merchantCategoryCode\": \"\",\n \"payerId\": \"\",\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n }\n },\n \"expiryDays\": \"3\",\n \"remark\": \"this is remark\",\n \"reference\": \"this is reference\",\n \"notifyUrl\": \"http://example.com/callback/\",\n \"notifyEmail\": \"example@gmail.com\",\n \"notifyPhone\": \"\",\n \"purpose\": \"GAME\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://mpgwpre.payallglobal.com/mp-gateway/api/mapi/v1/payments/open/api/paymentOrderPay")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["signature"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"charset\": \"utf-8\",\n \"memberId\": \"2022000000008454\",\n \"merchantId\": \"2022000000008454\",\n \"requestTime\": \"2025-10-24T15:00:00.500+08:00\",\n \"signType\": \"RSA\",\n \"transType\": \"PAY\",\n \"version\": \"2.0.0\",\n \"data\": {\n \"outTradeNo\": \"394916B2ADFD4D6CAD6CC624C88990D0\",\n \"country\": \"ID\",\n \"sourceAccount\": \"PHP\",\n \"destinationCurrency\": \"PHP\",\n \"trade\": {\n \"amount\": \"100\",\n \"currency\": \"IDR\"\n },\n \"payeeInfo\": {\n \"paymentMethodType\": \"WALLET\",\n \"accountInfo\": {\n \"accountNo\": \"0812323233332\",\n \"accountType\": \"\",\n \"checkDigit\": \"\"\n },\n \"targetOrg\": \"DANA\",\n \"payeeType\": \"PERSONAL\",\n \"bankInfo\": {\n \"bankCode\": \"\",\n \"bankName\": \"\",\n \"bankBranch\": \"\",\n \"bankCity\": \"\",\n \"corAccountNo\": \"\"\n },\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n },\n \"document\": {\n \"documentType\": \"\",\n \"documentId\": \"\",\n \"documentIssueDate\": \"\",\n \"documentExpireDate\": \"\"\n },\n \"address\": {\n \"address\": \"\",\n \"city\": \"\",\n \"state\": \"\",\n \"zipCode\": \"\"\n },\n \"payeePhone\": \"08123456789\",\n \"birthDate\": \"1996-09-01\",\n \"email\": \"example@gmail.com\"\n },\n \"chargeOption\": \"\",\n \"clearingRail\": \"LOCAL\",\n \"userId\": \"abc123456789\",\n \"payerInfo\": {\n \"subMerchantNo\": \"\",\n \"businessLegalName\": \"\",\n \"registrationCountry\": \"\",\n \"merchantCategoryCode\": \"\",\n \"payerId\": \"\",\n \"name\": {\n \"firstName\": \"James\",\n \"middleName\": \"Shri Williams\",\n \"lastName\": \"Kanta\",\n \"fullName\": \"James Shri Williams Kanta\"\n }\n },\n \"expiryDays\": \"3\",\n \"remark\": \"this is remark\",\n \"reference\": \"this is reference\",\n \"notifyUrl\": \"http://example.com/callback/\",\n \"notifyEmail\": \"example@gmail.com\",\n \"notifyPhone\": \"\",\n \"purpose\": \"GAME\"\n }\n}"
response = http.request(request)
puts response.read_body{
"msg": "Success.",
"code": "00000000",
"data": {
"tradeNo": "20220429052556PO71330000270184",
"outTradeNo": "ORDER123456",
"status": "success"
}
}Authorizations
Example: MIIEpQIBAAKCAQEA...(Base64编码的签名字符串)
加签
加签是开放平台和商户对于交互消息完整性的校验。加签行为主要发生两个部分:
- 商户服务器端针对向PayAllGlobal开放平台发送的请求报文进行加签;
- PayAllGlobal开放平台针对通知商户的异步消息进行加签。 PayAllGlobal平台要求使用 RSA 私钥进行加签, 使用 RSA 公钥进行验签。 因此,在以上两部分描述的交互中, 存在商户公私钥、PayAllGlobal 公私钥,开发者需要使用商户私钥,对第一部分报文进行加签,使用 PayAllGlobal 公钥对第二部分消息进行验签。
加签规则如下:
使用商户私钥对请求体进行 SHA256withRSA 签名后,再进行 Base64 编码的结果。
- 使用 商户私钥对待
request.body进行签名(SHA256WithRSA 计算原始数据的SHA-256哈希值。 使用私钥对哈希值进行签名,即使用私钥对哈希值进行RSA加密。此时得到的加密结果就是数字签名。);
Signature signature = Signature.getInstance("SHA256withRSA");
signature.initSign(privateKey);
// 计算 SHA256withRSA 签名时,需要以 utf-8 的编码转换 byte 流,否则可能导致含中文参数的签名计算不正确
signature.update(request.body);
byte[] signedHash = signature.sign();
- 将加签内容进行 Base64 编码;
String signature = Base64.getEncoder().encodeToString(signedHash);
- 将编码后的内容放在请求头部 signature 参数中。 注意,加签是对 request.body 进行签名,当查询等 request.body 为空时,则无需加签。
Body
application/json
支付查询基础请求对象
交互数据的编码【utf-8】
Example:
"utf-8"
机构号
Example:
"2022000000008454"
商户号
Example:
"2022000000008454"
请求时间(ISO 8601 格式,带时区)
Example:
"2025-10-24T15:00:00.500+08:00"
报文签名类型
Example:
"RSA"
交易类型
Available options:
PAY, CREDIT_CARD, 3D_PREAUTH_VOIDS, 3D_PREAUTH_COMPLETION, REFUND, VOIDS, QUERY, TRANSFER, DOWNLOAD, REGISTRATION, FILEUPLOAD, INQUIRYREGISTRATIONSTATUS, AUTHORIZE Example:
"PAY"
接口版本,当前版本为【2.0.0】,目前只能传2.0.0,不能不传
Example:
"2.0.0"
Show child attributes
Show child attributes
⌘I