Payment integration errors are mostly not caused by a wrong key, but by the callback URL being unreachable: the site URL is set to an intranet address, or the WeChat Pay AppID is confused with the Open Platform website app AppID. This article explains the required fields and failure causes by channel.

1. Fill in the website URL first—callbacks depend entirely on it
All callback URLs are composed from the Website URL under "Settings → Site Basics → Basic Information". If it is https://shop.example.com, the callbacks are:
| Channel | Callback URL |
|---|---|
| WeChat Pay | /pay/notify/wechat |
| Alipay | /pay/notify/alipay |
| Mercado Pago | /pay/notify/mercadopago |
| Khipu | /pay/notify/khipu |
The website URL must be a public, externally accessible production address. If it is not filled in or set to a local address, the channel cannot call back—this is the number one reason why "payment was made but the order is still pending payment".
2. WeChat Pay: all six items are required
The web payment page displays a Native QR code for scanning; after a member logs in via official account authorization within WeChat, "Pay Now" is shown to invoke JSAPI. For JSAPI, you also need to configure the official account AppID and AppSecret under "Login Methods → WeChat Login" in the member module, and the official account AppID must match the WeChat Pay AppID.
The card has six items: WeChat Pay AppID, merchant ID, merchant certificate serial number, merchant API private key, APIv3 key, and platform certificate. It is considered configured only when all six are complete. A few key points:
- WeChat Pay AppID ≠ "WeChat Login AppID (Open Platform website app)"; confusing these two is the most common configuration error.
- The private key and APIv3 key are not displayed after saving; leaving the input blank means keeping the saved value.
- After platform certificate rotation, paste the new certificate again; otherwise all callback signature verifications will fail.
- The callback URL must be entered in the payment callback configuration of the WeChat Pay merchant platform.
- The "Enable WeChat Pay" switch is on by default; after it is turned off, WeChat Pay is no longer offered at frontend checkout or for AI/API orders, and the server will also reject it.

3. Alipay and other channels
Alipay uses Face-to-Face Payment pre-order, and the customer scans to pay. The callback is a form POST, and you need to configure the AppID, application private key, and Alipay public key; the system only recognizes TRADE_SUCCESS and TRADE_FINISHED, and other statuses do not change the order.
Latin American sites also have Mercado Pago and Khipu; in Chile, Webpay (Transbank) is available: create an order to obtain a token and redirect URL → buyer pays → callback carries token_ws, then commit. The system verifies whether pay_token and token_ws are bound to this order and whether the amount and order number match; only AUTHORIZED/CAPTURED with response_code=0 will be credited, and repeated returns do not cause duplicate crediting.
4. Merchant parameters and security boundaries
Merchant parameters are all entered in the backend; submitting them blank means keeping the original key, and the backend does not display the private key. Card numbers do not pass through the site, and the PCI scope remains on the channel side. The QR code is generated as a PNG on the server using the order's code_url; the payment page polls the status every 2 seconds and redirects to the result page once paid.
5. Common failures and troubleshooting order
- Payment succeeds but the order does not change: first check whether the website URL is publicly accessible, then confirm that the callback URL has been entered in the channel backend.
- Clicking "Pay Now" in WeChat reports an error: the official account AppID does not match the WeChat Pay AppID, or WeChat Login has not been configured in the member module.
- WeChat callback signature verification fails: the platform certificate has been rotated but not updated.
- The order does not change after Alipay receives payment: the callback status is not
TRADE_SUCCESS/TRADE_FINISHED, or the asynchronous notification URL was not composed from the website URL. - Duplicate callbacks cause duplicate crediting: this should not happen normally; repeated returns and token replacement will be rejected; if it occurs, check the audit log.
Summary
The order for payment configuration is: first set the website URL correctly, then fill in all parameters by channel, and finally register the callback URL on the channel side. When problems occur, troubleshoot in four steps—"can the URL be reached → are the parameters correct → has the certificate expired → is the status successful"—which is more effective than repeatedly re-pasting the key.