API keys are created under Settings → Integrations → Custom Integrations. A key applies to one shop.
With an API key, your own system reads and acts on returns and claims through the Returnflows API. It is used by helpdesk tools, finance systems and integrations you build yourself.
Add an API key
Select Custom Integrations at the top of the Integrations page.
Select Add API Key.
Enter a Name that describes what the key is for, and select Create.
Copy the key. It is shown once.
Select Delete to remove a key.
Use the API
The API is at https://api.returnflows.com. Send the key as a Bearer token in the Authorization header of every request.
Select Go to API docs on the Custom Integrations page to open the documentation, with every endpoint and its format. It is at api.returnflows.com/docs.
Area | What you can do | Path |
Returns | List and search returns, and read one return with its lines and its history. Edit, close or cancel a return, and release the exchange on a return |
|
Return options | Extend the return window, give a free return label or block returns on one order |
|
Claims | List and read claims, and review, close or cancel a claim |
|
Read, create, change and delete your return reasons |
| |
Claim settings | Read your claim questions, and read and change your Statistical Reasons and your Resolutions |
|
Read, create and change your markets and their settings |
| |
Addresses | Read, create and change your return, claims and company addresses |
|
Every answer has the fields success, message, responseObject and statusCode. The data is in responseObject.
A return is read with its own id or with the Shopify order id. The list of returns takes filters for the status, a date range and a search text.
The return window extension takes the numeric Shopify order ID and a number of days for the refund, the exchange and the gift card window. Each is between 0 and 36,500. It is the same extension as Return Options on the order. Learn more in Return Options.
To be notified when something happens, add a webhook and fetch the details from the API afterwards. Learn more in Webhooks.
Limits
The API allows 10 requests per second from one IP address. Above that it answers 429.
After 5 failed authentications in 15 minutes, further attempts are limited.
Every answer carries the headers
RateLimit-Limit,RateLimit-RemainingandRateLimit-Reset.A request without a key or with a wrong key answers 401.
Send your own User-Agent header. A request with the default one from a script library is refused with 403 and the error code 1010.
What the API doesn't cover
A return or a claim can't be created through the API.
A webhook can't be added or changed through the API. It is set up in Returnflows.
Shipping options, carriers, integrations, analytics, product rules and translations aren't in the API.
Good to know
If you have more than one shop, then create a key in each.
For an AI assistant such as Claude, use an MCP key. Learn more in MCP Integrations.
Gorgias reads your returns and claims with an API key. Learn more in Gorgias.

