shayypy / guilded.py

Asynchronous Guilded API wrapper for Python
https://guildedpy.rtfd.io
Other
133 stars 25 forks source link

Implement rate limit buckets #38

Open shayypy opened 2 years ago

shayypy commented 2 years ago

Guilded's rate limits are pretty vague but it is possible to improve on the current system as a library. Notably, this issue suggests implementation of rate limit buckets in order to prevent extraneous requests from being made to the same bucket while the client is rate limited.

Partially related to this issue is the x-slowmode-cooldown header returned when the client fails to send a message to a channel with slowmode enabled. It contains the value in seconds of the slowmode setting for the channel. In this case, the bucket is the channelId.