Cart Rule Detail
Returns a single cart rule with its full field set — the data behind the admin Marketing → Promotions → Cart Rules view screen.
TIP
New here? Read the Cart Rules overview for what a cart rule does and how its fields behave.
Operation
| Operation | Type | Purpose |
|---|---|---|
adminMarketingCartRule | Query | Fetch one cart rule by id |
Details
- Requires an admin Bearer token in the
Authorizationheader. - Pass the rule's IRI (e.g.
/api/admin/marketing/cart-rules/47) as theidargument;_idin the response is the numeric id. - Unlike list rows, the detail query resolves
conditions,channels, andcustomerGroups— the per-rule targeting and condition data.
Fields
| Field | Type | Notes |
|---|---|---|
id | ID | The rule's IRI |
_id | Int | Numeric id |
name | String | Rule name |
description | String | Free-text description |
startsFrom | String | Start date (ISO 8601) or null |
endsTill | String | End date (ISO 8601) or null |
status | Int | 0 inactive / 1 active |
couponType | Int | 0 no coupon (auto-applies) / 1 specific coupon code |
useAutoGeneration | Int | 1 when coupon codes are auto-generated |
usagePerCustomer | Int | Per-customer usage limit (0 = unlimited) |
usesPerCoupon | Int | Per-coupon usage limit (0 = unlimited) |
timesUsed | Int | Read-only usage count |
conditionType | Int | 1 match all conditions / 0 match any |
conditions | Array | Cart / product condition filters |
actionType | String | by_percent, by_fixed, cart_fixed, buy_x_get_y |
discountAmount | Float | Discount value (capped at 100 for by_percent) |
discountQuantity | Int | Quantity for buy_x_get_y |
discountStep | String | Buy-step for buy_x_get_y |
applyToShipping | Int | 1 applies the discount to shipping too |
freeShipping | Int | 1 grants free shipping |
endOtherRules | Int | 1 stops lower-priority rules from also applying |
usesAttributeConditions | Int | 1 when conditions use product attributes |
sortOrder | Int | Priority — lower runs first |
couponCode | String | The rule's primary coupon code, or null |
channels | Array | Channel ids the rule applies to |
customerGroups | Array | Customer-group ids the rule applies to |
createdAt | String | Creation timestamp |
updatedAt | String | Last-update timestamp |

