Skip to content

List Returnable Items ​

List the items of one of the customer's orders that are still eligible for return — within their return window and not already fully returned or canceled. Each row carries the trusted quantity caps the store enforces when a return is raised (forReturnQuantity, forCancelQuantity, currentQuantity), so a client can present the correct maximum. Use these rows to pick the orderItemId and quantity for POST /api/shop/returns.

Endpoint ​

GET /api/shop/returnable-items

Authentication ​

This endpoint requires an authenticated customer — send the storefront key and a customer Bearer token. See the Authentication page.

Request Headers ​

HeaderRequiredDescription
Content-TypeYesapplication/json
X-STOREFRONT-KEYYesYour storefront API key
AuthorizationYesBearer token (customer login required)

Query Parameters ​

ParameterTypeRequiredDescription
order_idintegerYesId of the order to list returnable items for. Must belong to the authenticated customer.

Response Fields (200 OK) ​

The response is a plain JSON array. Each item is a returnable-item object.

FieldTypeDescription
orderItemIdintegerId of the order item (order line) — send this as order_item_id when raising a return.
productIdintegerId of the product.
skustringProduct SKU.
namestringProduct name.
typestringProduct type, e.g. simple.
urlKeystringProduct URL key.
pricenumberItem price.
baseImageUrlstringURL of the product's base image.
qtyOrderedintegerQuantity originally ordered.
currentQuantityintegerQuantity currently eligible to act on.
forReturnQuantityintegerMaximum units that can be returned.
forCancelQuantityintegerMaximum units that can be canceled.
rmaQuantityintegerUnits already placed into a return.
rmaReturnPeriodintegerReturn window in days.

WARNING

orderItemId is the id of the order line, not of the product. Sending a productId as order_item_id when raising a return fails with The selected item is not eligible for return.

Units held by a canceled or declined return are released back into currentQuantity, so a shopper who withdrew a request can raise a new one for the same item.

Status Codes ​

StatusMeaning
200 OKReturnable items retrieved.
401 UnauthorizedMissing or invalid storefront key.
403 ForbiddenMissing or invalid customer Bearer token.
404 Not FoundThe order does not exist or is not the customer's.

Released under the MIT License.