Upgrade from Eikon -> Workspace. Learn about programming differences.

For a deeper look into our Eikon Data API, look into:

Overview |  Quickstart |  Documentation |  Downloads |  Tutorials |  Articles

question

Upvotes
1 0 0 1

I am being throttled by the usage limits for the Eikon Data API when I have played fairly

I am using the Eikon API with Python on Windows (with a desktop session). I am instantiating a historic_pricing.Definition class and calling .get_data() to retrieve a time series of hourly prices per RIC.


query_definition = historical_pricing.summaries.Definition(
        universe=refined_rics,
        interval=interval,
        fields=[pricing_field],
        start=query_start.strftime("%Y-%m-%d %H:%M:%S"),
        end=query_end.strftime("%Y-%m-%d %H:%M:%S"),
        sessions=[
            historical_pricing.MarketSession.NORMAL,
        ],
    )

1714147581891.png

As you can see in the log, I have batched the requests to be a max of 50 RICs and the date filter restricts the amount of historical price points returned. Typically I am receiving around 5000 data points back per request, which doesn't seem like a problem when I look at the usage limits. Additionally, I am making synchronous calls so I am not going to breach 5 requests per second. Lastly, the daily limit of 5Gb and minute limit of 50Mb are much larger than the data I am requesting per day.


Therefore I cannot understand why I am getting this error:

Error code 429 | Client Error: Too Many Requests - Too many requests, please try again later.
refinitiv-dataplatform-eikon#producthistoricalapi-limitsprice-historythrottlingusage
1714147581891.png (42.3 KiB)
icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Hello @Matt.Whiteley

Thank you for your participation in the forum. Is the reply below satisfactory in resolving your query?


If so please can you click the 'Accept' text next to the appropriate reply? This will guide all community members who have a similar question.

Thanks,


AHS

1 Answer

· Write an Answer
Upvote
5.4k 18 2 7

Hi @Matt.Whiteley ,


There is another limit of 10,000 request per day, I think you are reaching that one (Documentation | Devportal (lseg.com)):

screenshot-2024-04-26-at-172654.png


Best regards,

Haykaz


icon clock
10 |1500

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Hi @Matt.Whiteley ,


As you perhaps rightfully noticed the get_data request with several RICs is not a single call. You can refer also to this thread, which provides more light on it.

Try Except would be another thing obviously which will result in additional API calls.

Best regards,

Haykazs

Hi @aramyan.h - thanks, I read through the thread and that makes a lot more sense, I didn't know the RICs were being iterated over and thus it was one API call per RIC. Is this also how it worked in the 'eikon' library? I see that price streaming is another option but that doesn't seem to let me access historic data, which is critical for my application.

Hi @Matt.Whiteley ,


That should be the same for Eikon as well. I realize your usecase might be different I just provided that thread as an explanation of the situation, but perhaps, you can build the history in a couple of days and then use the streaming, if an option for your use case at all. You may also want to talk to your Account Manager who may suggest another product or workflows.


Best regards,

Haykaz

For reference, this thread suggests the original eikon library didn't make a request per RIC. I have also checked the source code for the eikon implementation and it appears to send one payload per function call. This will solve my problem but I will verify that with some tests today and confirm here, if that is useful.
Show more comments
Hi Aramyan,


It shouldn't (in theory!) be anywhere close to 10,000 requests. Of course, I am counting one method call of 'get_data()' as one request, which may not be strictly true. One thing to note is that my internet was very intermittent that day, and perhaps the poor connection was triggering a lot of retry requests, which is why I was then throttled. That's my best guess, as I don't know how it works under the hood.


Thanks

Matt

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.