How do I apply line_item discount using REST Admin Order API

Shopify Partner
4 0 1


How can I apply discount on line_items when im create a new order using REST Admin Order API?

I've tried to set almost every possible keys available in the line_items. And my requirement must be an Order, not DraftOrder.

I've even tried to create first, then later update the line_items with discount but still no avail.

I'm open for GraphQL API solution as I'm using this package in my application >>

Hope someone has done similar thing. Thanks

Replies 2 (2)
Shopify Staff
Shopify Staff
402 65 92

Hey there @ikkifujiwara 

I've looked into this and presently this is not possible using the Orders API. In Storefront API, (checkoutDiscountCodeApplyV2 mutation would apply an existing discount to a checkout) - that's seemingly the closest we've got to what you're looking for.

It's mentioned that Discounts can't be applied to specific items within an Order in the Orders CSV docs strangely enough, I'll look at getting this same mention into the API docs.

I've noted that there are other partners who are looking for the same functionality and I've made this known to the product team today. If there's any future updates, they'll be communicated via the Shopify Community forums and via our Developer Changelog. Hope that explains things at least!

| Shopify |
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution!
Shopify Partner
4 0 1


thanks so much for your reply. i'm trying out your method and finger-crossed i can make it.