Hosted checkout

Create a session, send the buyer to a page that takes the payment, and react to the result. You never touch a card number and you never open a merchant account.

The four steps

  1. Create a session. POST /v1/checkout/sessions with the buyer’s country, the currency, the mechanism and the pre-tax amount.
  2. Redirect the buyer. POST /v1/checkout/sessions/:id/hosted returns a URL. Send the browser there; the acquirer collects the card.
  3. Confirm on return. The buyer lands on /pay/<session-id>/return. Arilator asks the acquirer what happened and writes the order and ledger only on a confirmed payment.
  4. React. Deliver the product on order.paid. The order is the record; the webhook is the notification.

What the buyer sees

A single page on www.arilator.com/pay/<session-id>: the seller, one line describing what they are buying, subtotal, tax with its label, the total, and a pay button. Nothing else. Card entry happens on the acquirer’s page, so the statement descriptor is Arilator’s and the dispute is ours.

Which acquirers can host it

Hosted checkout is implemented for Stripe today, on both entities: STRIPE_US for buyers outside India, STRIPE_IN for buyers inside it. Adyen, Cashfree and Razorpay are connected for direct charges and payouts; their hosted pages are planned. If the resolved chain has nothing that can host a page, the call fails with ACQUIRER_NOT_CONFIGURED rather than silently charging another way.

Test and live

The acquirer credential decides the mode: a sk_test_… key produces a Stripe test checkout, a sk_live_… key produces a real one. There is no flag to flip and no chance of a test checkout charging a real card.

No acquirer, no charge. If the entity has no approved acquirer for the buyer’s country and currency, the page says so and nothing is charged. That is the state today: the account applications are in progress. See What works today.

Tax is added, not hidden

The subtotal is the price you set. Tax is computed from the buyer’s billing country and added on top; the label names the tax and the rate. A price you publish as €100 does not silently become €81 of revenue and €19 of tax — that difference is visible to the buyer before they pay.

Failure and retry

  • Session expired (15 minutes) — create a new one. The old link says so and charges nothing.
  • Soft decline — the acquirer chain fails over without the buyer re-entering details.
  • Hard decline — the chain stops and the buyer is told; nothing is retried silently.
  • Return page reloaded — safe. One order per session, enforced by a unique index.

Endpoint detail

Field-by-field reference is in Checkout API. The events are in Webhooks.