Skip to Content
DocumentationCheckouts

Checkouts

The Checkout API lets you create payment sessions, check their status, and list past checkouts.

Base URL: https://api.inzilink.com/api/v1

All requests require an API key in the Authorization header. See Authentication.


Create checkout

Creates a new payment session and returns a hosted checkout page URL.

POST /v1/checkouts

Request body

FieldTypeRequiredDescription
amountstringYesPayment amount. String to avoid float precision issues.
currencystringYesISO 4217 code. Currently supported: USD.
descriptionstringNoShown on checkout page. Max 256 chars.
metadataobjectNoArbitrary JSON (max 4KB). Returned in webhooks untouched.
customer_emailstringNoFor future receipt functionality.
redirect_urlstringNoWhere to redirect user after payment.
webhook_urlstringNoOverride merchant-level default webhook URL.
expires_inintegerNoSeconds until expiration. Default: 1800. Min: 300, Max: 86400.
curl -X POST https://api.inzilink.com/api/v1/checkouts \ -H "Authorization: Bearer sk_live_xxxxx" \ -H "Content-Type: application/json" \ -d '{ "amount": "25.00", "currency": "USD", "description": "Order #12345", "metadata": { "order_id": "uuid-xxx", "user_id": "uuid-yyy" }, "redirect_url": "https://yoursite.com/thank-you", "webhook_url": "https://yoursite.com/webhooks/inzi", "expires_in": 1800 }'

Response 201 Created

{ "id": "chk_live_abc123def456", "status": "pending", "amount": "25.00", "currency": "USD", "description": "Order #12345", "metadata": { "order_id": "uuid-xxx", "user_id": "uuid-yyy" }, "checkout_url": "https://inzilink.com/p/abc123def456", "expires_at": "2026-04-04T12:30:00Z", "created_at": "2026-04-04T12:00:00Z" }

Redirect the user to checkout_url. They’ll see a hosted payment page with chain/token selector, QR code, and copy-paste address.

Amount tolerance: Inzi accepts payments within max(1%, $0.05) of the requested amount to account for network rounding.


Get checkout

Retrieve the current state of a checkout. Use as fallback when a webhook doesn’t arrive.

GET /v1/checkouts/{checkout_id}

Response 200 OK

{ "id": "chk_live_abc123def456", "status": "completed", "amount": "25.00", "currency": "USD", "description": "Order #12345", "metadata": { "order_id": "uuid-xxx", "user_id": "uuid-yyy" }, "checkout_url": "https://inzilink.com/p/abc123def456", "payment": { "amount_crypto": "25.000000", "crypto_currency": "USDT", "network": "ton", "tx_hash": "abc123...", "sender_address": "UQ...", "confirmed_at": "2026-04-04T12:05:00Z" }, "expires_at": "2026-04-04T12:30:00Z", "created_at": "2026-04-04T12:00:00Z" }

The payment object is null when status is pending or expired.

Checkout statuses

StatusDescription
pendingAwaiting payment
processingPayment detected, awaiting confirmations
completedPayment confirmed on-chain
expiredNot paid before expires_at
underpaidReceived less than required amount

List checkouts

Paginated list of your checkouts. Useful for dashboards and reconciliation.

GET /v1/checkouts?status=completed&limit=20&offset=0

Query parameters

ParamTypeDescription
statusstringFilter by status. Optional.
limitintegerMax results. Default: 20, Max: 100.
offsetintegerPagination offset.
created_afterdatetimeFilter: created after this ISO 8601 timestamp.
created_beforedatetimeFilter: created before this ISO 8601 timestamp.

Response 200 OK

{ "data": [ { "id": "chk_live_abc123", "status": "completed", "amount": "25.00", "..." : "..." }, { "id": "chk_live_def456", "status": "pending", "amount": "10.00", "..." : "..." } ], "total": 142, "limit": 20, "offset": 0 }