Versioned API schema

Shopify GraphQL Returns API exchangeLineItems lineItems first processed line item

A return/exchange integration drops additional line items after repeated processing.

Shopify Returns GraphQLCommerce SaaS APIVersioned API schemashopify_returns

Agent Quick Fix

Repair against the current Shopify Returns GraphQL contract, then keep the change narrow and source-backed.

Product: Shopify Returns GraphQL
Current-contract area: ExchangeLineItem.lineItem returns only first processed line
Likely root cause: A return/exchange integration drops additional line items after repeated processing.
Repair direction: Verifier exercises the changed field/status/enum plus an unaffected endpoint to prevent a brittle one-off patch. Verify all associated line items and ordering/aggregation behavior.

Symptom

A return/exchange integration drops additional line items after repeated processing.

Why This Happens

Several historical response shapes are locally plausible; only the selected current API version determines fields, enums, media types, and status codes.

Common Wrong Fixes

  • Changing local code without checking the current external contract.
  • Retrying the same install, build, or API call with no version/source change.
  • Applying a broad unsafe bypass when a narrow compatibility fix is available.

Codex Search Keywords

These are the search terms observed in a neutral Codex validation run for this failure shape.

Shopify GraphQL Returns API exchangeLineItems lineItems first processed line item
site:shopify.dev/docs/api/admin-graphql return exchangeLineItems lineItems
Shopify Admin GraphQL API Return object returnLineItems exchangeLineItems
https://shopify.dev/docs/api/admin-graphql/latest/objects/Return
'returnProcess' in https://shopify.dev/docs/api/admin-graphql/latest/objects/Return
https://shopify.dev/docs/api/admin-graphql/latest/input-objects/ReturnProcessingStatusFilterInput

Source Trail