POS UI Extensions Now Return Accurate Percentage Values for Discounts

Shopify POS 11.15 updates the Discount.amount field for percentage discounts, aligning it with the Cart API contract. Developers must adjust their POS UI extensions to treat the amount as a percentage, not a monetary value.

POS UI Extensions Now Return Accurate Percentage Values for Discounts
6 sections

If you build or maintain Shopify POS UI extensions, the latest POS 11.15 release brings a critical change that can affect how discounts are displayed and calculated across your apps. This post breaks down the update, explains who needs to act, and provides clear steps to keep your extensions running smoothly.

What Changed

Prior to POS 11.15, a 25% discount on a $200 line item returned a Discount.amount of 50 – the monetary value of the discount. Starting with POS 11.15, Discount.amount now returns the literal percentage (25), matching the Cart API contract. The change applies to all percentage‑type discounts at the cart level and per line item, including manual, app‑applied, and automatic discounts that use type "Percentage". FixedAmount and Code discounts remain unchanged.

Who Is Affected

The update impacts every POS UI extension, regardless of the API version you target. Keeping an older api_version does not preserve the previous behavior, so extensions running on POS 11.14 or earlier will still see the old monetary amount, while those on 11.15+ will receive the percentage. Both developers and merchants who rely on extensions for loyalty points, savings calculations, or custom pricing logic will notice the difference.

Why It Matters

Treating the amount as a percentage eliminates a long‑standing mismatch between the POS UI and the Cart API. Without the fix, extensions that displayed the discount as money could double‑count savings or miscalculate loyalty rewards. Aligning the data model also prevents errors when extensions push cart state back via bulkCartUpdate, where a monetary value could be mistakenly interpreted as a percentage.

Action Steps for Developers

  • Guard against type assumptions. Before you treat Discount.amount as a currency, check Discount.type. If it equals "Percentage", treat the amount as a number representing the percent. Example:
  • js

    // Sample POS UI extension discount handling

    function formatDiscount(discount) {

    if (discount.type === 'Percentage') {

    // amount is now a percent, not a money value

    return ${discount.amount}% off;

    }

    // For FixedAmount or Code discounts, amount is a Money object

    return $${(discount.amount / 100).toFixed(2)} off;

    }

  • Update any UI that shows the discount as a price. Replace the monetary display with a percentage label or recalculate the monetary value on the client side using the line item price.
  • Review loyalty‑point or rewards calculations that rely on the discount amount. Use the percentage to compute the correct monetary savings before converting to points.
  • If your extension still supports POS 11.14 or earlier, add a fallback branch that detects the older behavior. You can inspect the POS version via the extension’s context and apply the appropriate logic until devices are upgraded.
  • Testing Your Extension

  • Install the extension on a device running POS 11.15 or later.
  • Create a cart‑level 25% discount and verify that Discount.amount is 25.
  • Add a line‑item discount of 10% and confirm the same behavior.
  • Run a bulkCartUpdate that sends the cart state back to the POS and ensure the discount is not re‑interpreted as a monetary amount.
  • Finally, test on a POS 11.14 device (if possible) to confirm your fallback logic works as expected.
  • Conclusion & Next Steps

    Shopify’s POS 11.15 fix brings the Discount.amount field in line with the Cart API, but it also means extensions that previously treated percentage discounts as money must be updated. By adding a simple type check and adjusting your UI and calculations, you can avoid display errors and keep loyalty programs accurate. Stay on top of future POS releases, and consider adding automated tests that validate discount handling across POS versions.

    Ready to update your extension? Dive into the Shopify developer docs, run the tests above, and publish the new version today. If you have questions, drop a comment or reach out to the Shopify developer community for support.

    Tags
    Sources

    Related Articles

    Flow Gains Real-Time “Updated” Triggers for Orders, Customers, and More

    Flow Gains Real-Time “Updated” Triggers for Orders, Customers, and More

    Shopify Flow now offers eight new “updated” triggers—covering customers, orders, refunds, fulfillments, returns, collections, locations, and inventory items. Learn what changed, who it impacts, and how to implement the new triggers to automate real‑time responses in your store.

    November 20, 20265 min
    Email and Text Receipts Now Mirror Your POS Printed Receipt

    Email and Text Receipts Now Mirror Your POS Printed Receipt

    Shopify POS receipts sent by email or SMS now use the same template as printed receipts, eliminating duplicate templates and simplifying compliance. Learn what changed, who it impacts, and how to update your settings and code.

    November 20, 20264 min
    Server Pixel Mutations Now Enforce App Access: What Developers Need to Know

    Server Pixel Mutations Now Enforce App Access: What Developers Need to Know

    Starting November 20 2026 Shopify’s eventBridgeServerPixelUpdate and pubSubServerPixelUpdate mutations require a user with app access. Learn what changed, who’s impacted, and how to adjust your code to avoid access‑denied errors.

    November 20, 20264 min
    Embedding YouTube & Vimeo Directly via File Reference Metafields in Shopify API 2027-01

    Embedding YouTube & Vimeo Directly via File Reference Metafields in Shopify API 2027-01

    Shopify’s 2027-01 API now lets file reference metafields store YouTube and Vimeo video URLs, unlocking seamless video embeds for merchants and developers. Learn what changed, who it affects, and how to implement the new feature today.

    November 20, 20265 min