# Discounts in partial rollouts: no way for extensions or Functions to know what the current buyer gets

**URL:** <https://community.shopify.dev/t/discounts-in-partial-rollouts-no-way-for-extensions-or-functions-to-know-what-the-current-buyer-gets/38318>\
**Category:** Functions\
**Tags:** discount-functions\
**Created:** [October 5, 2026, 8:44pm UTC](https://community.shopify.dev/t/discounts-in-partial-rollouts-no-way-for-extensions-or-functions-to-know-what-the-current-buyer-gets/38318 "2026-10-05T20:44:08Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![yannlombard](https://sea1.discourse-cdn.com/shopifycommunity/user_avatar/community.shopify.dev/yannlombard/32/10139_2.png) [@yannlombard](https://community.shopify.dev/u/yannlombard)\
**Post date:** [October 5, 2026, 8:44pm UTC](https://community.shopify.dev/t/discounts-in-partial-rollouts-no-way-for-extensions-or-functions-to-know-what-the-current-buyer-gets/38318/1 "2026-10-05T20:44:08Z")

</div>

Hi,

We build a cart progress bar app (“spend $X, get 10% off / a free gift”). Each tier is its own automatic app discount backed by the same discount Function. A theme app extension and a checkout UI extension tell buyers which tiers they’ve unlocked. On the backend we already read `rollouts` (Admin API 2026-10, `read_rollouts`) and follow the “Upgrade your app for discount rollouts” guide.

**What we observed on a dev store** (tier A = 5% at $500, no rollout; tier B = 10% at $1,000, expired for 50% of traffic):

- For buyers in the expiring arm, tier B’s Function is never invoked. That’s expected.
- A discount activated by a rollout runs even though its own dates are in the past. Also expected.
- Our Function only lets the highest reached tier emit, so tiers never stack. Tier A’s Function can’t tell that tier B is off for this buyer, so it stays silent. **On a $1,480 cart the buyer gets no discount at all** , although tier A isn’t in any rollout.
- The assignment survived a new `cart` cookie and a new `_shopify_y`. We couldn’t find where it lives, and nothing in Liquid, `/cart.js`, the Storefront API or the checkout Discounts API exposes it.
- In the admin, a rollout can be limited to specific markets and sales channels, but `Rollout` (2026-10, 2027-01 and unstable) exposes neither. With the guide’s “safe to promote” rule, a rollout that expires a discount for 100% of traffic in a single market looks to us like it expires it everywhere, so we’d hide the offer in every market.

**What would solve it for us** , from most to least useful:

1. **Function input: tell us which of our app’s discounts are active for this cart.** For example, a `discounts { id }` list in the input (or `isActiveForBuyer` on sibling discounts). The Function could then pick the highest tier that’s actually served, instead of silencing everything.
2. **Expose the rollout’s market and sales channel targeting** on `Rollout` (for example `markets { id }` and `channels`), and let the `rollouts` query filter on them. It’s a small addition, and without it the guide’s safe-to-promote check gives the wrong answer for any rollout limited to a market or channel.
3. **A stable discount ID on applied discounts** : `discount_application.discount_id` in Liquid and `/cart.js`, and the discount node ID on Storefront API and checkout discount allocations. Today, our only link between an applied discount and our tier is its title, which merchants edit and translate.
4. **Let extensions know which of our discounts the current buyer is served** , before the cart qualifies: the IDs of the app’s discounts active for this buyer, in Liquid, `/cart.js`, the Storefront API and the checkout API. Treatment IDs would also work, but they force every app to replicate how treatments map to discounts.
5. **A rollout change type for app-owned metafields** (or app data), so a treatment can swap our config the way it swaps a theme. Our extensions would then read the treatment’s values natively.

Is any of this planned? If a feature request already exists, we’d be glad to add our use case to it.

Thanks!

---

<div class="post-metadata">

**Author:** ![lodel](https://sea1.discourse-cdn.com/shopifycommunity/user_avatar/community.shopify.dev/lodel/32/19487_2.png) [@lodel](https://community.shopify.dev/u/lodel)\
**Post date:** [October 7, 2026, 2:09pm UTC](https://community.shopify.dev/t/discounts-in-partial-rollouts-no-way-for-extensions-or-functions-to-know-what-the-current-buyer-gets/38318/3 "2026-10-07T14:09:56Z")

</div>

Hi Yann, thanks for the detailed examples and API suggestions.

How are A and B’s combination settings configured today? Could A continue returning 5% whenever its own conditions are met, while B returns 10% when it runs and qualifies, with the two configured not to combine?

If both tiers are order discounts, you can configure this by setting [`combinesWith.orderDiscounts`](https://shopify.dev/docs/api/admin-graphql/2026-10/input-objects/DiscountCombinesWithInput) to `false` on A and B through [`discountAutomaticAppUpdate`](https://shopify.dev/docs/api/admin-graphql/2026-10/mutations/discountAutomaticAppUpdate). If both are product discounts, use `combinesWith.productDiscounts` instead. When updating, explicitly retain the other combination settings you want to keep.

At $1,480, assuming both discounts apply to the same subtotal and no other discounts are competing, Shopify would select B’s 10% when both qualify. If the rollout excludes B, A’s 5% would remain available. This follows the **“Best discount selection”** behavior described in our [discount combinations guide](https://help.shopify.com/en/manual/discounts/discount-combinations).

These settings apply to the whole discount class, not just the other tier. For example, disabling order-discount combinations also prevents those tiers from stacking with other merchant order discounts. Does your app need to preserve those combinations, or need the highest configured tier to win regardless of monetary saving? Those requirements could affect whether this approach fits.

That first approach could address the missing fallback (for example, applying A’s 5% when the rollout excludes B).

You could also have one automatic app discount control the full tier ladder, with its function selecting the applicable tier. All tiers would then share that discount’s rollout availability, removing the need to coordinate tiers served under different discount treatments. Tier-specific labels can still be returned through candidate messages, such as `orderDiscountsAdd.candidates[].message` for order discounts. The Discount Function documentation includes a [tiered-subtotal example](https://shopify.dev/docs/api/functions/latest/discount?example=apply-tiered-discounts-based-on-order-subtotal).

The trade-off is rollout granularity: activating or expiring that discount would affect the whole ladder, rather than B independently of A.

---

<div class="post-metadata">

**Author:** ![Quan\_TM](https://avatars.discourse-cdn.com/v4/letter/q/65b543/32.png) [@Quan\_TM](https://community.shopify.dev/u/Quan_TM)\
**Post date:** [October 13, 2026, 8:02am UTC](https://community.shopify.dev/t/discounts-in-partial-rollouts-no-way-for-extensions-or-functions-to-know-what-the-current-buyer-gets/38318/4 "2026-10-13T08:02:31Z")

</div>

Similar issue.  
In many case with discount apps, we have discounts go with some kind of promotion on the storefront.

So with number **4.**  **Let extensions know which of our discounts the current buyer is served,** as the original topic requested, would be really useful.
