Update products line item from an order

I’m trying to work on an app, where I want to update or add the line-items of the products after the order has been submitted. I was trying to find the GraphQl API’s from the documentation but couldn’t find anything.
Reference Documentation link: orderEditAddShippingLine - GraphQL Admin

Have anyone worked on this type of API before? Please let me know if I can work on that.

Thanks.

1 Like

Hey @Mehedi_Hasan :waving_hand: - you’d likely want to use the two mutations below for this:

^This one lets you add an existing product variant as a new line item and the one below here would allow you to add a custom one (essentially a line item that doesn’t already exist as a product):

If you wanted to remove a line item completely, you can use the OrderEditSetQuantity mutation to set the line item quantity to 0 which will basically delete the line item:

Hope this helps, let me know if I can clarify anything on our end here :slight_smile:

Great ! Let me take a look.

1 Like