post
https://api.talkdeskapp.com/erc/ecommerce/return/process-refund
Process a return and create a refund for the associated order. This endpoint finalizes the return flow by issuing a refund tied to an existing return.
Required fields:
- order_id
- return_id
A successful request that refunds money returns 201 with the created refund details for the specified order. A return processed with
exchange items where nothing is refunded returns 200 with process_return_response instead.
Returns with exchange items:
- Send the exchange items in exchange_line_items, together with the return line items in refund_line_items, to process them in one request. Their
prices are netted, and what happens to the money is Shopify's suggested outcome for the whole order, the same as financial_outcome of the
suggested refund: the items are first netted against what the order already owes. - When money is refunded (REFUND), the response is 201 with the refund, return_id, return_status, financial_outcome and the processed
exchange_line_items. - When the customer owes money (INVOICE) or nothing is owed either way (EVEN), nothing is refunded and the response is 200 with
process_return_response. For an INVOICE with notify set to true, Shopify's invoice for the order is emailed to the customer. - Shopify closes the return by itself a moment after everything in it is processed, so return_status can still read OPEN.
- Without exchange_line_items, the return line items are refunded as before. A return that still has exchange items stays open, and they are
listed in pending_exchange_line_items. Processing them in a later request does not net them with the refunded items: the exchange items are then
charged in full. - Requests for Shopify are rejected with 400 when the return is not open, when a quantity is more than is left to process, or when transactions
are sent and no refund is due. Custom integrations receive the request as is.
Recent Requests
Log in to see full request history
| Time | Status | User Agent | |
|---|---|---|---|
Retrieving recent requests… | |||
Loading…