Automatic Discounts Behavior Mismatch Between Shopify Admin (Or GQL API) and Storefront Checkout

The fundamental problem that I’m experiencing is that the draft order visible in the API or Shopify’s admin side does not match the draft order that the customer sees when they open it as an invoice.

You can replicate this problem yourself:

  1. Set up an automatic discount applying to a specific product.
  2. On Shopify’s Admin side, configure a draft order like:
    1. The purchasing entity is a company location.
    2. Contains your line item that is the target of the automatic discount.
    3. “Apply Automatic Discounts” is enabled.
  3. You should see that the automatic discount does not apply on Shopify’s admin side.
  4. Copy the draft’s invoice link and open it as if you were the customer.
  5. You should see that the automatic discount does apply in this view.

Here’s a video from my store: https://drive.google.com/file/d/19vYivjFo2XOzGXju3aaKTsL7NHU_ndzr/view?usp=drive_link

AI Disclosure - I did not use AI to write this post.

This lines up with how discount Functions interact with B2B draft orders, they get evaluated at actual checkout rather than fully baked into the draft preview, so the admin screen and the invoice link can disagree. I wouldn’t treat the draft order total as final for an automatic discount tied to a company location.