API REFERENCE
Paiements intégrés à l’application
Paramètres
| Parameter | Type | Description | Obligatoire |
|---|---|---|---|
| data.pay_method | string | online | ✓ |
| data.sub_pay_method | string | Alipay | ✓ |
| data.sub_pay_method_type | string | 参考支持的钱包列表 | — |
| data.order_id | string | 商户的订单ID | ✓ |
| data.amount | string | 金额数字。例如 € 24.99 应该写成24.99,CNY金额>=1,欧元金额>=0.1 | ✓ |
| data.currency | string | 货币代码,ISO 4217,例如EUR,CHF | ✓ |
| data.description | string | 订单描述 | ✓ |
| data.demo | string | 自定义字段 | — |
| data.timeout | string | 过期时间单位分钟(0-1440) | ✓ |
| data.notify_url | string | 支付完成后异步通知地址 | ✓ |
| data.redirect_url | string | 支付完成后跳转地址;IOS和Android注意:回调到APP处理的,需要applink或者deeplink做回调处理 | — |
| data.os_type | string | 安卓端传android 苹果端传ios | ✓ |
| Paramètre | Type | Description | Obligatoire |
|---|---|---|---|
| user | String | Compte marchand UID | Obligatoire |
| sign | String | Signature | Obligatoire |
| method | String | v3.CreatePaymentsAlipayAppPay | Obligatoire |
| time | Long | Timestamp | Obligatoire |
- Parameters | Paramètre | Type | Description | Obligatoire | |:---------------|:--- |:-----------------------------------------------------------|:--- | | pay_method | String | online | Obligatoire | | sub_pay_method | String | Alipay | Obligatoire | | sub_pay_method_type | String | Voir la liste des portefeuilles pris en charge | Facultatif | | order_id | String | ID de commande du marchand | Obligatoire | | amount | String | Montant numérique. Par exemple, € 24.99 doit être indiqué sous la forme 24.99; CNY amount>=1, montant en euros ≥0.1 | Obligatoire | | currency | String | code devise ISO 4217, par exemple EUR ou CHF | Obligatoire | | description | String | Description de la commande | Obligatoire | | demo | String | Champ personnalisé | Facultatif | | timeout | String | Durée d’expiration en minutes (0-1440) | Obligatoire | | notify_url | String | URL de notification asynchrone après le paiement | Obligatoire | | redirect_url | String | URL de redirection après le paiement. Sur iOS et Android, utilisez un lien d’application ou un lien profond pour gérer le retour vers l’application | Facultatif | | os_type | String | Transmettez android pour Android et ios pour Apple | Obligatoire |
Exemple de signature:
Paramètres triés et concaténés sous forme de chaîne de requête au format URL
"amount=1¤cy=EUR&description=YabandPay test&method=v3.CreatePaymentsAlipayAppPay¬ify_url=https://www.yabandpay.com/notify&order_id=202412654894165484&os_type=ios&pay_method=online&redirect_url=https://www.yabandpay.com/redirect_url&sub_pay_method=Alipay&time=1546588959&timeout=0&user=YOUR_CASHIER_UID"
Signez la chaîne A à l’aide de secret_key
La signature obtenue est :
"YOUR_SIGNATURE"
Exemple de requête:
{
"user": "YOUR_CASHIER_UID",
"sign": "YOUR_SIGNATURE",
"method": "v3.CreatePaymentsAlipayAppPay",
"time": 1546588959,
"data": {
"description": "YabandPay test",
"timeout": "0",
"pay_method": "online",
"sub_pay_method": "Alipay",
"order_id": "YOUR_ORDER_ID",
"amount": "1",
"currency": "EUR",
"notify_url": "https://www.yabandpay.com/notify",
"redirect_url": "https://www.yabandpay.com/redirect_url",
"os_type": "ios"
}
}
Exemple de réponse:
{
"status": true,
"code": "200",
"data": {
"order_id": "YOUR_ORDER_ID",
"trade_id": "e5baf40b-08b2-4660-ed20-d632eeeceab3",
"amount": "0.01",
"currency": "EUR",
"parameters": {
"pay_url": "https://open-sea-global.alipayplus.com/api/open/v1/ac/cashier/self/codevalue/checkout.htm?codeValue=281666040097PyqF6IxZEzTURq7PhvTv3ken",
"payments_data": "{\"displayPaymentAmount\":\"0.01\",\"displayPaymentCurrency\":\"EUR\",\"wallets\":[{\"enabled\":true,\"promoNames\":[\"{\\\"en_US\\\":\\\"test\\\",\\\"nl_NL\\\":\\\"test\\\"}\"],\"searchKeywords\":[\"dana wallet\"],\"walletName\":\"DANA\"}]}"
},
"state": "processing"
},
"message": ""
}
Informations complémentaires:
Si votre application utilise une webview, redirigez directement vers pay_url.
Si votre application est développée pour iOS ou Android, téléchargez le SDK correspondant : Download .
Consultez la documentation officielle de AliPay+ documentation for integration.
Résultat de la réponse:
-
Une requête réussie renvoie "status": true.
-
Une requête échouée renvoie "status": false.
Nous recommandons vivement d’utiliser à la fois Consulter la commande and Asynchronous Notifications afin de maintenir les statuts de paiement exacts et à jour.
Portefeuilles pris en charge par Alipay+ :
Les portefeuilles correspondant à sub_pay_method_type prennent en charge les scénarios de paiement suivants :
| sub_pay_method_type | APP | WAP | Web | Mini Program |
|---|---|---|---|---|
| ALIPAY_CN | ✅ | ❌ | ✅ | ✅ |
| TRUEMONEY | ✅ | ❌ | ✅ | ✅ |
| ALIPAY_HK | ✅ | ✅ | ✅ | ✅ |
| TNG | ✅ | ✅ | ✅ | ✅ |
| GCASH | ✅ | ✅ | ✅ | ✅ |
| DANA | ✅ | ✅ | ✅ | ✅ |
| KAKAOPAY | ✅ | ❌ | ✅ | ❌ |
| RABBIT_LINE_PAY | ✅ | ❌ | ✅ | ❌ |
| BPI | ❌ | ✅ | ✅ | ❌ |
| BOOST | ✅ | ✅ | ✅ | ❌ |
| AKULAKU_PAYLATER | ✅ | ✅ | ✅ | ❌ |
| BILLEASE | ✅ | ✅ | ✅ | ❌ |
| TINABA | ✅ | ✅ | ✅ | ❌ |
| NAVERPAY | ❌ | ✅ | ✅ | ❌ |
| TOSSPAY | ✅ | ❌ | ✅ | ✅ |
| MPAY | ✅ | ✅ | ✅ | ❌ |
| KREDIVO_ID | ✅ | ❌ | ✅ | ❌ |
| KPLUS | ✅ | ✅ | ✅ | ❌ |
| HIPAY | ✅ | ✅ | ✅ | ✅ |
Codes de réponse:
| Status | Code | Message |
|---|---|---|
| true | 200 | Success |
| false | -1000 | Internal error |
| false | -3001 | Required field is missing |
| false | -403 | The signature Error |
| false | -4011 | Not support the payment method |
