Starts a checkout session for a replacing (redeem + pay) order using the merchant’s public key. This endpoint does not require the x-api-key header — the public key in the path authenticates the call.
When phone_number is provided but no matching customer exists, the returned checkout_url lands on an onboarding page where the customer can register before paying. The response shape is identical in both cases.
Public key that identifies the merchant.
Checkout amount (SAR).
x >= 0150.75
Merchant order reference. A leading # is stripped server-side.
"ORD-2024-0001"
Customer phone number. Accepted formats: +966XXXXXXXXX, 00966XXXXXXXXX, 966XXXXXXXXX, 0XXXXXXXXX, or bare 5XXXXXXXX. Normalised server-side to 5\d{8}.
"512345678"
Customer name.
255"Ahmed Al-Saud"
x >= 015
x >= 022.5
x >= 010
Optional shipping address. All fields are individually optional.
Line items. Nullable — orders can be created without per-item detail.
1Optional metadata that will be stored with the order.
{
"source": "mobile_app",
"notes": "Deliver ASAP"
}URL to redirect the customer after checkout completion.
"https://merchant.example.com/callback"