Skip to content
Docs

Payments

POST/api/payments/seamless

Seamless Integration

server to server seamless integration.

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
captureOptionalboolean

Whether to capture the payment.

Default true
customer_emailRequiredstring

customer email id.

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

customer mobile.

e.g. 971501234567
customer_first_nameRequiredstring

customer First Name.

e.g. Aisha
customer_last_nameRequiredstring

customer Last Name.

e.g. Rahman
success_urlRequiredstring

For redirect success payment methods.

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

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 false
send_smsOptionalboolean

This will send a notification to the merchant through SMS.

Default false
cardRequiredobject

Allows you to send card information.

card.numberOptionalstring

Card number.

e.g. 4242424242424242
card.expiry_monthOptionalstring

Card expiry month.

e.g. 12
card.expiry_yearOptionalstring

Card expiry year.

e.g. 2029
card.cvcOptionalstring

Card CVC/CVV.

e.g. 123
card.card_holder_nameOptionalstring

Name on card.

e.g. Aisha Rahman
instalment_planOptionalobject

Split payment (EPP). Required when split payments are enabled on your account, and rejected when they are not. Cannot be combined with session_id - split payments require card details. Fetch the available banks and tenures from POST /api/payments/epp/banks.

instalment_plan.bank_codeRequiredstring

The bank the customer selected, as returned by POST /api/payments/epp/banks (e.g. EMIRATES_NBD, MASHREQ, ADCB, LIV, HSBC_ME, RAKBANK, FAB, DUBAI_FIRST). The card used must belong to this bank.

e.g. EMIRATES_NBD
instalment_plan.tenureRequirednumber

The tenure in months the customer selected. Must be one of the tenures that bank offers your account.

e.g. 6
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.

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
redirect_urlOptionalstring

3ds payment page link.

e.g. https://api.geturbanledger.com/api/payments/665717cedf61dee714e1a0d2/process
statusOptionalstring

Payment status.

e.g. Pending
messageOptionalstring

Request message.

e.g.
merchant_order_idOptionalstring

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
transactionIdOptionalstring

The Urban Ledger transaction id for this payment.

e.g. UL_665717cedf61dee714e1a0d2
payment_customer_nameOptionalstring

Customer full name.

e.g. Aisha Rahman
payment_customer_emailOptionalstring

Customer email id.

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

Customer mobile number.

e.g. 9715*******84
typeOptionalstring

Request type.

e.g. API
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_planOptionalobject

Returned only for split payments (EPP) - a summary of the split payment plan that was booked.

instalment_plan.bank_codeOptionalstring—
e.g. EMIRATES_NBD
instalment_plan.bank_nameOptionalstring—
e.g. Emirates NBD
instalment_plan.bank_typeOptionalstring—
One of MANUALAUTOMATICBANKING_APP
instalment_plan.tenureOptionalnumber

Tenure in months.

e.g. 6
instalment_plan.monthly_amountOptionalnumber

The amount the customer pays each month.

e.g. 166.67
instalment_plan.fee_amountOptionalnumber

The bank's processing fee for this amount and tenure.

e.g. 30
instalment_plan.total_amountOptionalnumber

The amount plus the processing fee.

e.g. 1030
instalment_plan.plan_statusOptionalstring

APPROVED for MANUAL and BANKING_APP banks; PENDING for AUTOMATIC banks, which the bank confirms asynchronously.

One of APPROVEDPENDING
POSThttps://sandbox.geturbanledger.com/api/payments/seamless
curl -X POST "https://sandbox.geturbanledger.com/api/payments/seamless" \
  -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",
  "capture": true,
  "customer_email": "aisha.rahman@example.com",
  "customer_mobile": "971501234567",
  "customer_first_name": "Aisha",
  "customer_last_name": "Rahman",
  "success_url": "https://example.com/checkout/success",
  "failure_url": "https://example.com/checkout/failed",
  "card": {
    "number": "4242424242424242",
    "expiry_month": "12",
    "expiry_year": "2029",
    "cvc": "123",
    "card_holder_name": "Aisha Rahman"
  },
  "metadata": {
    "channel": "web",
    "customer_ref": "CUST-10482"
  }
}'
Response
200 OK · Success
{
  "redirect_url": "https://api.geturbanledger.com/api/payments/665717cedf61dee714e1a0d2/process",
  "status": "Pending",
  "message": "",
  "merchant_order_id": "ORD-10482",
  "transactionId": "UL_665717cedf61dee714e1a0d2",
  "payment_customer_name": "Aisha Rahman",
  "payment_customer_email": "aisha.rahman@example.com",
  "payment_customer_mobile_number": "9715*******84",
  "type": "API",
  "reference": "ORD-10482",
  "metadata": {
    "channel": "web",
    "customer_ref": "CUST-10482"
  }
}
Talk to ustalk-to-us