Storefront Orders
Get order data immediately after an order is placed on the storefront.
For info about API accounts, see our Guide to API Accounts.
For info about authenticating BigCommerce APIs, see Authentication and Example Requests.
Get Order
GET /orders/{orderId}
Request
Returns Order data. This will return order data immediately after an order is placed on the storefront.
Note
- Substitute your storefront domain for
yourstore.example.com
. - The Send a Test Request feature is not currently supported for this endpoint.
Parameters
- store_domain in path - string
- orderId in path - integer - required
ID of an Order.
example
const options = {method: 'GET', headers: {'Content-Type': 'application/json'}}; fetch('https://yourstore.example.com/api/storefront/orders/[orderId]', options) .then(response => response.json()) .then(response => console.log(response)) .catch(err => console.error(err));
Response
Body
orderIdnumber
cartIdstring
The ID of cart that was converted to order.
currencyobject
This will always be the same between cart and checkout.
isTaxIncludedboolean
Whether this item is taxable.
baseAmountnumber
Cost of cartʼs contents before applying discounts.
discountAmountnumber
Discounted amount.
giftWrappingCostTotalnumber
Gift wrapping for all items, including or excluding tax.
orderAmountnumber
Sum of line-items amounts, minus cart-level discounts and coupons. This amount includes taxes where applicable.
orderAmountAsIntegernumber
Order amount represented in integer. Eg. 1234 for $12.34
couponsarray[object]
Array of
AppliedCoupon
objects applied to this cart.lineItemsarray[object]
Array of
LineItem
objects.customerIdstring
billingAddressobject
statusstring
Order status.
Allowed: INCOMPLETE | PENDING | SHIPPED | PARTIALLY_SHIPPED | REFUNDED | CANCELLED | DECLINED | AWAITING_PAYMENT | AWAITING_PICKUP | AWAITING_SHIPMENT | COMPLETED | AWAITING_FULFILLMENT | MANUAL_VERIFICATION_REQUIRED | DISPUTED | PARTIALLY_REFUNDED
Example: INCOMPLETE
hasDigitalItemsboolean
Specifies whether this order has at least one digital item.
isDownloadableboolean
Specifies whether this order is fully paid, so that digital items can be downloaded.
isCompleteboolean
Specifies whether this order is complete and ready to be taken to the order confirmation page.
customerMessagestring
Shopperʼs provided message for the order.
shippingCostTotalinteger
shippingCostBeforeDiscountinteger
handlingCostTotalinteger
customerCanBeCreatedboolean
taxesarray[object]
taxTotalinteger
channelIdnumber
ID of the channel which the order belongs to.
consignmentsobject
All the consignments of the order.
example
{ "orderId": 1, "cartId": "a978ee3d-b7bf-468a-b84b-28f1d6366abc", "currency": { "name": "string", "code": "string", "symbol": "string", "decimalPlaces": 0 }, "isTaxIncluded": true, "baseAmount": 0, "discountAmount": 0, "giftWrappingCostTotal": 0, "orderAmount": 0, "orderAmountAsInteger": 0, "coupons": [ { "id": "string", "code": "string", "displayName": "string", "couponType": "string", "discountedAmount": 0 } ], "lineItems": [ { "physicalItems": [ { "id": "string", "parentId": "string", "variantId": 0, "productId": 0, "sku": "string", "name": "string", "url": "string", "quantity": 0, "isTaxable": true, "imageUrl": "string", "discounts": {}, "discountAmount": 0, "couponAmount": 0, "listPrice": 0, "salePrice": 0, "extendedListPrice": 0, "extendedSalePrice": 0, "type": "string", "addedByPromotion": true, "isShippingRequired": true, "giftWrapping": { "name": "string", "message": "string", "amount": 0 }, "categories": [ {} ] } ], "digitalItems": [ { "id": "string", "parentId": "string", "variantId": 0, "productId": 0, "sku": "string", "name": "string", "url": "string", "quantity": 0, "isTaxable": true, "imageUrl": "string", "discounts": [ { "coupon": 8.28 } ], "discountAmount": 0, "couponAmount": 0, "listPrice": 0, "salePrice": 0, "extendedListPrice": 0, "extendedSalePrice": 0, "type": "string", "downloadFileUrls": [ "string" ], "downloadPageUrl": "string", "downloadSize": "string", "categories": [ {} ] } ], "giftCertificate": [ { "name": "string", "quantity": 0, "isTaxable": true, "amount": 0, "type": "string" } ] } ], "customerId": "string", "billingAddress": { "firstName": "string", "lastName": "string", "email": "string", "company": "string", "address1": "string", "address2": "string", "city": "string", "stateOrProvince": "string", "stateOrProvinceCode": "string", "country": "string", "countryCode": "string", "postalCode": "string", "phone": "string", "customFields": [ { "fieldId": "string", "fieldValue": "string" } ] }, "status": "INCOMPLETE", "hasDigitalItems": true, "isDownloadable": true, "isComplete": true, "customerMessage": "string", "shippingCostTotal": 0, "shippingCostBeforeDiscount": 0, "handlingCostTotal": 0, "customerCanBeCreated": true, "taxes": [ { "name": "string", "amount": 0 } ], "taxTotal": 0, "channelId": 0, "consignments": { "shipping": [ { "lineItems": [ { "id": 4 } ], "shippingAddressId": 1, "firstName": "first1", "lastName": "last1", "company": "company1", "address1": "2802 Skyway Cir", "address2": "Balcony", "city": "Austin", "stateOrProvince": "Texas", "postalCode": "78704", "country": "United States", "countryCode": "US", "email": "first1@bigcommerce.com", "phone": "0410123452", "itemsTotal": 1, "itemsShipped": 0, "shippingMethod": "Flat Rate", "baseCost": 15.5, "costExTax": 15.5, "costIncTax": 16.7, "costTax": 1.2, "costTaxClassId": 2, "baseHandlingCost": 0, "handlingCostExTax": 0, "handlingCostIncTax": 0, "handlingCostTax": 0, "handlingCostTaxClassId": 2, "shippingZoneId": 1, "shippingZoneName": "United States", "customFields": [ { "name": "special note", "value": "super rare" } ] } ] } }