AlipayHK
Beta
Last updated: September 14, 2022
Start accepting payments using one of the top e-wallets in Hong Kong. Alipay Hong Kong (HK) provides a mobile payment service that allows its customers to make one-time purchases or sign up for a recurring payment.
AlipayHK is a part of Ant Financial’s e-wallet network, which enables it to be used in countries outside of the local market, as long as the regions are covered by Ant’s partners.
When accepting payments with AlipayHK, you need to display the Alipay+ and AlipayHK logos on your payment interface. To ensure that the logos match Alipay's requirements, refer to their Brand display guidelines for online payments and Brand display guidelines for cashier payments.
Information
To learn more, reach out to your Customer Success Manager or support@checkout.com.
Model | Collecting |
---|---|
Payment flow | Redirect |
Payment method type | Wallet |
One-step payment | |
Authorization | |
Capture | |
Refund | |
Partial refund | |
Chargeback | |
Recurring payment |
Supported countries |
|
---|---|
Supported processing and settlement currencies |
|
AlipayHK has a 2-step process:
For the full API specification, see the API reference.
post
https://api.checkout.com/payments
If a customer ID or email is not provided in the request, we automatically create a customer profile and return the customer ID in the response.
1{2"amount": 10,3"currency": "EUR",4"source": {5"type": "alipay_hk"6},7"processing": {8"terminal_type": "APP",9"os_type": "IOS"10},11"success_url": "https://example.com/payments/success",12"failure_url": "https://example.com/payments/failure",13"payment_type": "Regular",14"reference": "ORD-5023-4E89",15"capture": true,16"customer": {17"email": "john.smith@example.com"18},19"shipping": {20"address": {21"country": "GB"22}23},24"items": [25{26"reference": "1st item reference",27"name": "1st item name",28"unit_price": 10,29"quantity": 130}31],32"processing_channel_id": "pc_ekaubqrravqupfxde7kxvd2t3i"33}
If you receive a 202 Success
response with a payment id
and a status
field set to Pending
, your request was successful.
1{2"id": "pay_bsrduhejxiuerlh32hb5n6dvae",3"status": "Pending",4"reference": "ORD-5023-4E89",5"customer": {6"id": "cus_2g4ehcpm6phexgkzahlwxvbgne",7"email": "john.smith@example.com",8"name": "John Smith"9},10"_links": {11"self": {12"href": "https://api.checkout.com/payments/pay_bsrduhejxiuerlh32hb5n6dvae"13},14"redirect": {15"href": "https://psp.ac.alipay.com/page/simulation-wallet/acwallet/alipayconnectcode.html?code=281666040099gDeR9hatc6IPfQ0bstyv3kOD&pspName=ALIPAY_HK&loadMode=2"16}17}18}
Redirect your customer to the redirect
link’s href
in the response. This will allow the customer to authorize the payment, before they are transferred to your predefined success or failure URL.
You can set up recurring payments for a subscription-based service. This allows you to make pre-authorized fund deductions from a customer’s account.
To request a recurring payment, your payment request should have payment_type
set to recurring
.
To get a detailed view of all required and optional fields, see our API reference.
post
https://api.checkout.com/payments
1{2"amount": 1100,3"currency": "EUR",4"source": {5"type": "alipay_hk"6},7"processing": {8"terminal_type": "WEB"9},10"success_url": "https://example.com/payments/success",11"failure_url": "https://example.com/payments/failure",12"payment_type": "Recurring",13"reference": "ORD-5023-4E89",14"capture": "true",15"customer": {16"email": "john.smith@example.com",17"name": "John Smith"18},19"shipping": {20"address": {21"country": "GB"22}23},24"items": [25{26"reference": "1st item reference",27"name": "1st item name",28"unit_price": 1029}30],31"processing_channel_id": "pc_ekaubqrravqupfxde7kxvd2t3i"32}
If you receive a 202 Success
response with a payment id
and a status
field set to Pending
, your request was successful.
1{2"id": "pay_4z3h7526xn6evko3vnybrmnu4e",3"status": "Pending",4"reference": "ORD-5023-4E89",5"customer": {6"id": "cus_2g4ehcpm6phexgkzahlwxvbgne",7"email": "john.smith@example.com",8"name": "John Smith"9},10"source": {11"id": "src_gnyde6bvifsukobwjb2vkwkbni",12"type": "alipay_hk"13},14"_links": {15"self": {16"href": "https://gwc.ckotech.co/gateway/payments/pay_4z3h7526xn6evko3vnybrmnu4e"17},18"redirect": {19"href": "https://g.alipayplus.com/page/aplus-linker/acwallet/qrcode.html?url=alipayconne"20}21}22}
1{2"amount": 44,3"currency": "EUR",4"source": {5"type": "id",6"id": "src_inmwstthmjyfcskeir3gcqtyj4"7},8"payment_type": "Recurring",9"reference": "ORD-5023-4E89-1234",10"customer": {11"name": "John Smith",12"email": "john.smith@example.com"13},14"shipping": {15"address": {16"country": "GB"17}18},19"items": [20{21"reference": "1st item reference",22"name": "1st item name",23"unit_price": 43,24"quantity": 125}26],27"processing_channel_id": "pc_ekaubqrravqupfxde7kxvd2t3i"28}
If you receive a 202 Success
response with a payment id
and a status
field set to Pending
, your request was successful.
1{2"id": "pay_xljv6f7ye4lebinkv7i7pho634",3"status": "Pending",4"reference": "ORD-5023-4E89-1234",5"customer": {6"id": "cus_mzrvode5g2jubm4bgbaad2usbu",7"email": "john.smith@example.com",8"name": "John Smith"9},10"source": {11"id": "src_inmwstthmjyfcskeir3gcqtyj4",12"type": "alipay_hk"13},14"_links": {15"self": {16"href": "https://gwc.ckotech.co/gateway/payments/pay_xljv6f7ye4lebinkv7i7pho634"17}18}19}
You can retrieve details about an existing AlipayHK payment by using the payment id
found in the payment response.
Use the details below to set up your request.
For the full API specification, see the API reference.
get
https://api.checkout.com/payments/{id}
1{2"id": "pay_bsrduhejxiuerlh32hb5n6dvae",3"requested_on": "2022-09-02T07:15:58.894077Z",4"source": {5"type": "alipay_hk"6},7"items": [8{9"name": "1st item name",10"unit_price": 10,11"reference": "1st item reference"12}13],14"amount": 1100,15"currency": "EUR",16"payment_type": "Regular",17"reference": "ORD-5023-4E89",18"status": "Captured",19"approved": true,20"balances": {21"total_authorized": 1100,22"total_voided": 0,23"available_to_void": 0,24"total_captured": 1100,25"available_to_capture": 0,26"total_refunded": 0,27"available_to_refund": 110028},29"customer": {30"id": "cus_mzrvode5g2jubm4bgbaad2usbu",31"email": "john.smith@example.com",32"name": "John Smith"33},34"shipping": {35"address": {36"country": "GB"37}38},39"processing": {40"partner_customer_id": "210220900020124540718"41},42"_links": {43"self": {44"href": "https://gwc.ckotech.co/gateway/payments/pay_7domcpi745nu5bdhm5rtrblbem"45},46"actions": {47"href": "https://gwc.ckotech.co/gateway/payments/pay_7domcpi745nu5bdhm5rtrblbem/actions"48},49"refund": {50"href": "https://gwc.ckotech.co/gateway/payments/pay_7domcpi745nu5bdhm5rtrblbem/refunds"51}52}53}
AlipayHK supports both partial and full refunds. You can refund a payment through the Dashboard or using the refund API.
To get a detailed view of all required and optional fields, see our API reference.
post
https://api.checkout.com/payments/{id}/refunds
1{2"amount": 203}
1{2"action_id": "act_c4x2vjvnx4uelb4io72fa4e57a",3"_links": {4"payment": {5"href": "http://gwc.ckotech.co/gateway/payments/pay_fzzdurog3squjj2ityho7x3o64"6}7}8}
You may receive the following webhooks when using AlipayHK.
Webhook | Description |
---|---|
| Sent when a merchant initiates the payment request. |
| Sent when a payment request has been successfully initiated and payment is pending for capture. |
| Sent when the payment has been successfully captured. |
| Sent when a payment request has been rejected. |
| Sent when the refund of the payment has been (fully or partially) accepted. |
| Sent when the payment has been (fully or partially) refunded. |
| Sent when a refund has been declined. |
View all of our webhook notifications.
Before you begin testing, you'll need to contact your Customer Success Manager or Implementation Engineer to:
- Activate AlipayHK payments in the sandbox environment.
- Get credentials to access the Alipay+ Linker app.
To start testing once you've completed merchant onboarding to AlipayHK:
- Sign in to the sandbox environment using the username and password provided by your Customer Success Manager.
- Create an AlipayHK sandbox transaction by following the request a payment instructions.
- Use the testing credentials to know what to do next depending on the device you are using.
When requesting an AlipayHK payment, there are specific steps to follow depending on the device being used and the processing.terminal_type
specified in the payment request.
Device | processing.terminal_type | After selecting redirect link |
---|---|---|
Computer |
| Select Pay Now |
Application |
| Select Pay Now |
Computer |
| For this method, make sure you have set up AlipayHK as an e-wallet under Common Settings in the Alipay+ Linker app. To choose the correct e-wallet, select TEST_WALLET.
|
Application |
|
|