Checkout Sessions
A Checkout Session creates a hosted payment page with a shareable URL. The customer visits the URL, selects their mobile money operator, enters their phone number, and confirms the payment.
Two Modes
- Items mode — Pass a list of line items with quantities and unit prices
- Amount mode — Pass a fixed total amount
You must provide either items or amount, but not both.
Expiration
Sessions expire after 30 minutes by default. Use expiresInMinutes (5-1440) to customize.
Endpoints
| Method | Path | Description |
|---|
POST | /v1/checkout/sessions | Create a session |
GET | /v1/checkout/sessions/{id} | Get a session |
GET | /v1/checkout/sessions | List sessions |
POST | /v1/checkout/sessions/{id}/expire | Expire a session |