Create Return with Exchange GraphQl Api

Topic summary

Creating returns with exchanges in Shopify’s Admin GraphQL API.

  • Current capability: In the unstable API version, returns with exchanges can be created by adding exchangeLineItems to ReturnInput and using the returnCreate mutation.

  • Scope limits: This input is available only for returnCreate (not returnRequest). It’s exclusive to the unstable version.

  • Stability caveats: “Unstable” features are experimental, may change or be removed, and aren’t recommended for production use. Test-only until a stable release is announced.

  • Open questions: How to identify which order items are being replaced when fetching orders via Admin APIs remains unanswered. One participant notes that Shopify Admin UI supports adding exchanges to a Return Request, but the corresponding public API endpoint appears missing or internal-only.

  • Evidence: Screenshots and a demo video (YouTube link) illustrate the Admin UI flow for adding exchanges; these media are central to the concern about missing public endpoints.

  • Status: Partial path exists via unstable/returnCreate. No confirmed stable timeline or parity with Admin UI flows. Thread remains open with unresolved retrieval and endpoint-parity questions.

Summarized with AI on December 24. AI used: gpt-5.

Hi Everyone,

We are working with the Return APIs of Shopify and got confused about the below. Will anyone help me with this?

  • This is about creating a return with the exchange. I have seen the Return Object in the release candidate and unstable version of the APIs there we can see the object exchangeLineItems but while creating the return (returnRequest API and returnCreate API) none of the APIs take exchangeLineItems as input. However, I checked the flow in the UI exchange option is available in the Seller Panel. If the exchangeLineItem is not part of creating return APIs, how can we create a return with exchange? What is the right flow for the same?

Regards

Deepak Samria

1 Like

Hi Deepak,
I also want to implement the exchange like functionality,

How did you implement it?

Hi,

I’m still looking for a solution, but I haven’t gotten anything as of now.

Hi @deepaksamria and @learnerSquad ,

Good news! Creating returns with exchanges is now available in the unstable version of the Admin API by including the exchangeLineItems in the ReturnInput.

Please note however that this is currently only available for the ReturnInput specifically, so would only be usable with the returnCreate mutation at this time.

Additionally, it’s important to understand that the unstable api version includes features and modifications that are still under development. Their behaviour is not guaranteed or supported as we may frequently alter them while we continue to work on new features.

Typically, new features are seen in the unstable version prior to a stable release. However, there’s no assurance that changes in the unstable version will ultimately be released. A feature could be added to the unstable version, only to be removed later. As a result, we suggest using the unstable version for testing before new features are launched. However, we advise against using it for live apps and stores in a production environment.

I hope this helps, and I hope you have a great day :slightly_smiling_face:

When fetching the order by admin APIs how so you which items are being replaced?

Hi @ShopifyDevSup and @deepaksamria , this is not really a solution on the issue :disappointed_face: It seems that there is the capability to add exchanges to a Return-Request that is made by the shopify-admin-ui:

For demonstration we recorded this demo here → https://youtu.be/peTHzR-GQXo?si=zOskTVz29qsL_WA9&t=212

It seems this endpoint is missing or only available internally within shopify: