StorefrontGetOrder
/rpc#StorefrontGetOrderOrder pages for guests (signed access links) and signed-in shoppers. Routed to the storefront RPC server by the x-storefront-request: true header. The store is resolved from the merchant domain's Host, so call it through the storefront route POST https://<store-domain>/api/orders/get, which forwards the shopper's cookies. The viewer is the signed-in shopper or a guest holding an order access grant cookie.
Authorization
customerSession Shopper session cookie (name prefix storefront), set by CustomerOtpVerify and managed by the browser.
In: cookie
Header Parameters
Value in
- "true"
Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Value in
- "Request"
Correlates the response line with this request.
Value in
- "StorefrontGetOrder"
Leave empty; the server prepends the HTTP request headers.
items <= 0Response Body
application/json
curl -X POST "https://$STORE_DOMAIN/api/orders/get" \ -H "Content-Type: application/json" \ -b "$CUSTOMER_SESSION_COOKIE" \ -d '{"orderId":"<uuid>"}'{ "_tag": "Exit", "requestId": "string", "exit": { "_tag": "Success", "value": { "orderId": "string", "status": "draft", "buyerStatus": "not_paid", "customerEmail": "string", "total": { "amountMinorUnits": "string", "currency": "AED" }, "adjustments": [ { "type": "discount", "label": "string", "amount": { "amountMinorUnits": "string", "currency": "AED" } } ], "createdAt": "string", "payment": { "paymentMethod": { "providerId": "stripe", "displayName": "string", "description": "string", "iconUrl": "string", "capabilities": { "canCapture": true, "canRefund": true, "canPartialRefund": true, "requiresManualVerification": true, "notifications": [ "webhook" ], "supportsPreauthorization": true, "hasApiValidation": true, "redeemsVouchers": true } }, "checkoutSessionId": "string", "transactionId": "string", "cryptoInvoice": { "paymentId": "string", "status": "pending", "asset": "btc", "assetLabel": "string", "address": "string", "amountDisplay": "string", "receivedDisplay": "string", "overpaidDisplay": "string", "receivedComparison": "short", "txIds": [ "string" ], "lateSeenAt": "string", "acceptable": true } }, "items": [ { "productName": "string", "variantName": "string", "options": [ { "name": "string", "value": "string" } ], "quantity": 1, "unitPrice": { "amountMinorUnits": "string", "currency": "AED" }, "charges": [ { "description": "string", "amount": { "amountMinorUnits": "string", "currency": "AED" } } ], "downloadUrl": "string", "deliveredKeys": [ { "value": "string", "status": "active" } ], "webhookDelivery": { "status": "pending", "deliverables": [ "string" ], "message": "string" }, "instructions": "string", "ships": true, "deliveryReports": [ { "id": "string", "quantity": -9007199254740991, "label": "string", "url": "string", "reportedAt": "string" } ], "oversold": true, "replacements": [ { "id": "string", "variantName": "string", "options": [ { "name": "string", "value": "string" } ], "quantity": -9007199254740991, "status": "held", "holdExpiresAt": "string", "label": "string", "url": "string", "shippedAt": "string" } ] } ], "log": [ { "id": "string", "eventType": "order_draft", "actorType": "system", "createdAt": "string" } ] } }}StorefrontDownloadInvoice POST
Signed invoice downloads for an order's viewer. Routed to the storefront RPC server by the `x-storefront-request: true` header. The store is resolved from the merchant domain's `Host`, so call it through the storefront route `POST https://<store-domain>/api/orders/invoice`, which forwards the shopper's cookies. The viewer is the signed-in shopper or a guest holding an order access grant cookie.
OrderLineDeliveryReport POST
How a plugin with the store's deliveries:write grant reports what it delivered on a line. A store API key can call it, unless the key is read-only. Plugins can call this RPC with the invocation token after the store grants `deliveries:write`.
