Create an order that was prepared outside the Bolt ecosystem.
Create an order that was prepared outside the Bolt ecosystem. Some Bolt-powered flows automatically manage order creation - in those flows the order ID will be provided separately and not through this API.
Authorization
api-key X-API-Key<token>
In: header
Header Parameters
X-Publishable-Key*string
The publicly shareable identifier used to identify your Bolt merchant division.
X-Merchant-Client-Id?string
A unique identifier for a shopper's device, generated by Bolt. The value is retrieved with Bolt.state.merchantClientId in your frontend context, per-shopper. This header is required for proper attribution of this operation to your analytics reports. Omitting this header may result in incorrect statistics.
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
curl -X POST "https://example.com/orders" \ -H "X-Publishable-Key: string" \ -H "Content-Type: application/json" \ -d '{ "profile": { "first_name": "Charlie", "last_name": "Dunn", "email": "charlie@example.com", "phone": "+14085551111" }, "cart": { "total": { "units": 1000, "currency": "USD" }, "tax": { "units": 100, "currency": "USD" }, "order_reference": "instore_20240116-878", "order_description": "Order #878", "display_id": "20240116-878", "items": [ { "name": "Red Fidget Spinner", "reference": "sku-984", "description": "Single-packed fidget spinner, red", "total_amount": { "units": 1000, "currency": "USD" }, "unit_price": 1000, "quantity": 1, "image_url": "https://www.example.com/products/984/image.png" } ], "shipments": [ { "cost": { "units": 10000, "currency": "USD" }, "carrier": "FedEx", "address": { ".tag": "explicit", "first_name": "Charlie", "last_name": "Dunn", "street_address1": "535 Mission St", "locality": "San Francisco", "postal_code": "94105", "region": "CA", "country_code": "US" } } ] } }'{ "id": "3Cxr2keCtxju", "transaction": { "reference": "2ZF2-WZ3J-WD2Y" }}