Appearance
Storefront API
Use the Storefront API to build the customer-facing pages of a store: the product list, the product page, related products, and the payment options at checkout.
These endpoints are public. They do not need a customer token. Send the X-MerchantApiKey header so that the API can find the store. The storefront product endpoints return only products that are not archived. They return the public product data and do not return cost price or profit.
Endpoints
| Endpoint | Method | Path |
|---|---|---|
| Get Storefront Products | GET | /v1/storefront/products |
| Get Storefront Product | GET | /v1/storefront/products/{productId} |
| Get Storefront Product by Slug | GET | /v1/storefront/products/slug/{slug} |
| Get Similar Storefront Products | GET | /v1/storefront/products/similar/by/category/{productId} |
| Get Top Selling Storefront Products | GET | /v1/storefront/products/top-selling |
| Get Storefront Payment Gateways | GET | /v1/storefront/payment-gateways |
Typical storefront flow
- Show the product list: Get Storefront Products.
- Show a product page: Get Storefront Product.
- Add the product to the cart: Cart V2.
- Show the payment options: Get Storefront Payment Gateways.
- Create the order: Checkout (V2).
Errors
| Status | Message | Cause |
|---|---|---|
400 | 'PRODUCT' is no longer available. | The product is archived. |
404 | Product not found | The product ID or slug does not exist. |
