Skip to content
Docs

Payment links

POST/api/payments/link

Create a Payment Link

Generate Payment link or QR Code.

Server-side request · headers mid + terminal-idTry it in Sandbox

Request body

FieldTypeDescription
amountRequirednumber

The payment amount. For payment of 100 AED it must be 100 for 100.50 it must be written as 100.50

Min 1e.g. 100
currencyRequiredstring

The three-letter ISO currency code.

Min length 3Max length 3e.g. AED
order_idRequiredstring

A order id you can later use to identify this payment, such as an order number. Can only be alphanumeric and must be unique for Benefit.

Max length 50e.g. ORD-10482
referenceOptionalstring

A reference to this payment.

Max length 50e.g. ORD-10482
request_typeRequiredstring

This will give you response accordingly base on type.

One of QRCODELINK
customer_emailOptionalstring

Optional. Customer Email Id. Customer email notifications are only sent when this is provided. If not sent, the customer is asked for it on the payment page.

e.g. aisha.rahman@example.com
customer_mobileOptionalstring

Optional. Customer mobile number including country code, without spaces, special characters, or + sign. For example, for a UAE number, it should start with 971 followed by the mobile number (e.g., 9715*******84). Customer SMS notifications are only sent when this is provided. If not sent, the customer is asked for it on the payment page.

e.g. 971501234567
customer_first_nameOptionalstring

Optional. Customer First Name. If not sent, the customer is asked for it on the payment page.

e.g. Aisha
customer_last_nameOptionalstring

Optional. Customer Last Name. If not sent, the customer is asked for it on the payment page.

e.g. Rahman
captureOptionalboolean

Whether to capture the payment.

Default true
success_urlOptionalstring

For redirect success payment methods.

Max length 1024e.g. https://example.com/checkout/success
failure_urlOptionalstring

For redirect failure payment methods.

Max length 1024e.g. https://example.com/checkout/failed
send_emailOptionalboolean

This will send a notification to the merchant through email.

Default true
send_smsOptionalboolean

This will send a notification to the merchant through SMS.

Default true
send_customer_emailOptionalboolean

This will send a notification to the customer through email.

Default false
send_customer_smsOptionalboolean

This will send a notification to the customer through SMS.

Default false
alternative_merchant_emailOptionalstring

Alternative merchant Email Id.

e.g. payments@example.com
alternative_merchant_mobileOptionalstring

Alternative merchant Mobile Number.

e.g. 971561234567
alternative_customer_emailOptionalstring

Alternative customer Email Id.

e.g. aisha.r@example.com
alternative_customer_mobileOptionalstring

Alternative customer Mobile Number.

e.g. 971551234567
metadataOptionalobject

Allows you to store additional information about a transaction with custom fields, which can be used for reporting purposes. Note that this object only allows one level of depth, so cannot accept non-primitive data types such as objects or arrays.

instalment_bank_listOptionalarray of objects

Restrict the split payment to specific banks and optionally limit which split payment tenures are shown. If provided, only the specified banks will be displayed on the payment page. If the instalment array is omitted for a bank, all available tenures for that bank will be shown. Each bank_code must be a valid code from the supported list. For the full list of supported bank codes, visit https://geturbanledger.com/docs/instalment_bank_codes

instalment_bank_list[].bank_codeRequiredstring

The bank identifier code. Must be one of the supported split payment bank codes (e.g., EMIRATES_NBD, MASHREQ, ADCB, LIV, HSBC_ME, RAKBANK, FAB, DUBAI_FIRST). For the complete code list, visit https://geturbanledger.com/docs/instalment_bank_codes

e.g. EMIRATES_NBD
instalment_bank_list[].instalmentOptionalarray of number

Optional. An array of split payment tenure months to allow for this bank (e.g., [3, 6, 9, 12]). If not provided or empty, all available split payment tenures for the bank will be shown. Each value must be a valid tenure offered by the specified bank.

Headers

FieldTypeDescription
midRequiredstring

Your MID, starts with ul-mid.

e.g. ul-mid-696f12de-46d0-48c4-a7c8-bb*********5
terminal-idRequiredstring

Your terminal id, starts with ul-tid.

e.g. ul-tid-6208df4ad7329e*********e

Responses

StatusDescription
200 OKSuccess
400 Bad requestBad Request
401 UnauthorizedUnauthorized

Response fields 200

FieldTypeDescription
request_idOptionalstring

Payment request id.

e.g. 631725c9a5bcfd0d3*******
linkOptionalstring

Payment URL for the link or QR Code.

e.g. https://api.geturbanledger.com/api/merchant/payment-link/631725c9a5bcfd0d3*******
POSThttps://sandbox.geturbanledger.com/api/payments/link
curl -X POST "https://sandbox.geturbanledger.com/api/payments/link" \
  -H "Content-Type: application/json" \
  -H "mid: sb-ul-mid-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx" \
  -H "terminal-id: ul-tid-xxxxxxxxxxxxxxxxxxxxxxxx" \
  -d '{
  "amount": 100,
  "currency": "AED",
  "order_id": "ORD-10482",
  "reference": "ORD-10482",
  "request_type": "QRCODE",
  "customer_email": "aisha.rahman@example.com",
  "customer_mobile": "971501234567",
  "customer_first_name": "Aisha",
  "customer_last_name": "Rahman",
  "capture": true,
  "success_url": "https://example.com/checkout/success",
  "failure_url": "https://example.com/checkout/failed",
  "send_email": true,
  "send_sms": true,
  "send_customer_email": false,
  "send_customer_sms": false,
  "alternative_merchant_email": "payments@example.com",
  "alternative_merchant_mobile": "971561234567",
  "alternative_customer_email": "aisha.r@example.com",
  "alternative_customer_mobile": "971551234567",
  "metadata": {
    "channel": "web",
    "customer_ref": "CUST-10482"
  },
  "instalment_bank_list": [
    {
      "bank_code": "EMIRATES_NBD",
      "instalment": [
        3,
        6,
        9
      ]
    },
    {
      "bank_code": "MASHREQ"
    },
    {
      "bank_code": "FAB",
      "instalment": [
        6,
        12
      ]
    }
  ]
}'
Response
200 OK · Success
{
  "request_id": "631725c9a5bcfd0d3*******",
  "link": "https://api.geturbanledger.com/api/merchant/payment-link/631725c9a5bcfd0d3*******"
}
Talk to ustalk-to-us