I'm running into an issue with the Admin REST API. What I'm trying to do is bulk update the email addresses attached to all of the orders linked to a group of customers. First, I'm listing the orders for a specific customer. Then, I iterate over the list of orders and make a request to update the email address of each one.
The problem I'm having is that I'm receiving the following error:
429 Client Error: Too Many Requests for url: https://<redacted>@<redacted>.myshopify.com/admin/orders/<redacted>.json
I understand that there is a rate limit of 2 requests per second. I've tried delaying between each request - even for up to 10 seconds(!) but I'm still receiving the error. Is there something I'm doing wrong that's leading to me getting this error? And is there a better way to bulk update all of the orders associated with a customer?
It looks like the URL being used doesn't include the API version. This isn't necessarily related to the 429 errors, but it's worth trying your calls again with a version number to rule it out as the cause.
If you're still experiencing the error, kindly provide the X-Request-ID value from the response headers of a failed call, and we'll use this to investigate further.