About Payment ​
Access scope
Multiple access scopes needed — refer to each endpoint for access scope requirements.
The Genstore payment business domain is the core business module that manages payment information by providing a series of RESTful interfaces, supporting sub domains such as order placement, refund actions, and payment order queries in the payment process. Core functions -* * Order * : Create a payment order based on the order and notify PSP for deduction. -Refund: According to the after-sales agreement, the refund will be given to the customer. - * Obtain a single payment order * *: Retrieve detailed information of the payment order based on the payment order ID associated with the order. Application scenarios -Payment Extersion: Developers can use payment development capabilities to connect third-party payment service providers to their stores as a third-party payment channel to expand their store's payment capabilities.
Endpoints
PUT /api/202412/app/account_authorize: Update account authorization result
PUT /api/202412/app/payment/{paymentId}: Update payment result
PUT /api/202412/app/capture/{captureId}: update capture result
PUT /api/202412/app/refund/{refundId}: Update refund result
PUT /api/202412/app/void/{voidId}: Update cancel capture result
PUT /api/202412/app/pre_authorize/{paymentId}: Update pre-authorized order authorization result
Payment Object ​
The payment object
Properties ​
{
"purchaseInfo": {
"insurance": "",
"itemTotal": "",
"shipping": "",
"taxTotal": "",
"description": "",
"discount": "",
"handling": "",
"shippingDiscount": "",
"items": [
{
"unitPrice": "",
"imgUrl": "",
"quantity": "",
"name": "",
"description": "",
"tax": "",
"category": "",
"sku": "",
"virtualProduct": ""
}
]
},
"amount": "",
"clientDetails": {
"acceptLanguage": "",
"ipAddress": "",
"userAgent": ""
},
"test": "",
"manualCapture": "",
"paymentId": "",
"paymentMethod": {
"data": {
"cipherText": "",
"salt": "",
"ephemeralPublicKey": "",
"suit": "",
"returnUrl": "",
"iv": ""
}
},
"currency": "",
"customer": {
"phoneNumber": "",
"shippingAddress": {
"phoneNumber": "",
"province": "",
"city": "",
"countryCode": "",
"givenName": "",
"familyName": "",
"postalCode": "",
"company": "",
"line2": "",
"line1": ""
},
"billingAddress": {
"phoneNumber": "",
"province": "",
"city": "",
"countryCode": "",
"givenName": "",
"familyName": "",
"postalCode": "",
"company": "",
"line2": "",
"line1": ""
},
"email": ""
}
}
PUT Update account authorization result ​
Update the account authorization result.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/account_authorize
Request Params
Response Data
curl -X PUT \
https://{shop}.genmystore.com/api/202412/app/account_authorize" \
-H "X-Genstore-Access-Token: {access_token}" \
-H "Content-Type: application/json" \
-d '{
"pay":{
"ready":"true"
}
}'
HTTP/1.1 200 OK
{}
PUT Update payment result ​
Return payment result.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/payment/{paymentId}
Request Params
Response Data
curl -X PUT \
https://{shop}.genmystore.com/api/202412/app/payment/{paymentId}" \
-H "X-Genstore-Access-Token: {access_token}" \
-H "Content-Type: application/json" \
-d '{
"pay":{
"result":"true",
"reason":"Insufficient balance of bank card",
"paymentId":"PI00202510281513381",
"channelPaymentId":"2025102815"
}
}'
HTTP/1.1 200 OK
{}
PUT update capture result ​
Returns manual capture results, success or failure.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/capture/{captureId}
Request Params
Response Data
curl -X PUT \
https://{shop}.genmystore.com/api/202412/app/capture/{captureId}" \
-H "X-Genstore-Access-Token: {access_token}" \
-H "Content-Type: application/json" \
-d '{
"pay":{
"result":"true",
"reason":"Payment do not support multiple captures",
"channelCaptureId":"510281513",
"captureId":"PI00202510281513381"
}
}'
HTTP/1.1 200 OK
{}
PUT Update refund result ​
Returns the refund processing result, success or failure.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/refund/{refundId}
Request Params
Response Data
curl -X PUT \
https://{shop}.genmystore.com/api/202412/app/refund/{refundId}" \
-H "X-Genstore-Access-Token: {access_token}" \
-H "Content-Type: application/json" \
-d '{
"pay":{
"result":"true",
"reason":"The Reason for refund failure",
"channelRefundId":"100202712119",
"refundId":"RI00202510281513381"
}
}'
HTTP/1.1 200 OK
{}
PUT Update cancel capture result ​
Returns the processing result for a merchant-initiated uncapture.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/void/{voidId}
Request Params
Response Data
curl -X PUT \
https://{shop}.genmystore.com/api/202412/app/void/{voidId}" \
-H "X-Genstore-Access-Token: {access_token}" \
-H "Content-Type: application/json" \
-d '{
"pay":{
"result":"true",
"reason":"Payment status is abnormal",
"voidId":"PI00204453245701197",
"channelVoidId":"I002044532457"
}
}'
HTTP/1.1 200 OK
{}
PUT Update pre-authorized order authorization result ​
Update the authorization result for a pre-authorized order.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/pre_authorize/{paymentId}
Request Params
Response Data
curl -X PUT \
https://{shop}.genmystore.com/api/202412/app/pre_authorize/{paymentId}" \
-H "X-Genstore-Access-Token: {access_token}" \
-H "Content-Type: application/json" \
-d '{
"pay":{
"result":"true",
"reason":"Abnormal bank card number",
"paymentId":"PI00202510281513381",
"channelPaymentId":"20251028151338"
}
}'
HTTP/1.1 200 OK
{}
About Payment
Access scope
Multiple access scopes needed — refer to each endpoint for access scope requirements.
The Genstore payment business domain is the core business module that manages payment information by providing a series of RESTful interfaces, supporting sub domains such as order placement, refund actions, and payment order queries in the payment process. Core functions -* * Order * : Create a payment order based on the order and notify PSP for deduction. -Refund: According to the after-sales agreement, the refund will be given to the customer. - * Obtain a single payment order * *: Retrieve detailed information of the payment order based on the payment order ID associated with the order. Application scenarios -Payment Extersion: Developers can use payment development capabilities to connect third-party payment service providers to their stores as a third-party payment channel to expand their store's payment capabilities.
Payment Object
The payment object
Properties
PUT Update account authorization result
Update the account authorization result.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/account_authorize
PUT Update payment result
Return payment result.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/payment/{paymentId}
PUT update capture result
Returns manual capture results, success or failure.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/capture/{captureId}
PUT Update refund result
Returns the refund processing result, success or failure.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/refund/{refundId}
PUT Update cancel capture result
Returns the processing result for a merchant-initiated uncapture.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/void/{voidId}
PUT Update pre-authorized order authorization result
Update the authorization result for a pre-authorized order.
Access scope
Requires ANY of the following access scopes: write_payment
Endpoint
PUT /api/202412/app/pre_authorize/{paymentId}