上海翻譯公司完成銀行系統(tǒng)介紹英文翻譯
MasaPay
Merchant Interface for Internet Payment
Record of Revised Versions
Version |
Date Revised |
Author |
Version Change |
1.0 |
2013-04-22 |
Zhou Ying |
First draft |
1.1 |
2013-04-24 |
Zhou Ying |
Remove products’ names and descriptions |
1.7 |
2013-06-21 |
Zhou Ying |
Add payment currencies and exchange rates |
1.8 |
2013-07-26 |
Zhou Ying |
Add currencies
Modify products’ names and descriptions to 1000 |
1.9 |
2013-08-20 |
Zhou Ying |
api order receiving version is upgraded to 1.1
2.4 Add errCode、errMsg on page callback
4.2 Add errCode、errMsg on merchant notification interface |
2.0 |
2013-08-21 |
Zhou Ying |
Gateway version is upgraded to 1.2
2.3 Merchants order submitting interface changes:
Add billing address and delivery address
3.3 Merchants payment submitting interface changes:
Payment ip is changed to non-null
Payment email is changed to non-null
Cardholder email is changed to non-null
Delivery country, state/city is changed to non-null
Name is changed to last name, first name, and signature
Add device Fingerprint ID and signature |
2.0 |
2013/9/5 |
Zhou Ying |
Order IP is changed to non-null |
2.1 |
2013/10/22 |
Zhou Ying |
Add 8.api uploading interface of express order |
2.2 |
2013/10/31 |
Zhou Ying |
Modify the following nullable fields into non-null according to the requirements of operation and risk management
Internet Payment Business:
billFirstName
billLastName
billAdderess
billPostalCode
billCountry
billState
billCity
billEmail
billPhoneNumber
shippingFirstName
shippingLastName
shippingAdderess
shippingPostalCode
shippingCity
shippingEmail
shippingPhoneNumber
registerUserEmail
registerTime
registerIp
registerTerminal
orderIp
orderTerminal
API Payment Business:
billName
billAdderess
billPostalCode
billCompany
billCountry
billState
billCity
billEmail
billPhoneNumber
shippingAdderess
shippingPostalCode
shippingcompany
shippingCity
shippingEmail
shippingPhoneNumber
deviceFingerprintID
registerUserEmail
registerTime
registerIp
registerTerminal
orderIp
orderTerminal |
2.2 |
2013/12/10 |
4.2.1 |
resultCode Add new return types |
|
|
|
|
|
|
|
|
1 Document Description
1.1 Function Description
Through MasaPay’s payment channel, payers can make payments to merchants directly. Merchant website price use MasaPay supported currencies. Payers use supported currencies of relevant payment methods to make payments.
1.2 Target Readers
MasaPay Internet Payment Merchant Interface document is target to website developers, website maintenance personnel, and website management professionals who have certain website developing abilities and are familiar with one of ASP, PHP, JAVA, ASP.NET and such programming languages and website development of SQL database languages.
2 Internet Collection Business
2.1 Function Outline
Merchant Order Submitting Interface Implements: Merchants submit order information and detail information to MasaPay Internet Order Receiving System.
Implementation of Merchant Notification Interface: Notify merchants about successful order submission after successful payment.
2.2 System Interaction
Figure 2.1System interaction figure
商戶系統(tǒng) |
Merchant system |
MasaPay系統(tǒng) |
MasaPay system |
seq支付請求 |
seq payment request |
1.構(gòu)造請求數(shù)據(jù) |
1. Construct request data |
2. 調(diào)用《商戶提交訂單接口》發(fā)送請求 |
2. Call Merchant Order Submitting Interface to send request |
3. 請求的交易 |
Requested business |
seq支付通知 |
seq payment notification |
4. 通知支付結(jié)果,見《通知商戶接口》 |
4. Notify payment results, see Merchant Notification Interface |
5. 接收后應(yīng)答,見《商戶應(yīng)答》 |
5. Response after receiving, see Merchant Response |
6. 對相應(yīng)的數(shù)據(jù)進(jìn)行處理 |
6. Process relevant data |
2.3 Merchant Order Submitting Interface
Initiator: Merchant system
Recipient: MasaPay Internet Order Receiving Interface
Submission type: POST
Produce submitting address:
https://mas.masapay.com/mas/receiveMerchantOrder.htm
Test submitting address:
https://mas-sandbox.masapay.com/mas/receiveMerchantOrder.htm
Submission parameters:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocate by MasaPay when merchant opens account. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
Business Parameter |
merchantOrderNo |
Merchant order no. |
String(256) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
goodsName |
Merchant name |
String(1000) |
Product name |
No |
goodsDesc |
Product description |
String(2000) |
The format is: product name 1^product specification 1^purchase quantity 1^product price 1^product display website 1|product name 2^product specification 2^purchase quantity 2^product price 2^product display website 2|…… |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
orderAmount |
Order amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
payMode |
Payment mode |
String(2) |
Fill out
10 International credit cards
20 local third party payment
30 offline remittance
90 UnionPay payment |
Yes |
orgCode |
Payment organization code |
String(10) |
Fill out
International credit cards: VISA, MASTER, JCB, AME, DINERSCLUB, DISCOVER
Local third party payment: WEBMONEY,QIWI,WALLETONE,PAYON
Offline remittance: WESTERNUNION , MONEYGRAM
UnionPay payment: UPOP |
Yes |
payerAuth |
Whether payment is authorized |
String(1) |
Y verification N no verification, the default is no verification |
Yes |
directFlag |
Whether connect directly |
String(1) |
N non-direct D direct E embedded |
No |
allowDuplicate |
Whether allow duplicated payment |
String(1) |
Y allow N don’t allow, the default is not allow |
Yes |
submitTime |
Submitting time |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
expiryTime |
Expiry time |
String(14) |
year month day hour minute second
eg: 20121117020101 |
Yes |
pageUrl |
Front desk call back URL |
String(256) |
For jumping to merchant appointed URL after payment is completed |
Yes |
bgUrl |
Notify URL |
String(256) |
The address for notifying merchant order submitting results |
Yes |
ext1 |
Extended fields |
String(256) |
Return the parameter when notifying merchant about order payment results, cannot include =, & and such special characters. |
Yes |
ext2 |
Extended fields |
String(256) |
Return the parameter when notifying merchant about order payment results, cannot include =, & and such special characters. |
Yes |
remark |
Remark |
String(256) |
For transmission of merchant special business information, only valid when merchant and masapay have agreement.
Format: parameter name 1^parameter valud 1|parameter name 2^parameter value 2| |
Yes |
Billing Information |
billFirstName |
Billing first name |
String(100) |
Billing first name |
No |
billLastName |
Billing last name |
String(100) |
Billing last name |
No |
billAdderess |
Billing address |
String(200) |
Billing address |
No |
billPostalCode |
Billing postcode |
String(20) |
Not exceed 20 digits |
No |
billCompany |
Billing company name |
String(200) |
Billing company name |
Yes |
billCountry |
Billing country |
String(20) |
Billing country ISO Standard Country Codes |
No |
billState |
Billing state/province |
String(20) |
Mandatory for the United States and Canada, can be null for other countries
two-character state,province, or territory codes. |
No |
billCity |
Billing city |
String(20) |
Billing city |
No |
billEmail |
Billing email |
String(100) |
Billing email |
No |
billPhoneNumber |
Billing Tel |
String(20) |
Numbers only, not exceed 20 digits |
No |
Shipping Information |
shippingFirstName |
Shipping first name |
String(100) |
Shipping first name |
No |
shippingLastName |
Shipping last name |
String(100) |
Shipping last name |
No |
shippingAdderess |
Shipping address |
String(200) |
Shipping address |
No |
shippingPostalCode |
Shipping postcode |
String(20) |
Not exceed 20 digits |
No |
shippingCompany |
Shipping company name |
String(200) |
Shipping company name |
No |
shippingCountry |
Shipping country |
String(20) |
Shipping country ISO Standard Country Codes |
No |
shippingState |
Shipping state/province |
String(20) |
Mandatory for the United States and Canada, can be null for other countries
two-character state,province, or territory codes. |
No |
shippingCity |
Shipping city |
String(20) |
Shipping city |
No |
shippingEmail |
Shipping email |
String(100) |
Shipping email |
No |
shippingPhoneNumber |
Shipping Tel |
String(20) |
Numbers only, not exceed 20 digits |
No |
Risk Control Parameter |
registerUserId |
Register user ID |
String(20) |
Unique ID for merchant website customer |
Yes |
registerUserEmail |
Register user email |
String(60) |
Register user email |
No |
registerTime |
Register time |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
registerIp |
Register IP |
String(20) |
eg: [202.96.209.16] |
No |
registerTerminal |
Register terminal device |
String(20) |
00 PC 01 Cell phone 02 Others |
No |
orderIp |
Order IP |
String(20) |
IP address when payers submit order
eg: [202.96.209.16] |
No |
orderTerminal |
Terminal device |
String(20) |
Terminal device when payers submit order
00 PC 01 Cell phone 02 Others |
No |
ext3 |
Extension |
String(256) |
Extension fields |
Yes |
ext4 |
Extension |
String(256) |
Extension fields |
Yes |
signMsg |
Signature |
String(256) |
See signature element description |
No |
Signature element description:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&merchantOrderNo=10000121&goodsName=Women’s Clothing &goodsDesc=product name 1^product specification 1^purchase quantity 1^product price 1^product display website 1|product name 2^product specification 2^purchase quantity 2^product price 2^product display website
2¤cyCode=USD&orderAmount=1000&payMode=20&orgCode=WEBMONEY&directFlag=D&allowDuplicate=N&submitTime=20121117020101&expiryTime=20121117030101&pageUrl=https://www.masapay.com&bgUrl=https://www.masapay.com&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
2.4 Page Callback
Initiator: Internet Order Receiving Interface
Recipient: Merchant system
Notification Address: pageUrl+POST request provided when merchant make an order
Parameter:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Business Parameter |
merchantOrderNo |
Merchant order no. |
String(64) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
masapayOrderNo |
Business serial no. |
String(16) |
MasaPay system business serial no. |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
orderAmount |
Order amount |
String(18) |
Monetary unit Yuan |
No |
payCurrencyCode |
Payment currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
payAmount |
Order amount |
String(18) |
Monetary unit Yuan |
No |
rates |
Exchange rate |
String(20) |
Be accurate 5 digits after dot |
No |
resultCode |
Result |
String(4) |
10 Successful payment 11 Unsuccessful payment 12 Payment processing |
No |
errCode |
Error code |
String(10) |
Error code returned when unsuccessful payment is made. |
Yes |
errMsg |
Error message |
String(256) |
Error message returned when unsuccessful payment is made. |
Yes |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
Note:
Final payment result shall be subject to the notification.
3 API Payment Receiving Business
3.1 Function Outline
Merchant Order Submitting Interface implements: Merchants submit order information and payment information to MasaPay API Order Receiving System.
3.2 System Interaction
Figure 3.1 System interaction figure
商戶系統(tǒng) |
Merchant system |
MasaPay API系統(tǒng) |
MasaPay API system |
seq訂單支付請求 |
seq order payment request |
1. 構(gòu)造請求數(shù)據(jù) |
1. Construct request data |
2. webservice 訂單支付請求 |
2. webservice order payment request |
3. 處理訂單支付請求 |
3. Handle order payment request |
4. 返回受理結(jié)果 |
4. Return results |
seq通知支付結(jié)果 |
seq notify payment results |
5. 通知商戶支付成功 |
5. Notify merchant about successful payment |
6. 返回OK |
6.Return OK |
7. 對通知結(jié)果進(jìn)行處理 |
7. Process notification results |
3.3 Merchant Order Payment Interface
3.3.1 Request
Initiator: Merchant system
Recipient: MasaPay API Internet Order Receiving Interface
Produce submitting address:
https://open.masapay.com/masapi/order/ReceiveMerchantOrder?wsdl
Test submitting address:
https://open-sandbox.masapay.com/masapi/order/ReceiveMerchantOrder?wsdl
Submission parameters:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocate by MasaPay when merchant opens account. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
Business Parameter |
merchantOrderNo |
Merchant order no. |
String(256) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
goodsName |
Merchant name |
String(1000) |
Product name |
No |
goodsDesc |
Product description |
String(2000) |
The format is: product name 1^product specification 1^purchase quantity 1^product price 1^product display website 1|product name 2^product specification 2^purchase quantity 2^product price 2^product display website 2|…… |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
orderAmount |
Order amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
payerAuth |
Whether payment is authorized |
String(1) |
Y verification N no verification, the default is no verification |
Yes |
allowDuplicate |
Whether allow duplicated payment |
String(1) |
Y allow N don’t allow, the default is not allow |
Yes |
submitTime |
Submitting time |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
expiryTime |
Expiry time |
String(14) |
year month day hour minute second
eg: 20121117020101 |
Yes |
bgUrl |
Notify URL |
String(256) |
The address for notifying merchant order submitting results |
Yes |
ext1 |
Extended fields |
String(256) |
Return the parameter when notifying merchant about order payment results, cannot include =, & and such special characters. |
Yes |
ext2 |
Extended fields |
String(256) |
Return the parameter when notifying merchant about order payment results, cannot include =, & and such special characters. |
Yes |
remark |
Remark |
String(256) |
For transmission of merchant special business information, only valid when merchant and masapay have agreement.
Format: parameter name 1^parameter valud 1|parameter name 2^parameter value 2| |
Yes |
Payment Parameter |
payMode |
Payment Mode |
String(2) |
10 International credit cards |
No |
orgCode |
Payment organization code |
String(10) |
International credit cards :
VISA,MASTER,JCB,AME,DINERSCLUB,DISCOVER |
No |
cardNumber |
Card No. |
String(19) |
Numbers only, not exceed 19 digits |
No |
cardHolderFirstName |
Card holder’s first name |
String(100) |
Card holder’s first name |
No |
cardHolderLastName |
Card holder’s last name |
String(100) |
Card holder’s last name |
No |
cardExpirationMonth |
Card expiration Month |
String(2) |
Numbers only, not exceed 2 digits |
No |
cardExpirationYear |
Card expiration Year |
String(4) |
Numbers only, not exceed 2 digits |
No |
securityCode |
Security Code |
String(3) |
Numbers only, not exceed 3 digits |
No |
cardHolderEmail |
Card holder’s email |
String(100) |
Card holder’s email |
No |
cardHolderPhoneNumber |
Card holder’s tel |
String(20) |
Numbers only, not exceed 20 digits |
Yes |
payExt1 |
Payment extension1 |
String(100) |
Standby |
Yes |
payExt2 |
payment extension2 |
String(100) |
Standby |
Yes |
Billing Information |
billName |
Billing first name |
String(100) |
Billing first name |
No |
billAdderess |
Billing last name |
String(100) |
Billing last name |
No |
billPostalCode |
Billing address |
String(200) |
Billing address |
No |
billCompany |
Billing postcode |
String(20) |
Not exceed 20 digits |
No |
billCountry |
Billing company name |
String(200) |
Billing company name |
Yes |
billState |
Billing country |
String(20) |
Billing country ISO Standard Country Codes |
No |
billCity |
Billing state/province |
String(20) |
Mandatory for the United States and Canada, can be null for other countries
two-character state,province, or territory codes. |
No |
billEmail |
Billing city |
String(20) |
Billing city |
No |
billPhoneNumber |
Billing email |
String(100) |
Billing email |
No |
Shipping Information |
shippingName |
Shipping name |
String(100) |
Name of recipient |
No |
shippingAdderess |
Shipping address |
String(200) |
Shipping address |
No |
shippingPostalCode |
Shipping postcode |
String(20) |
Not exceed 20 digits |
No |
shippingCompany |
Shipping company name |
String(200) |
Shipping company name |
No |
shippingCountry |
Shipping country |
String(20) |
Shipping country ISO Standard Country Codes |
No |
shippingState |
Shipping state/province |
String(20) |
Mandatory for the United States and Canada, can be null for other countries
two-character state,province, or territory codes. |
No |
shippingCity |
Shipping city |
String(20) |
Shipping city |
No |
shippingEmail |
Shipping email |
String(100) |
Shipping email |
No |
shippingPhoneNumber |
Shipping Tel |
String(20) |
Numbers only, not exceed 20 digits |
No |
Risk Control Information |
deviceFingerprintID |
Device finger print ID |
String(60) |
1.Device finger print ID is
session_token
session_token Generating rule:
m+merchantId+merchantOrderNo+ submitTime
2 Introducing the following url at page js
sandbox environment:
https://h.online-metrix.net/fp/check.js?org_id=1snn5n9w&session_id=masapay1{session_token}
generating environment:
https://h.online-metrix.net/fp/check.js?org_id=k8vif92e&session_id=masapay2{session_token} |
No |
payerName |
Payer name |
String(60) |
Payer name |
Yes |
payerMobile |
Payer cell phone |
String(20) |
Payer cell phone |
Yes |
payerEmail |
Payer email |
String(60) |
Payer email |
Yes |
registerUserId |
Registered user ID |
String(20) |
The only ID in merchant website |
Yes |
registerUserEmail |
Registered user email |
String(60) |
Register email at merchant website |
No |
registerTime |
Register time |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
registerIp |
Register IP |
String(20) |
eg: [202.96.209.16] |
No |
registerTerminal |
Register terminal device |
String(20) |
00 PC 01 Cell phone 02 Others |
No |
orderIp |
Order IP |
String(20) |
IP address when payers submit order
eg: [202.96.209.16] |
No |
orderTerminal |
Terminal device |
String(20) |
Terminal device when payers submit order
00 PC 01 Cell phone 02 Others |
No |
ext3 |
Extension |
String(256) |
Extension fields |
Yes |
ext4 |
Extension |
String(256) |
Extension fields |
Yes |
signMsg |
Signature |
String(256) |
See signature element description |
No |
|
|
|
|
|
|
Participated signature element description:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&merchantOrderNo=10000121&goodsName=Women’s Clothing &goodsDesc=product name 1^product specification 1^purchase quantity 1^product price 1^product display website 1|product name 2^product specification 2^purchase quantity 2^product price 2^product display website 2¤cyCode=USD&orderAmount=1000 &allowDuplicate=N&submitTime=20121117020101&expiryTime=20121117030101& bgUrl=https://www.masapay.com&payMode=10&orgCode=visa&cardNumber=4000000000000000&cardHolderFirstName=jerry&cardHolderLastName=jin &cardExpirationMonth=09&cardExpirationYear=14&securityCode=780&[email protected]&cardHolderPhoneNumber=13788888888 &deviceFingerprintID=HJH*098&*GYUJHG& shippingCountry =US&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
3.3.2 Return
Return data as XML format to merchant.
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
errCode |
Error code |
String(10) |
Error code returned when unsuccessful payment is made. |
Yes |
errMsg |
Error message |
String(256) |
Error message returned when unsuccessful payment is made. |
Yes |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
Business Parameter |
merchantOrderNo |
Merchant order no. |
String(64) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
masapayOrderNo |
Business serial no. |
String(16) |
MasaPay system business serial no. |
No |
submitTime |
Submission time |
String(14) |
Time when merchant submit order
Year month day hour minute second
eg: 20121117020101 |
No |
dealTime |
Deal time |
String(14) |
Time when MasaPay business completed
Year month day hour minute second
eg: 20121117020101 |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen |
No |
orderAmount |
Order amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent
|
No |
payCurrencyCode |
Payment currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen |
No |
rates |
Exchange rate |
String(20) |
Be accurate 5 digits after dot |
No |
paidAmount |
Paid amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
payMode |
Payment mode |
String(2) |
10 International credit cards |
No |
orgCode |
Payment organization code |
String(10) |
International credit cards: VISA,MASTER,JCB,AME,DINERSCLUB |
Yes |
resultCode |
Result |
String(2) |
00 Accept 10 Payment succeeded 11 Payment failed |
No |
riskLevel |
Risk level |
String(2) |
00 None,01 Rejected by risk control,02 Suspicious
03 Business suspended |
Yes |
riskOccurCount |
Cumulative quantity of risk orders |
String(4) |
Cumulative quantity of risk orders |
Yes |
riskDesc |
Risk description |
String(256) |
Risk note |
Yes |
ext1 |
Extension |
String(256) |
Return original order merchant submitted ext1 |
Yes |
ext2 |
Extension |
String(256) |
Return original order merchant submitted ext2 |
Yes |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
Participated signature element description:
version=1.2&charset=utf-8&language=en&signType=SHA256&merchantOrderNo=10000121&masapayOrderNo=880111123&submitTime=20121117020101&dealTime=20121117030101¤cyCode=USD&orderAmount=1000&payCurrencyCode=CNY&rates=6.21321&paidAmount=1000&payMode=20&orgCode=WEBMONEY&resultCode=10&riskLevel=00& riskOccurCount=10&riskDesc=norisk&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
4 Merchant Notification of Payment Result
4.1 Function Outline
Merchant Notification Interface implements: Notify merchant about system order payment is successful after successful payment.
4.2 Merchant Notification Interface
4.2.1 Callback Merchant’s URL
Initiator: Internet Order Receiving Interface
Recipient: Merchant system
Notification address: bgUrl + POST request provided by merchant when making order
Parameter:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
Business Parameter |
merchantOrderNo |
Merchant order no. |
String(64) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
masapayOrderNo |
Business serial no. |
String(16) |
MasaPay system business serial no. |
No |
submitTime |
Submission time |
String(14) |
Time when merchant submit order
Year month day hour minute second
eg: 20121117020101 |
No |
dealTime |
Deal time |
String(14) |
Time when MasaPay business completed
Year month day hour minute second
eg: 20121117020101 |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
orderAmount |
Order amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
payCurrencyCode |
Payment currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen |
No |
rates |
Exchange rate |
String(20) |
Be accurate 5 digits after dot |
No |
paidAmount |
Paid amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
payMode |
Payment mode |
String(2) |
Fill out
10 International credit cards
20 local third party payment
30 offline remittance
90 UnionPay payment |
No |
orgCode |
Payment organization code |
String(10) |
Fill out
International credit cards: VISA, MASTER, JCB, AME, DINERSCLUB, DISCOVER
Local third party payment: WEBMONEY,QIWI,WALLETONE,PAYON
Offline remittance: WESTERNUNION , MONEYGRAM
UnionPay payment: UPOP |
Yes |
resultCode |
Result |
String(2) |
10 Successful payment 11 Unsuccessful payment 12 Checking |
No |
errCode |
Error code |
String(10) |
Error code returned when unsuccessful payment is made. |
Yes |
errMsg |
Error message |
String(256) |
Error message returned when unsuccessful payment is made. |
Yes |
riskLevel |
Risk level |
String(2) |
00 None,01 Rejected by risk control,02 Suspicious
03 Business suspended |
Yes |
riskOccurCount |
Cumulative quantity of risk orders |
String(4) |
Cumulative quantity of risk orders |
Yes |
riskDesc |
Risk description |
String(256) |
Risk note |
Yes |
ext1 |
Extension |
String(256) |
Return original order merchant submitted ext1 |
Yes |
ext2 |
Extension |
String(256) |
Return original order merchant submitted ext2 |
Yes |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
|
|
|
|
|
|
Signature element description:
version=1.2&charset=utf-8&language=en&signType=SHA256&merchantOrderNo=10000121&masapayOrderNo=880111123&submitTime=20121117020101&dealTime=20121117030101¤cyCode=USD&orderAmount=1000&payCurrencyCode=CNY&rates=6.21321&paidAmount=1000&payMode=20&orgCode=WEBMONEY&resultCode=10&riskLevel=00& riskOccurCount=10&riskDesc=norisk&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
4.2.2 Merchant Response
MasaPay notifies merchant through bgUrl in back stage. After handled by merchant system, it needs to be sent back to MasaPay system as character string format. The content is as following:
Return |
Description |
OK |
Successful. MasaPay system will not resend notice if receives this result. |
No return or other character |
Unsuccessful, MasaPay system will re-notify if receives this result. |
5 API Inquiry Business of Collection Order
5.1 Function Outline
Merchant Inquiry Interface implements: Search for MasaPay transaction records in a certain period or any transaction record on merchant website.
5.2 System Interaction
商戶系統(tǒng) |
Merchant system |
MasaPay系統(tǒng) |
MasaPay system |
1. 構(gòu)造請求數(shù)據(jù) |
1. Construct request data |
2. 調(diào)用《商戶提交訂單接口》發(fā)送請求 |
2.Call Merchant Order Submitting Interface to send request |
3. 請求處理 |
3. Request for solutions |
4. 返回結(jié)果 |
4. Return results |
5. 對相應(yīng)的數(shù)據(jù)進(jìn)行處理 |
5. Process relevant data |
5.3 Merchant Query Interface
5.3.1 Request
Produce submitting address:
https://open.masapay.com/masapi/order/QueryMerchantOrder?wsdl
Test submitting address:
https://open-sandbox.masapay.com/masapi/order/QueryMerchantOrder?wsdl
Input Parameter:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocate by MasaPay when merchant opens account. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
Business Parameter |
queryType |
Query Type |
String(1) |
0 query for individual according to MasaPay business serial no.
1 according to merchant order no.
2 bulk query according to business ending time, successful orders only |
No |
masapayOrderNo |
Business serial no. |
String(16) |
Fill out when query type is 0 |
Yes |
merchantOrderNo |
Merchant order no. |
String(64) |
Fill out when query type is 1 |
Yes |
startTime |
Starting time of order submission |
String(14) |
Fill out when query type is 2
Year month day hour minute second
eg: 20121117020101 |
Yes |
endTime |
Ending time of order submission |
String(14) |
Fill out when query type is 2
Year month day hour minute second
eg: 20121117020101
Limited time period is 14 days, and spacing is 24 hours. |
Yes |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
|
|
|
|
|
|
Note:
If merchant has duplicated submission, there would be more results according to merchant order number.
Signature element description:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&queryType=1&merchantOrderNo=10000121&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
5.3.2 Return
Send data back to merchant as XML.
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocate by MasaPay when merchant opens account. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
errCode |
Error code |
String(10) |
Error code returned when unsuccessful payment is made. |
Yes |
errMsg |
Error message |
String(256) |
Error message returned when unsuccessful payment is made. |
Yes |
recordCount |
Record count |
String(10) |
Record count |
No |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
Order Information (list) |
merchantOrderNo |
Merchant order no. |
String(60) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
masapayOrderNo |
Business serial no. |
String(16) |
MasaPay system business serial no. |
No |
orderAmount |
Order amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
orderTime |
Submission time |
String(14) |
Time when merchant submit order
Year month day hour minute second
eg: 20121117020101 |
No |
dealTime |
Deal time |
String(14) |
Year month day hour minute second
eg: 20121117020101 |
No |
status |
Order status |
String(1) |
N not paid
S paid successful
F paid failed
I during payment
C closed |
No |
payMode |
Payment mode |
String(2) |
10 International credit cards
20 local third party payment
30 offline remittance
90 UnionPay payment |
Yes |
orgCode |
Payment organization code |
String(10) |
Fill out
International credit cards: VISA, MASTER, JCB, AME, DINERSCLUB, DISCOVER
Local third party payment: WEBMONEY,QIWI,WALLETONE,PAYON
Offline remittance: WESTERNUNION , MONEYGRAM
UnionPay payment: UPOP |
Yes |
paidAmount |
Paid amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
payCurrencyCode |
Payment currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
rates |
Exchange rate |
String(20) |
Be accurate 5 digits after dot |
No |
riskLevel |
Risk level |
String(2) |
00 None,01 Rejected by risk control,02 Suspicious
03 Business suspended |
Yes |
riskOccurCount |
Cumulative quantity of risk orders |
String(4) |
Cumulative quantity of risk orders |
Yes |
riskDesc |
Risk description |
String(256) |
Risk note |
Yes |
OrdersignMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
|
|
|
|
|
|
Participated signature element description:
signMsg=SHA256(version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256& recordCount=1&key={key}
OrdersignMsg signature element description:
merchantOrderNo=10000121&masapayOrderNo=880111123&orderAmount=1000&orderTime=20121117020101&dealTime=20121117020101&status=S&payMode=20&orgCode=WEBMONEY&paidAmount=1000¤cyCode=USD&payCurrencyCode=CNY&rates=6.21321&riskLevel=00& riskOccurCount=10&riskDesc=norisk&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
6 API Refund Business
6.1 Function Outline
Merchant Refund Interface: Merchant return all or part of bill of purchasing products or service back to user.
Merchant Refund Notification Interface: Notify merchant of successful refund after completed.
6.2 System Interaction
商戶系統(tǒng) |
Merchant system |
MasaPay系統(tǒng) |
MasaPay system |
seq退款請求 |
seq refund request |
1. 構(gòu)造請求數(shù)據(jù) |
1. Construct request data |
2. 調(diào)用《商戶退款接口》發(fā)送請求 |
2. Call Merchant Refund Interface to send request |
3. 請求處理 |
3. Request for solutions |
seq退款通知 |
seq refund notification |
4. 通知退款結(jié)果《退款通知接口》 |
Notify refund results, see Refund Notification Interface |
5. 接受后應(yīng)答,見《商戶應(yīng)答》 |
Response after receiving, see Merchant Response |
6. 對相應(yīng)的數(shù)據(jù)進(jìn)行處理 |
Process relevant data |
6.3 Merchant Refund Interface
6.3.1 Request
Produce submitting address:
https://open.masapay.com/masapi/refund/RefundMerchantOrder?wsdl
Test submitting address:
https://open-sandbox.masapay.com/masapi/refund/RefundMerchantOrder?wsdl
Input Parameter:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocate by MasaPay when merchant opens account. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
Business Parameter |
refundOrderNo |
Refund order no. |
String(30) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
merchantOrderNo |
Original merchant order no. |
String(64) |
Merchant paid order no. |
No |
masapayOrderNo |
MasaPay Business serial no. |
String(16) |
MasaPay Business serial no. |
Yes |
refundAmount |
Refund amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
refundSubmitTime |
Refund submission time |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
callbackUrl |
Callback notify URL |
String(256) |
Notify callback address that merchant refund order result |
No |
signMsg |
Signature |
String(256) |
See signature element description |
No |
|
|
|
|
|
|
Participated signature element description:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&refundOrderNo=0001&merchantOrderNo=10000121&masapayOrderNo=1231221&refundAmount=100¤cyCode=CNY&refundSubmitTime=20121117020101&callbackUrl=http://www.masapay.com&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
6.3.2 Return
Return to merchant the data as XML format.
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocated by MasaPay when registering |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
Business Parameter |
resultCode |
Refund result |
String(2) |
10 successful refund
11failed refund |
No |
errorMsg |
Error message |
String(256) |
Error message returned when failed |
Yes |
refundOrderNo |
Refund order no. |
String(32) |
the same as refund serial no. when submitting |
No |
Participated signature element description:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256& resultCode=10& refundOrderNo=123213932&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
6.4 Refund Notification Interface
6.4.1 Notification
Initiator: Internet Order Receiving Interface
Recipient: Merchant system
Notification address: bgUrl + POST request provided by merchant when making order
Parameter:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
Business Parameter |
refundOrderNo |
Refund order no. |
String(64) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
merchantOrderNo |
Original merchant order no. |
String(64) |
Merchant paid order no. |
No |
masapayOrderNo |
MasaPay Business serial no. |
String(16) |
MasaPay Business serial no. |
Yes |
masapayRefundOrderNo |
Masapay refund serial no. |
String(16) |
Masapay refund serial no. |
No |
submitTime |
Submission time |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
dealTime |
Deal time |
String(14) |
Time when MasaPay business completed
Year month day hour minute second
eg: 20121117020101 |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
refundAmount |
Refund amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
resultCode |
Result |
String(2) |
10 successful refund 11unsucessful refund |
No |
ext1 |
Extension |
String(256) |
Return original order merchant submitted ext1 |
Yes |
ext2 |
Extension |
String(256) |
Return original order merchant submitted ext2 |
Yes |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
Participated signature element description:
version=1.2&charset=utf-8&language=en&signType=SHA256&refundOrderNo=0001&merchantOrderNo=10000121&masapayOrderNo=12312312&masapayRefundOrderNo=1111111111111111&submitTime=20121117020101&dealTime=20121117020101¤cyCode=CNY&refundAmount=100&resultCode=10&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
6.4.2 Response
MasaPay notifies merchant through bgUrl in back stage. After handled by merchant system, it needs to be sent back to MasaPay system as character string format. The content is as following:
Return |
Description |
OK |
Successful. MasaPay system will not resend notice if receives this result. |
No return or other character |
Unsuccessful , MasaPay system will re-notify if receives this result. |
7 API Refund Inquiry Business
7.1 Function Outline
Merchant can search for individual transaction record or records on MasaPay in a certain time period.
7.2 System Interaction
商戶系統(tǒng) |
Merchant system |
MasaPay系統(tǒng) |
MasaPay system |
1. 構(gòu)造請求數(shù)據(jù) |
1. Construct request data |
2. 調(diào)用《退款查詢接口-請求》 |
2. Call Refund Inquiry Interface-Request |
3. 請求處理 |
3. Request for solutions |
4. 返回結(jié)果《退款查詢接口-返回》 |
4. Return results Refund Inquiry Interface-Return |
5. 對相應(yīng)的數(shù)據(jù)進(jìn)行處理 |
5. Process relevant data |
7.3 Refund Inquiry Interface
7.3.1 Request
Initiator: Merchant system
Recipient: MasaPay Internet Order Receiving Interface
Produce submitting address:
Test submitting address:
Input Parameter:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocate by MasaPay when merchant opens account. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
Business Parameter |
queryType |
Query Type |
String(1) |
0 query for individual according to MasaPay business serial no.
1 bulk query according to business ending time, successful orders only |
No |
refundOrderNo |
Refund order no. |
String(30) |
Fill out when query type is 0. The only refund serial no. generated by merchant |
No |
startTime |
Starting time of refund submission |
String(14) |
Fill out when query type is 2
Year month day hour minute second
eg: 20121117020101 |
Yes |
endTime |
Ending time of refund submission |
String(14) |
Fill out when query type is 2
Year month day hour minute second
eg: 20121117020101
Limited time period is 14 days, and spacing is 24 hours |
Yes |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
Signature element description:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&queryType=0&refundOrderNo=0001&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
7.3.2 Return
Return data as XML format to merchant.
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocated by MasaPay when register |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
errCode |
Error code |
String(10) |
Error code returned when unsuccessful payment is made. |
Yes |
errMsg |
Error message |
String(256) |
Error message returned when unsuccessful payment is made. |
Yes |
recordCount |
Record count |
String(10) |
Record count |
No |
signMsg |
Signature character string |
String(256) |
See Signature Element Description |
No |
Order Information (list) |
refundOrderNo |
Refund order no. |
String(64) |
Unique order number in merchant websites to ensure the uniqueness in merchant system. |
No |
merchantOrderNo |
Original merchant order no. |
String(64) |
Merchant paid order no. |
No |
masapayRefundOrderNo |
MasaPay refund serial no. |
String(16) |
MasaPay refund serial no. |
Yes |
refundAmount |
Refund amount |
String(18) |
Integer
Except JYD and KRW as yuan, other currencies as cent. |
No |
currencyCode |
Currency |
String(3) |
CNY RenMinBi, USD US Dollar, EUR Euro, RUB Ruble, JPY Yen, MOP Macao Pataca, MYR Malaysian Ringgit, NZD New Zealand Dollar, CHF Swiss Franc, THB Thai Baht, TWD New Taiwan Dollar, KRW Korea Won, INR Indian Rupee, CAD Canadian Dollar, AUD Australia Dollar, HKD Hong Kong Dollar, GBP Great Britain Pound, EUR Euro |
No |
submitTime |
Submission time |
String(14) |
eg: 20121117020101 |
No |
dealTime |
Deal time |
String(14) |
eg: 20121117020101 |
No |
status |
Status |
String(1) |
P Refund processing
S Refund succeeded
F Refund failed |
No |
OrdersignMsg |
Individual order signature character string |
String(256) |
Encrypted element for individual order record |
No |
|
|
|
|
|
|
|
signMsg signature element description:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&recordCount=1&key={key}
OrdersignMsg signature element description:
refundOrderNo=0001&merchantOrderNo=10000121&masapayRefundOrderNo1111111111111111&refundAmount=100¤cyCode=CNY&submitTime=20121117020101&dealTime=20121117020101&status=P&key={key}
Examples of Signature Methods:
Please see details in Appendix 8.1 Example of Signature Methods
8 API Express Order Uploading Business
8.1 Function Outline
Express Order Uploading Interface implements: Merchant upload express order data.
8.2 Express Order Uploading Interface
8.2.1 Request
Produce submitting address:
https://open.masapay.com/masapi/order/UploadExpressList?wsdl
Test submitting address:
https://open-sandbox.masapay.com/ masapi/order/UploadExpressList?wsdl
Input Parameter:
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocate by MasaPay when merchant opens account. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
expressCount |
Express order amount |
String(10) |
Upload express order total amount |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
signMsg |
Signature character string |
String(256) |
See signature element description |
No |
Express Order Information (list) |
merchantOrderNo |
Merchant order no. |
String(64) |
Original merchant payment order no. |
No |
expressDate |
Express date |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
etaDate |
Estimated delivery date |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
expressNo |
Express No. |
String(32) |
Order no. when express company make an order |
No |
expressCompany |
Express company |
String(60) |
Express company |
No |
expressUrl |
Express order inquiry Url |
String(200) |
Website where express company search for orders |
No |
uploadDate |
Uploading date |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
expressSignMsg |
Individual express order signature character string |
String(256) |
Each express order signature character string |
No |
|
|
|
|
|
|
|
|
Note:
Merchant can upload multiple orders once.
Signature element description:
signMsg=SHA256(version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&expressCount=1&key={key})
ExpressSignMsg Signature element description:
merchantOrderNo=10000121&expressDate=20121117020101&etaDate=20121117020101&expressNo=10099900101&expressCompany=SFexpress&expressUrl=www.masapay.com&key={key}
8.2.2 Return
Return data as XML format to merchant.
Parameter |
Parameter Name |
Data Type |
Parameter Description |
Whether can be null |
Basic Parameter |
version |
Version no. |
String(4) |
Gateway version number. This version is 1.2. |
No |
merchantId |
Merchant ID |
String(32) |
Allocated by MasaPay when registered. |
No |
charset |
Coded character set |
String(10) |
Such as gbk,gb2312,utf-8,Shift-JIS |
No |
language |
Language |
String(2) |
cn Chinese, en English, ru Russian, jp Japanese |
No |
signType |
Signature type |
String(8) |
Select SHA256 or MD5 |
No |
errCode |
Error code |
String(10) |
Error code returned when unsuccessful payment is made. |
Yes |
errMsg |
Error message |
String(256) |
Error message returned when unsuccessful payment is made. |
Yes |
expressCount |
Express order amount |
String(10) |
Total amount received successful orders |
No |
signMsg |
Signature character string |
String(256) |
See signature element description |
No |
Unsuccessful Express Order Information list |
merchantOrderNo |
Merchant order no. |
String(64) |
Original merchant payment order no. |
No |
expressDate |
Express date |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
etaDate |
Estimated delivery date |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
expressNo |
Express No. |
String(32) |
Order no. when express company make an order |
No |
expressCompany |
Express company |
String(60) |
Express company |
No |
expressUrl |
Express order inquiry Url |
String(200) |
Website where express company search for orders |
No |
uploadDate |
Uploading date |
String(14) |
year month day hour minute second
eg: 20121117020101 |
No |
expressSignMsg |
Individual express order signature character string |
String(256) |
Each express order signature character string |
No |
|
|
|
|
|
|
|
|
|
|
|
|
Signature element description:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256& expressCount =2&key={key}
expressSignMsg Signature element description:
merchantOrderNo=10000121&expressDate=20121117020101&etaDate=20121117020101&expressNo=10099900101&expressCompany=FS express & expressUrl = &key = {key}
9 Appendix
9.1 Examples of Signature Methods
9.1.1 Merchant Order Submission Interface
Signature Calculation Method:
SHA256
Participated Signature Elements:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&merchantOrderNo=10000121&goodsName=women’s clothing&goodsDesc= product name 1^product specification 1^purchase quantity 1^product price 1^product display website 1|product name 2^product specification 2^purchase quantity 2^product price 2^product display website 2¤cyCode=USD&orderAmount=1000&payMode=20&orgCode=WEBMONEY&directFlag=D&submitTime=20121117020101&expiryTime=20121117030101&pageUrl=https://www.masapay.com&bgUrl=https://www.masapay.com&key=1234567890
Use SHA256 to the above signature elements and obtain signature result (capitalize when transferring binary system to hexadecimal)vas following:
AD59678D5389974AB6886A3AAB6133FE0BCF1C0BA56E270B71C941F135F00BC0
Examples of Submitting Parameter:
version=1.2&merchantId=88800033122&charset=utf-8&language=en&signType=SHA256&merchantOrderNo=10000121&goodsName= women’s clothing&goodsDesc= product name 1^product specification 1^purchase quantity 1^product price 1^product display website 1|product name 2^product specification 2^purchase quantity 2^product price 2^product display website 2¤cyCode=USD&orderAmount=1000&payMode=20&orgCode=WEBMONEY&directFlag=D&submitTime=20121117020101&expiryTime=20121117030101&pageUrl=http://www.masapay.com&bgUrl=http://www.masapay.com&ext1=&ext2=&remark=&payerName=&payerMobile=&payerEmail=®isterTime=®isterIp=®isterTerminal=&receiveName&receiveAddress=&receivePostCode=&receiveTel=&orderIp=&orderTerminal=&ext3=&ext4=&signMsg=AD59678D5389974AB6886A3AAB6133FE0BCF1C0BA56E270B71C941F135F00BC0
9.1.2 Merchant Notification Interface:
Signature Calculation Method:
SHA256
Participated Signature Elements:
version=1.2&charset=utf-8&language=en&signType=SHA256&merchantOrderNo=10000121&masapayOrderNo=880111123&submitTime=20121117020101&dealTime=20121117030101¤cyCode=USD&orderAmount=1000&paidAmount=1000&payMode=20&orgCode=WEBMONEY&resultCode=10&riskLevel=00&riskDesc=norisk&key=1234567890
Use SHA256 to the above signature elements and obtain signature result (capitalize when transferring binary system to hexadecimal) as following:
AE403619EA1D5F460F1F4819802AF9F647C3A4169BACF3F35ECF081568EC2B94
Examples of Submitting Parameter:
version=1.2&charset=utf-8&language=en&signType=SHA256&merchantOrderNo=10000121&masapayOrderNo=880111123&submitTime=20121117020101&dealTime=20121117030101¤cyCode=US
1.1 Response Code
Response Code defines reporting response when business is failed.
1.1.1 Property
AN-4
Field: None.
Data Field: fixed to 4 digits.
1.2.1 Description
Response Code is used for sending authorization status of financial or request authorization transactions. It can also be used in document updating, reconciliation account checking, system management, and receiving status of management transactions. The following is all responding codes and its reasons.
Response codes |
|
|
MasaPay Code |
MasaPay Definition |
Code Classification |
3084 |
Insufficient fund |
Transaction |
3085 |
Wrong password |
Transaction |
3086 |
Violate Encryption Regulations |
Risk |
3088 |
Exceed card numbers limit |
Risk |
3089 |
Suspicious for cheating |
Risk |
3091 |
Wrong bank parameter |
System |
3092 |
Invalid transactions |
Transaction |
3093 |
Invalid amount |
Transaction |
3094 |
Invalid card number |
Transaction |
3095 |
Transaction time-out |
Transaction |
3096 |
Wrong expiry date |
Transaction |
3097 |
Unsupported card types |
Transaction |
3098 |
Abnormal system |
System |
3099 |
Other abnormal conditions |
Others |
D&orderAmount=1000&paidAmount=1000&payMode=20&orgCode=WEBMONEY&resultCode=10&riskLevel=00&riskDesc=norisk&ext1=&ext2=&signMsg=AE403619EA1D5F460F1F4819802AF9F647C3A4169BACF3F35ECF081568EC2B94
9.2 Contact
9.3 Agreement
1 MasaPay will not add signs for returned report when returned report has errorCode. At the same time, relevant MasaPay transaction information will be returned as null. 世聯(lián)翻譯-讓世界自由溝通!專業(yè)的全球語言翻譯供應(yīng)商,上海翻譯公司專業(yè)品牌。絲路沿線56種語言一站式翻譯與技術(shù)解決方案,專業(yè)英語翻譯、日語翻譯等文檔翻譯、同傳口譯、視頻翻譯、出國外派服務(wù),加速您的全球交付。
世聯(lián)翻譯公司在北京、上海、深圳等國際交往城市設(shè)有翻譯基地,業(yè)務(wù)覆蓋全國城市。每天有近百萬字節(jié)的信息和貿(mào)易通過世聯(lián)走向全球!積累了大量政商用戶數(shù)據(jù),翻譯人才庫數(shù)據(jù),多語種語料庫大數(shù)據(jù)。世聯(lián)品牌和服務(wù)品質(zhì)已得到政務(wù)防務(wù)和國際組織、跨國公司和大中型企業(yè)等近萬用戶的認(rèn)可。 |