WeChat Pay integration: QR-code checkout with APIv3
Accept WeChat Pay in ShipAny with the APIv3 Native Pay flow — a QR-code checkout page, encrypted payment notifications and automatic credit grants.
Last updated: Oct 8, 2026
WeChat Pay is how hundreds of millions of people pay online in China. ShipAny ships a native WeChat Pay provider built on APIv3, so you can take RMB payments directly with your own merchant account.
What ShipAny handles
- Native Pay checkout: ShipAny creates a transaction with
/v3/pay/transactions/nativeand sends the user to a QR-code page; they scan it with WeChat to pay. - Payment notifications at
/api/payment/notify/wechat, decrypted with your APIv3 key. ShipAny answers with the{ code: "SUCCESS" }JSON WeChat expects. - Order queries by out-trade-no as a fallback, so a paid order is confirmed even if a notification is delayed.
- Orders and credits: a successful payment marks the order paid and grants credits in one transaction.
- A test amount in fen (分) to run a ¥0.01 payment before launch.
Native WeChat Pay is used for one-time payments. For recurring billing, use Stripe or Creem.
Setup
- In the WeChat Pay merchant platform, make sure Native payment is enabled for your merchant ID and bound to your AppID.
- Set a 32-character APIv3 key, then apply for a merchant API certificate and note its serial number and private key (PEM).
- In ShipAny, open Admin → Settings → Payment → WeChat Pay: switch on Enable WeChat Pay and fill in the AppID, merchant ID, APIv3 key, merchant private key, certificate serial number, and the notify URL
https://<your-domain>/api/payment/notify/wechat. - Set the test amount to
1, scan the QR code to pay ¥0.01, then clear it before launch.
Tips
- The APIv3 key must be exactly 32 characters — notifications can't be decrypted otherwise.
- The serial number must match the private key you uploaded; a mismatch shows up as signature errors when creating transactions.
- Selling internationally too? Stripe can offer WeChat Pay for one-time payments without a Chinese merchant account.
