Documentation/Référence API

API REFERENCE

Augmenter l’autorisation

POSThttps://mapi.yabandpay.com/Payments
Live API
API PLAYGROUND · Live API

Augmenter l’autorisation

POSThttps://mapi.yabandpay.com/Payments
Automatically signed with your credentials

Request parameters6

Required fields first

增加预授权

trade_idRequiredstringdata.trade_id对应增加预授权的trade_id
amountRequiredstringdata.amount金额数字。例如 € 24.99 应该写成24.99
currencyRequiredstringdata.currency货币代码,ISO 4217,例如EUR,CHF
descriptionRequiredstringdata.description订单描述
notify_urlRequiredstringdata.notify_url支付完成后异步通知地址
request_idRequiredstringdata.request_id请求id需保持唯一,建议24以上位数字+字母

Credentials stay on this page. Your secret key is never stored or sent to the documentation server.

Paramètres

ParameterTypeDescriptionObligatoire
data.trade_idstring对应增加预授权的trade_id✓
data.amountstring金额数字。例如 € 24.99 应该写成24.99✓
data.currencystring货币代码,ISO 4217,例如EUR,CHF✓
data.descriptionstring订单描述✓
data.notify_urlstring支付完成后异步通知地址✓
data.request_idstring请求id需保持唯一,建议24以上位数字+字母✓
ParamètreTypeDescriptionObligatoire
userStringCashier account UIDObligatoire
signStringSignatureObligatoire
methodStringv3.PreauthIncrementObligatoire
timeLongTimestampObligatoire
  • Parameters
ParamètreTypeDescriptionObligatoire
trade_idStringtrade_id of the authorization to increaseObligatoire
amountStringNumeric amount. For example, € 24.99 must be written as 24.99Obligatoire
currencyStringISO 4217 currency code, such as EUR or CHFObligatoire
descriptionStringOrder descriptionObligatoire
notify_urlStringAsynchronous notification URL after payment completionObligatoire
request_idStringUnique request id; at least 24 alphanumeric characters are recommendedObligatoire

Signature example:

Sorted parameters concatenated into a URL-style query string

"amount=1&currency=EUR&description=test&method=v3.PreauthIncrement&notify_url=https://www.yabandpay.com/notify&request_id=ca51f2fas3i0f8uiw7efj6oe4i2w1ghj&time=1720684254&trade_id=160899f3-f6d9-a8d8-ab5b-82eacdab9c5b&user=YOUR_CASHIER_UID"

Sign stringA using secret_key

Le champ resulting signature is:

"YOUR_SIGNATURE"

Exemple de requête:

{
  "user": "YOUR_CASHIER_UID",
  "sign": "YOUR_SIGNATURE",
  "method": "v3.PreauthIncrement",
  "time": 1720684254,
  "data": {
    "description": "test",
    "trade_id": "160899f3-f6d9-a8d8-ab5b-82eacdab9c5b",
    "amount": "1",
    "currency": "EUR",
    "notify_url": "https://www.yabandpay.com/notify",
    "request_id": "ca51f2fas3i0f8uiw7efj6oe4i2w1ghj"
  }
}

Exemple de réponse:

{
  "status": true,
  "code": "200",
  "data": {
    "order_id": "YOUR_ORDER_ID",
    "trade_id": "160899f3-f6d9-a8d8-ab5b-82eacdab9c5b",
    "amount": "1",
    "currency": "EUR",
    "state": "authorized"
  },
  "message": "",
  "response_id": "202407111550570060848432"
}

Informations complémentaires:

Résultat de la réponse:
  1. Une requête réussie renvoie "status": true.

  2. Une requête échouée renvoie "status": false.

Cette API augmente le montant de l’autorisation. Le résultat est renvoyé de manière synchrone.

Response codes:
StatusCodeMessage
true200
false-1000Internal error
false-403The signature Error
false-2001The user not exist
false-3001Required field is missing
false-4118Incorrect request ID
false-4024The original trade ID is incorrect