ErythroGuild / irene

<Erythro>'s server admin bot.
Mozilla Public License 2.0
0 stars 0 forks source link

Add rate limiting to `BlizzardClient` #429

Open Ernest314 opened 1 year ago

Ernest314 commented 1 year ago

Not quite sure how to implement this.

The official docs state a limit of 36,000 requests/hr, and a burst limit of 100 requests/sec (long-term average of 10 requests/sec).

Ernest314 commented 1 year ago

Check with the API discord on how rate limiting is implemented (e.g. sliding window, buckets, tokens, etc.).

Ernest314 commented 1 year ago

.NET 7 comes with a ratelimiting library: https://learn.microsoft.com/en-us/dotnet/api/system.threading.ratelimiting?view=aspnetcore-7.0

Better docs: