Payment Submit Interface

Description

This interface would be used when merchants have decided the mode of payment, the communication adopts HTTPS protocol, merchants could send request parameter to Geoswift assigned URL to receive asynchronous notification result after finishing payment.

Request Endpoint

https://apis.geoswift.com/cp/order

Name Type& Max Description Requirement
merchantId varchar(9) The unique identity of the merchant ID in Geoswift system. M
partnerId varchar(9) The unique ID of the service provider in the Geoswift system C
orderAmount decimal(18) When the orderCurrency is JPY, KRW or VND, the unit of orderAmount is Yuan, the unit of other currencies is China Fen, 1 Yuan = 100 Fen M
orderCurrency varchar(8) CNY M
USD
JPY
EUR
GBP
CAD
AUD
HKD
RUB
KRW
VND
NZD
requestId varchar(50) The order number is generated by the merchant, the order number must be the unique on the transaction platform. Request/order which had been paid or canceled in Geoswift’s platform can’t be submitted with the same request ID. M
settlementCurrency varchar(8) CNY M
USD
JPY
EUR
GBP
CAD
AUD
HKD
NZD
SGD
forUse varchar(50) GOODSTRADE M
PLANETICKET
HOTELACCOMMODATION
STUDYABROAD
OTHER
gatewayType varchar(6) ALL O
DEBIT
CREDIT
When the paymentModeCode is ONLINE_PAY-UNION_PAY-P2P ,the gatewayType parameter is optional and the default value is ALL.
subject varchar(64) Product subject M
notifyUrl varchar(200) Server notification: After successful payment, there would be a notification sent to the address which could be parameterized(Please refer to "Interface Rules" for the sending mechanism). Example: “https://www.geoswift.com/callback.a ction?test=test ” Note: Your server would not receive the notification of paid successfully after completing payment if the parameter value of notifyUrl wasn’t filled in. M
callbackUrl varchar(200) Page callback: After successful payment, it will jump to this address.for example: “https://www.geoswift.com/callback. action?test=test” Note: Your browser page would not receive the notification of paid successfully after completing payment if the parameter value of callbackUrl wasn’t filled in. M
remark varchar(300) It is for merchants to remark orders in Geoswift ,which would be returned to merchant through the payment result. O
paymentModeCode varchar(50) ONLINE_PAY-ALI_PAY-P2P (Remark: Alipay Web Payment-Direct) M
ONLINE_PAY-UNION_PAY-P2P (Remark: UnionPay Online -> Direct)
SCANCODE-WEIXIN_PAY-P2P (Remark: Wechat QR Code Scan ->Direct)
SCANCODE-WEIXIN_PAY (Remark: Wechat QR Code Scan ->Non-direct)
APP-ALI_PAY-P2P (Remark: Alipay App Payment ->Direct)
APP-WEIXIN_PAY-P2P (Remark: Wechat App Payment ->Direct)
MINIAPPS-WEIXIN_PAY-P2P (Remark: Wechat Mini Program Payment ->Direct)
isDirect Fixed value true M
false
goodstrades Json(array) Reference to the table "Request Parameter Fields(goodstrades,product details)",no more than 50 product information C
clientIp varchar(100) If the client IP has been set, the order can’t be paid on any other IP.When the paymentModeCode is SCANCODE-WEIXIN_PAY-P2P or MINIAPPS-WEIXIN_PAY-P2P,the clientIp must be set. C
timeout Long(1440) Unit : minute. The default is 1440 minutes O
authCode varchar(32) Authorization code(Alipay) C
openId varchar(30) The openId of WeChat official account.When the paymentModeCode is APP-WEIXIN_PAY-P2P or MINIAPPS-WEIXIN_PAY-P2P,the openId is required C
appId varchar(30) WeChat APPID.When the paymentModeCode is APP-WEIXIN_PAY-P2P or MINIAPPS-WEIXIN_PAY-P2P,the appId is required C
ticketInfo Json Reference to the table "Request Parameter Fields ( ticketInfo , air ticket information)",this item only allows uploading one datum.When the forUse is PLANETICKET,the ticketInfo is required C
studyAbroadInfo Json Reference to the table “Request Parameter Fields ( studyAbroadInfo , overseas study information)”,this item only allows uploading one datum.When the forUse is STUDYABROAD,the studyAbroadInfo is required C
studentIdType varchar(32) IDCARD C
PASSPORT
OTHER
When the payment method code is ONLINE_PAY-ALI_PAY-P2P or APP-ALI_PAY-P2P, this field only supports IDCARD.
studentIdNo varchar(32) Student ID No C
studentPhoneNo varchar(16) Student phone No C
studentEmail varchar(128) Student e-mail C
payerIdType varchar(32) IDCARD C
PASSPORT
OTHER
payerIdNo varchar(32) Payer's ID No C
payerName varchar(64) Payer's English name C
payerNameZh varchar(32) Payer's Chinese name C
payerPhoneNo varchar(16) Payer's phone No C
payerFirstName varchar(64) Payer's first name(English) C
payerLastName varchar(64) Payer's last name(English) C
payerStudentRelation varchar(20) When the trade background is related to studying abroad and the payment method code is ONLINE_PAY-ALI_PAY-P2P or APP-ALI_PAY-P2P, this field is required C
SELF
PARENTS
GRANDPARENTS
SPOUSE
SIBLINGS
hotelInfo Json Reference to the table "Request Parameter Fields ( hotelInfo , hotel information)",this item only allows uploading one datum. When the forUse is HOTELACCOMMODATION, the hotelInfo is required C
otherInfo Json Reference to the table "Request Parameter Fields ( otherInfo , other information)",this item only allows uploading one datum. When the forUse is OTHER, the otherInfo is required C
hmac varchar(500) The result of parameter signature,generated by the merchant.For the method of obtaining hmac,please reference to "Geoswift encryption and decryption process specification" M

The preceding parameter values cannot contain the following special characters: '" &<>()

Request Parameter Fields(goodstrades,product details)

Name Type& Max Description Requirement
name varchar(200) Name of product C
count Int(6) Quantity of product,maximum value is 999999 C

2 Request Parameter Fields ( ticketInfo , air ticket information)

Name Type& Max Description Requirement
flight varchar(100) Flight numbers; Flight numbers are separated by "," if more than one C
departureArrivalTime varchar(14) yyyymmdd hh:min sample:20170601 10:12 C
arrivalTime varchar(14) yyyymmdd hh:min sample:20170601 10:12 O

Request Parameter Fields ( studyAbroadInfo , overseas study information)

Name Type& Max Description Requirement
url varchar(200) Admission information or admission letter url C
studentChineseName varchar(32) Student Chinese name O
studentName varchar(64) Chinese phonetic alphabet name,sample:zhang san C
schoolName varchar(128) School name(non-Chinese) C
studentNo varchar(64) Student No(non-Chinese) O
schoolCountry varchar(3) Reference to the country code in the appendix C
payAmount Long When the payCurrency is JPY, KRW or VND, the unit of payAmount is Yuan, the unit of other currencies is China Fen, 1 Yuan = 100 Fen C
payCurrency varchar(8) All currencies.Reference to the currency list table in the appendix C
schoolNo varchar(64) School number(non-Chinese) C, Descrption: When choosing Alipay as the payment method, then it is "M"; It is "O" when other methods are selected
studentFirstName varchar(64) Student first name(English ) C
studentLastName varchar(64) Student last name(English ) C

Request Parameter Fields ( hotelInfo , hotel information)

Name Type& Max Description Requirement
hotelName varchar(100) Hotel name C
checkInDate varchar(10) yyyy-MM-dd sample:2017-06-01 C
checkOutDate varchar(10) yyyy-MM-dd sample:2017-06-01 C

Request Parameter Fields ( otherInfo , other information)

Name Type& Max Description Requirement
description varchar(200) Description information C

Sample

{ "appId": "", "authCode": "", "callbackUrl": "https://qa-sdk-v2.geoswift.com/cp/callbackUrl", "clientIp": "43.254.91.131", "forUse": "STUDYABROAD", "gatewayType": "DEBIT", "goodstrades": [], "hmac": "QZfqFCZshGKsV9G99XOuX9b+NpW5TOEgD0d1hxJTAnDgB6V2JEyiGHDb diWf7yNZUdruKx7Q1P6bwv6dhu05o13wYfp0S7zC7GP0aolLdjYqjNbR2n4gXinH7Tr1B3 GyOEJ2B6SDa3xEebBl8cd7m/Msng3jYbB1NznHkIQec329Xuh19kr0SQB+xdMAbX7Dzt dDweNMEnH+5pJLgbDjSyMocF9jBkhShvX5g1VdBpfK05ZTqRNaGcLrLgwMh4QlPtJhvq TBtOiko23ZtIylinHiVaaXnbsR9WGg5fsmtRly3Cf6LW/XbJUuyh6O92eArAV1CXOEuKy04 +qIkSW0bQ==", "isDirect": "true", "merchantId": "G90008005", "notifyUrl": "https://qa-sdk-v2.geoswift.com/cp/notify", "openId": "", "orderAmount": 100, "orderCurrency": "CNY", "partnerId": "", "payerFirstName": "tester", "payerIdNo": "130733200211111120", "payerIdType": "IDCARD", "payerLastName": "guo", "payerName": "tester", "payerNameZh": "guo", "payerPhoneNo": "1**********7", "paymentModeCode": "ONLINE_PAY-UNION_PAY-P2P", "remark": "1234", "requestId": "1630985841101", "settlementCurrency": "CNY", "studentEmail": "2**********7@qq.com", "studentIdNo": "130733200211141210", "studentIdType": "IDCARD", "studentPhoneNo": "1**********7", "studyAbroadInfo": { "payAmount": 1, "payCurrency": "CNY", "schoolCountry": "USA", "schoolName": "English", "schoolNo": "0310", "studentChineseName": "123", "studentFirstName": "123", "studentLastName": "123", "studentName": "slass", "studentNo": "1234567", "url": "urlaaa111" }, "subject": "苹果手机", "timeout": "10" }

Synchronously Returned Parameter Fields

Name Description
merchantId The unique identity of the merchant ID in Geoswift system.
partnerId The unique ID of the service provider in the Geoswift system
requestId The order number is generated by the merchant, the order number must be the unique on the transaction platform. Request/order which had been paid or canceled in Geoswift’s platform can’t be submitted with the same request ID.
bankRequestNumber Request bank serial number
status Request status
SUCCESS
FAILED
ERROR
REDIRECT
appParams When the payment method is wechat/Alipay app payment, this parameter will be returned, which can be used to call the official wechat/Alipay SDK to complete the payment. Note: When choose Alipay APP payment, it is supported to call Alipay H5 page; For details, please refer to the SDK from the official Alipay websites:https://global.alipay.com/docs/ac/app/download tuning up method
redirectUrl User’s Internet explorer should visit the redirect url if the request id status are redirect.It will be return when the paymentModeCode is ONLINE_PAY-UNION_PAY-P2P or ONLINE_PAY-ALI_PAY-P2P or SCANCODE-WEIXIN_PAY.
jsString This JSON data is returned from wechat, which the merchant will use to invoke wechat payment.
scanCodeUrl The QR code link would only be returned when the paymentModeCode is SCANCODE-WEIXIN_PAY-P2P
serialNumber Serial number of the request in Geoswift's platform
errorMessage Error message
orderStatus INIT
CANCEL
PROCESSING
SUCCESS
FAILED
hmac The result of parameter signature,generated by Geoswift.For the signature verification process,please reference to "Geoswift encryption and decryption process specification"

Sample

{ "redirectUrl": "https://qa-gs-cashier.geoswift.com/receipt/redirect/index /2c9980957a2c66a2017a2d17967b005b/2c9980957a2c66a2017a2d1796d1005e", "serialNumber": "2c9980727a2c6c68017a2d1795490029", "merchantId": "G90008005", "requestId": "16242538053223", "orderStatus": "PROCESSING", "status": "REDIRECT", "hmac": "uFzGnMExQgcCbxDjDbgjitCVK6+iD3qvxhQfk3DuDyfaJcXyiobyh8XBC4/jLpgF SidLjxYXdnX9bP4iom3wStOOh05ohGWvYbdLHh31bKMmjITouKH05SfUOIno15vrENfUu8wbr f0lIOx3tslTg2LAeAd+s9ekEVBq5ZvW06gKfOtmRzAtVTtT+weUxDo/R/vs7jK16rN3Gi4Jd6 YVmbPJFJCtkeGZJY1CkdfFFlYFoyIPY3/XvGUnw8KgAkQ8KlZIgzjWqBfiLyO7gcSWC1nybBK tGTqdux2a/vinahPNcRdmN+BBauk65qaAEZnNaTLFsUtmc/b724P0PKKKKQ==" }

Asynchronously Returned Parameter Fields

Name Description
merchantId The unique identity of the merchant ID in Geoswift system.
partnerId The unique ID of the service provider in the Geoswift system
requestId The order number is generated by the merchant, the order number must be the unique on the transaction platform. Request order which had been paid or canceled in Geoswift's platform can’t be submitted with the same request ID.
bankRequestNumber Request bank serial number
serialNumber Serial number of the request in Geoswift's platform
totalRefundCount Total count of refund
totalRefundAmount Total amount of refund.When the refund currency is JPY, KRW or VND, the unit of totalRefundAmount is Yuan, the unit of other currencies is China Fen, 1 Yuan = 100 Fen
orderAmount Amount of order.When the orderCurrency is JPY, KRW or VND, the unit of orderAmount is Yuan, the unit of other currencies is China Fen, 1 Yuan = 100 Fen
orderCurrency Reference to the currency list table in the appendix
settlementAmount Amount of settlement, when the settlementCurrency is JPY, KRW or VND, the unit of settlementAmount is Yuan, the unit of other currencies is China Fen, 1 Yuan = 100 Fen
settlementCurrency Reference to the currency list table in the appendix
status CANCEL
SUCCESS
FAILED
exchangeRate Exchange rate, to six decimal places
feeAmount Amount of fee, when the feeCurrency is JPY, KRW or VND, the unit of feeAmount is Yuan, the unit of other currencies is China Fen, 1 Yuan = 100 Fen
feeCurrency Reference to the currency list table in the appendix
gatewayType ALL
DEBIT
CREDIT
The gatewayType will be returned when the paymentModeCode is ONLINE_PAY-UNION_PAY-P2P.
completeDate Time Payment completion time
paymentModeCode ONLINE_PAY-ALI_PAY-P2P
ONLINE_PAY-UNION_PAY-P2P
SCANCODE-WEIXIN_PAY-P2P
APP-ALI_PAY-P2P
APP-WEIXIN_PAY-P2P
SCANCODE-WEIXIN_PAY "Non-direct"
MINIAPPS-WEIXIN_PAY-P2P
remark remark
needReview true
false
errorMessage Error message
hmac The result of parameter signature,generated by Geoswift.For the signature verification process,please reference to "Geoswift encryption and decryption process specification"

Sample

{ "completeDateTime": "2021-06-21 13:54:04", "needReview": "true", "feeCurrency": "CNY", "remark": "", "paymentModeCode": "ONLINE_PAY-UNION_PAY-P2P", "gatewayType": "ALL", "orderAmount": "110", "exchangeRate": "100.000000", "merchantId": "G90008005", "requestId": "16242538053223", "totalRefundCount": "0", "serialNumber": "2c9980727a2c6c68017a2d1795490029", "orderCurrency": "CNY", "errorMessage": "null-null", "feeAmount": "11", "settlementCurrency": "CNY", "settlementAmount": "110", "totalRefundAmount": "0", "status": "SUCCESS", "hmac": "0mbgZQaTrBFhrEm6uRUW8VnxvZl8Mja4ecCEqNiP3Si8iJrZOL zQs5U0T5PJc/LmZpp6k10Ft85R8akvZBno9kz1EDugCFXvzDHyW+ai8+xuy qZhMNDlLS4GnWoiST4L3yIfIHy3WECBhgzfFi6N74dWBAHbeoc/vK89t7Fz xtd3ZzagsKOLov8iQ7mTlR27MSkSylv0HLIA1iVjBOUYJVAL53uGWxJNJne BUKpl9jQD8If8rpBJKN4Pa5UADbvXcq6oF7YIgYX/X125Pu4zq14+UtDozp ppgNcri6kB3vkQnlU6iGlAgO08bmjMfDlT/Qd+/ZltcaGi2CnhXNDmfw==" }