Retry-After is ignored in flow action response

Hi,
We’ve implemented a custom Flow Action that sends data to be handled asynchronously on our side due to the potentially long-running nature of some operations. To manage this, we’ve introduced logic to support delayed responses as follows:

  1. We use the action_run_id as an idempotency key.
  2. We return an HTTP 202 Accepted status immediately upon receiving the request and handle the processing asynchronously.
  3. While processing is ongoing, any retry from Shopify Flow receives an HTTP 429 Too Many Requests response, along with the header Retry-After: 15 to indicate Flow should retry after 15 seconds.
  4. Once the processing is complete, we return either 200 OK or a 4xx error, depending on the outcome, to finalize the Flow Action and stop further retries.

According to the Shopify Flow Actions documentation, returning a Retry-After header with a 429 status should control the retry interval. However, based on our testing and logs, it seems that Flow ignores this header - retries occur with increasing intervals regardless of the Retry-After value we return.

We’ve confirmed that our responses do include the Retry-After: 15 header by testing with Postman.
When Shopify Flow retries, the logs show a 429 status, but the retry delay continues to grow.
With 429 HTTP status code and Retry-After: 15 header:

2025-07-22 09:03:43 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: b63199047e046bd08b41c3a545dfbc9086aa1354 
2025-07-22 09:03:43 [version 4c7b87465ba5df01952350026a13663f] [info]: Request processing starting b63199047e046bd08b41c3a545dfbc9086aa1354 
2025-07-22 09:03:43 [version 4c7b87465ba5df01952350026a13663f] [info]: 202 Accepted b63199047e046bd08b41c3a545dfbc9086aa1354 

.... long-running call started

2025-07-22 09:03:43 [version 4c7b87465ba5df01952350026a13663f] [info]: Set state (b63199047e046bd08b41c3a545dfbc9086aa1354): {"status":"RUNNING","createdAt":"2025-07-22T09:03:43.175Z"}
2025-07-22 09:03:48 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: b63199047e046bd08b41c3a545dfbc9086aa1354 
2025-07-22 09:03:48 [version 4c7b87465ba5df01952350026a13663f] [info]: 429 Still processing... b63199047e046bd08b41c3a545dfbc9086aa1354 
2025-07-22 09:04:22 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: b63199047e046bd08b41c3a545dfbc9086aa1354 
2025-07-22 09:04:22 [version 4c7b87465ba5df01952350026a13663f] [info]: 429 Still processing... b63199047e046bd08b41c3a545dfbc9086aa1354 

.... long-running call finished

2025-07-22 09:04:53 [version 4c7b87465ba5df01952350026a13663f] [info]: Set state (b63199047e046bd08b41c3a545dfbc9086aa1354): {"status":"FAIL","createdAt":"2025-07-22T09:03:43.175Z","result":"some result","statusCode":400,"updatedAt":"2025-07-22T09:04:53.982Z"} 
2025-07-22 09:04:57 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: b63199047e046bd08b41c3a545dfbc9086aa1354 
2025-07-22 09:04:57 [version 4c7b87465ba5df01952350026a13663f] [info]: 4xx Bad Request b63199047e046bd08b41c3a545dfbc9086aa1354

as we can see the intervals were:
202429 - 5 sec
429429 - 34 sec
4294xx - 35 sec

With 429 HTTP status code and without Retry-After header:

2025-07-22 12:59:18 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: ea328f3e68fe42ff71600bc4680490a07e5d23f5 
2025-07-22 12:59:18 [version 4c7b87465ba5df01952350026a13663f] [info]: Request processing starting ea328f3e68fe42ff71600bc4680490a07e5d23f5 
2025-07-22 12:59:18 [version 4c7b87465ba5df01952350026a13663f] [info]: 202 Accepted ea328f3e68fe42ff71600bc4680490a07e5d23f5 

.... long-running call started

