Bearer token with
marketing:read scopeRequest body
The promotion code to validate
Customer ID to check per-customer usage limits
Array of product IDs in the order (for product-specific promotions)
Array of category IDs in the order (for category-specific promotions)
Order total in minor units (cents) to calculate discount
3-letter ISO currency code
Response
Whether the code is valid
Error code if invalid (see table below)
Human-readable error message if invalid
Promotion details if valid
Code details if valid
Calculated discount in minor units (if order_total_minor provided)
Currency of the discount
Error codes
| Error | Description |
|---|---|
invalid_code | Code not found |
inactive_code | Code is not active |
not_yet_valid | Code validity period hasn’t started |
expired_code | Code has expired |
max_uses_reached | Code has reached maximum uses |
promotion_not_found | Parent promotion not found |
promotion_inactive | Promotion is not active |
promotion_not_yet_valid | Promotion validity period hasn’t started |
promotion_expired | Promotion has expired |
promotion_max_uses_reached | Promotion has reached maximum uses |
below_minimum_order | Order doesn’t meet minimum value |
currency_mismatch | Order currency doesn’t match promotion |
product_excluded | Products in order are excluded |
category_excluded | Categories in order are excluded |
product_not_applicable | Products not eligible for this promotion |
category_not_applicable | Categories not eligible for this promotion |
customer_max_uses_reached | Customer has used this code maximum times |
Request
Response (Valid)
Response (Invalid)