Can we get the "Rate Limits" headers as part of the JSON output?

It seems as if the “Rate Limits” headers are only sent back as HTTP headers. At least that’s what I assume is the case, based on the somewhat fuzzy https://dev.twitch.tv/docs/api/guide/#rate-limits page and the fact that they are lacking from the JSON blob.

For complicated reasons, it’s impossible/extremely impractical for me to parse HTTP response headers. For this reason, I hereby wish for these headers to also be baked into the JSON blob.

(I frankly don’t understand why they are part of the HTTP response headers to begin with…)

Because it’s industry standard.

Rate limits are usually put in the header so that if you perform an API request for Item A today, then Item A tomorrow you can diff them without having to modify the output to remove the rate limit information from the data.

Rate limits are not the data you requested hence they are in the header and not in the data.

1 Like

I see. Well, it would be useful to be able to grab this information with some special API request.

Some special API request involves making an API request which changes the amount of API requests you have remaining.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.