2025-07-22 12:59:18 [version 4c7b87465ba5df01952350026a13663f] [info]: Set state (ea328f3e68fe42ff71600bc4680490a07e5d23f5): {"status":"RUNNING","createdAt":"2025-07-22T12:59:18.559Z"} 
2025-07-22 12:59:24 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: ea328f3e68fe42ff71600bc4680490a07e5d23f5 
2025-07-22 12:59:24 [version 4c7b87465ba5df01952350026a13663f] [info]: 429 Still processing... ea328f3e68fe42ff71600bc4680490a07e5d23f5 
2025-07-22 12:59:28 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: ea328f3e68fe42ff71600bc4680490a07e5d23f5 
2025-07-22 12:59:28 [version 4c7b87465ba5df01952350026a13663f] [info]: 429 Still processing... ea328f3e68fe42ff71600bc4680490a07e5d23f5 
2025-07-22 13:00:18 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: ea328f3e68fe42ff71600bc4680490a07e5d23f5 
2025-07-22 13:00:18 [version 4c7b87465ba5df01952350026a13663f] [info]: 429 Still processing... ea328f3e68fe42ff71600bc4680490a07e5d23f5 

.... long-running call finished

2025-07-22 13:00:29 [version 4c7b87465ba5df01952350026a13663f] [info]: Set state (ea328f3e68fe42ff71600bc4680490a07e5d23f5): {"status":"FAIL","createdAt":"2025-07-22T12:59:18.559Z","result":"some result","statusCode":400,"updatedAt":"2025-07-22T13:00:29.093Z"} 
2025-07-22 13:01:25 [version 4c7b87465ba5df01952350026a13663f] [info]: Action run ID: ea328f3e68fe42ff71600bc4680490a07e5d23f5 
2025-07-22 13:01:25 [version 4c7b87465ba5df01952350026a13663f] [info]: 4xx Bad Request ea328f3e68fe42ff71600bc4680490a07e5d23f5

the intervals were:
202429 - 6 sec
429429 - 4 sec
429429 - 50 sec
4294xx - 67 sec

Actual Result:
From the logs, we can see that the retry intervals are increasing over time, even though we are explicitly setting the Retry-After header to 15 seconds in each 429 Too Many Requests response.

Expected Behavior:
We expect Flow to respect the Retry-After header and follow a consistent retry interval as defined. The expected sequence should look like:
202429 - initial retry in 4–6 seconds - we can’t control this
429429 - 15 sec
429429 - 15 sec
429429 - 15 sec
429429 - 15 sec
4294xx - 15 sec, final response based on processing result

Could you please confirm whether Retry-After is currently supported by Flow and whether there are any constraints or known issues that could cause it to be ignored?

:waving_hand: It looks like our documentation is inaccurate and the retry-after header isn’t currently handled by Flow. We’ll update our documentation and we’ve tracking this issue internally.

Thanks @Maxime_Leduc , do you know when this Retry-After could be implemented by the dev team? At least can you confirm how we can expect the behavior to be for the time being?

do you know when this Retry-After could be implemented by the dev team?

Unfortunately we don’t have a timeline at the moment.

At least can you confirm how we can expect the behavior to be for the time being?

For now unfortunately the retry-after header won’t be handled by Flow. This means that adding it to your response won’t influence the wait time before a retry.

Right but since there is no Retry-After header at all how can we expect Shopify to behave with retrying requests in the interim until this is implemented?

Flow will resend the POST request at increasing intervals for up to 36 hours.

Do you know what those increasing intervals would officially be?
i.e 20 mins, then 30 mins, then 60 minutes, then 120 minutes, etc.?

Good news, we just shipped support for the Retry-After header.

1 Like

This is great news, thanks so much @Maxime_Leduc ! Looking forward to giving this a try.

