Search...
Log inGet started
Airwallex logo
Home
Core API
Payments
Transactional FX
Payouts
Issuing
Back to home
OverviewChoose your payments solutionGet started with payments
Online payments
Invoice integrations
Payment methods
Payment methods overviewGlobal
EU & UK
APAC
7-Eleven
Alipay
Alipay HK
Atome
Boost
DANA
DOKU Wallet
Dragonpay
DuitNow
E.SUN (Taiwan ATM & Internet banking)
FPS
GCash
GoPay
GrabPay - Malaysia
GrabPay - Singapore
Indonesian Bank Transfer
Indonesian Convenience Stores - BETA
Jenius Pay
Kakao Pay
Kiosk Payments
Konbini
LinkAja
OVO
Pay-easy
PayNow
Philippines Online Banking
PromptPay
Rabbit LINE Pay
ShopeePay
Taiwan Convenience Stores
Tesco Lotus
Thailand Online Banking
Touch 'n Go
TrueMoney
WeChat Pay
Website QRWeChat Pay ElementMobile App Mobile Browser (H5)
WeChat Official AccountWeChat Mini Program Customs Declaration WeChat Pay funds split
NORTH AMERICA & LATAM

Mobile Browser (H5)

Accept WeChat Pay on your mobile website by redirecting shoppers to WeChat App. See checkout experience as below. WeChat H5 payment flow

  1. The shopper chooses to pay with WeChat Pay and the shopper will be redirected to WeChat Pay App
  2. The shopper completes payment in WeChat Pay App
  3. Payment succeeds and the shopper is redirected back to the mobile browser page you designated
Note

To use WeChat H5 payment, extra offline review process is required, please contact your account manager for detailed information

Step 1. Initialize a payment Intent

Create a PaymentIntent object with a request_id, amount, currencyand a merchant_order_id from your backend server. Provide return_url to specify where shoppers will be redirected to both for cancelled payment and succeeded payment scenarios . Please note that the first level domain name of the return_url and the url you use to pull up the WeChat Pay shall both be aligned with the one you submitted to WeChat in the offline review process.

Shell

Step 2. Redirect to WeChat App to complete payment

When a shopper selects to pay with WeChat Pay on their mobile browser, call the following API endpoints to get a e-wallet cashier URL (next_action.url in API response), which you can redirect the shopper to WeChat App to complete payment.

  1. Obtain URL from Airwallex and redirect shopper to WeChat App

Request:

Shell

Response:

Shell
  1. Wait for notification from Airwallex

Airwallex will notify you on the payment result asynchronously via the webhook API. Please refer to webhook documentation to set up your webhook accordingly. Although subscribing to different events is optional, it is recommended to at least subscribe to the ‘payment_intent.succeeded’ which indicates that the shopper has successfully paid for the order via WeChat Pay.

  1. Query the PaymentIntent status

You may also query the status of a payment anytime via the PaymentIntents API

Shell
Note

WeChat Pay also support H5 flow from App, Please do add the the domain name you registered in WeChat Pay system as the referer when you request WeChat payment via the url we returned to you. If no, you cannot pull up WeChat App successfully.

To realize the scheme redirect, you shall use app-embedded browser to pull up WeChat Pay. Also, extra offline sheet needs to be filled and please wait WeChat to deploy configuration for you. In this case, you don’t need to pass return_url when creating PaymentIntent.