Re: Orders API return removed order item

Solved

Orders API return removed order item

Ramsam
Shopify Partner
3 0 0

Shopify order have 3 times when i excute Get Orders API, i received 3 times.

Now in shopify store backend i removed one time (Edit> Remove Items)  from order,

Now i excute Orders API, i got removed Order item also.

How to avoid this?

And How to identity the removed items in order api response properties? 

 

Accepted Solution (1)

syf_
Shopify Staff
95 21 25

This is an accepted solution.

Hi @Ramsam,

I'd be able to shed some light on the behaviour you're seeing.

Even though the order via the API (REST, I'm assuming) shows all the items in the original order, you'd notice that when you take a closer look at the deleted order item, its fulfillable_quantity field has a value of 0. This essentially indicates that this item doesn't have to be fulfilled and is no longer part of the order. You should see the deleted item in the refunds object of the order response. See this manual about editing orders.

Hopefully this helps clarify the behaviour you're seeing.

Best,

Seth.

syf_ | Developer Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

View solution in original post

Replies 5 (5)

syf_
Shopify Staff
95 21 25

This is an accepted solution.

Hi @Ramsam,

I'd be able to shed some light on the behaviour you're seeing.

Even though the order via the API (REST, I'm assuming) shows all the items in the original order, you'd notice that when you take a closer look at the deleted order item, its fulfillable_quantity field has a value of 0. This essentially indicates that this item doesn't have to be fulfilled and is no longer part of the order. You should see the deleted item in the refunds object of the order response. See this manual about editing orders.

Hopefully this helps clarify the behaviour you're seeing.

Best,

Seth.

syf_ | Developer Support @ Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit Shopify.dev or the Shopify Web Design and Development Blog

Skaloot
Visitor
2 0 1

Oh my.. I've looked everywhere trying to find ANY parameter from the API saying that there are deleted items in this order. but, I never looked into the refunds object.. Thanks VERY much.. lesson learned..

2characterslong
Tourist
5 0 4

Super helpful, thanks!

KieraLin
Visitor
1 0 0

Hi,

 

I'm having the same issue. May I ask how did you solve it at the end? Since the item has been removed from the order, I can't refund it anymore, as no item is available. 

 

Kiera

arsinthu
Visitor
1 0 0

Hi ,

After fulfilling the order, if we check the API, both active and removed products show a fulfillable quantity of 0.