Orders & Checkout
List and manage orders, and create checkout sessions for products. The checkout and product-info endpoints are public (used by the widget/Telegram).
GET
/api/v1/sites/{id}/orders AuthList orders for a site.
Response
{ "success": true, "orders": [ { "id": 30, "product": "Haircut", "amount": 5000, "currency": "usd", "status": "paid" } ] }DELETE
/api/v1/sites/{id}/orders/{orderId} AuthDelete an order.
Response
{ "success": true }GET
/api/v1/product-info PublicGet public product info for checkout.
| Param | Type | In | Description |
|---|---|---|---|
site_key | string | query | Required |
product_id | int | query | Required |
lang | string | query | Optional |
Response
{ "success": true, "product": { "id": 8, "name": "Haircut", "formatted_price": "$50.00" } }POST
/api/v1/product-checkout PublicCreate a checkout session and return the payment URL. amount is optional for pay-what-you-want products.
Request body
{ "site_key": "sk_…", "product_id": 8, "conversation_id": 50, "visitor_email": "[email protected]" }Response
{ "success": true, "checkout_url": "https://checkout.stripe.com/…" }