Good afternoon @Maxime_Leduc - was the support for Retry-After header fully rolled out? We are testing around with it, but it is still not working as expected. In our example, we set the Retry-After to 15 (seconds). However, the requests appear to still be polling/retrying from Shopify at ~1-minute intervals. Looking forward to your input.

2025-10-28 16:42:34 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Trying to authenticate using ShopifyFlowAuth 
2025-10-28 16:42:34 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Verifying Flow Request for shop tmg-isukhorutchenko-dev 
2025-10-28 16:42:34 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Action run ID: 80a04df63a99033965d9e6286e88b64a8b2d43f6 
2025-10-28 16:42:34 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: 429 Still processing... 80a04df63a99033965d9e6286e88b64a8b2d43f6 

2025-10-28 16:43:40 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Trying to authenticate using ShopifyFlowAuth 
2025-10-28 16:43:40 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Verifying Flow Request for shop tmg-isukhorutchenko-dev 
2025-10-28 16:43:40 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Action run ID: 80a04df63a99033965d9e6286e88b64a8b2d43f6 
2025-10-28 16:43:40 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: 429 Still processing... 80a04df63a99033965d9e6286e88b64a8b2d43f6 

2025-10-28 16:44:33 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Trying to authenticate using ShopifyFlowAuth 
2025-10-28 16:44:33 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Verifying Flow Request for shop tmg-isukhorutchenko-dev 
2025-10-28 16:44:33 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Action run ID: 80a04df63a99033965d9e6286e88b64a8b2d43f6 
2025-10-28 16:44:33 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: 429 Still processing... 80a04df63a99033965d9e6286e88b64a8b2d43f6 

2025-10-28 16:45:04 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Trying to authenticate using ShopifyFlowAuth 
2025-10-28 16:45:04 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Verifying Flow Request for shop tmg-isukhorutchenko-dev 
2025-10-28 16:45:04 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Action run ID: 80a04df63a99033965d9e6286e88b64a8b2d43f6 
2025-10-28 16:45:04 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: 429 Still processing... 80a04df63a99033965d9e6286e88b64a8b2d43f6 

2025-10-28 16:45:48 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Trying to authenticate using ShopifyFlowAuth 
2025-10-28 16:45:48 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Verifying Flow Request for shop tmg-isukhorutchenko-dev 
2025-10-28 16:45:48 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Action run ID: 80a04df63a99033965d9e6286e88b64a8b2d43f6 
2025-10-28 16:45:48 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: 429 Still processing... 80a04df63a99033965d9e6286e88b64a8b2d43f6 

2025-10-28 16:46:44 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Trying to authenticate using ShopifyFlowAuth 
2025-10-28 16:46:44 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Verifying Flow Request for shop tmg-isukhorutchenko-dev 
2025-10-28 16:46:44 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Action run ID: 80a04df63a99033965d9e6286e88b64a8b2d43f6 
2025-10-28 16:46:44 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: 429 Still processing... 80a04df63a99033965d9e6286e88b64a8b2d43f6 

2025-10-28 16:48:34 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Trying to authenticate using ShopifyFlowAuth 
2025-10-28 16:48:34 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Verifying Flow Request for shop tmg-isukhorutchenko-dev 
2025-10-28 16:48:34 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: Action run ID: 80a04df63a99033965d9e6286e88b64a8b2d43f6 
2025-10-28 16:48:34 [version 1d86027e1cf7d5e6aab564505f1f81f3] [info]: 400 Request timeout 80a04df63a99033965d9e6286e88b64a8b2d43f6

Good morning @Maxime_Leduc , would you have an update on this issue? Thanks!

Hi Aaron,

Sorry for the delay, we finally updated our docs. The answer to your question is:

The value of the Retry-After header is treated as a minimum wait time and only supports wait times between 5 and 3600 seconds (1 hour). The automation tool will add a jitter to the Retry-After value and wait at increasing intervals if it receives multiple 429 responses.

Thanks @Maxime_Leduc ! That link goes to a 404. We’ll give it a try in the meantime