In the middle of building rate limiting for my bot before distributing it. Just a query regarding the rates as this is the one thing I’m not clear on. I’m aware of the 20 messages per 30 seconds for non-mods, 100 for mods and the rate is shared so you send 50 on mod then 1 on non-mod you get 8-hour’d. I’m also aware this restriction is on a per-connection basis.
Okay, so this period of time. How is it measured? Assuming modded, If I send 100 messages in 1 second, then 30 seconds later I can send 100 again? Assuming not modded, 20 in 1 second, 30 seconds later, 20 more?
This is how I’m currently imagining it, so I am designing the rate limiter to store the last 100 messages and query it about when (if modded) the 100 previous message was.
Will this cause me any problems?
Another question I had for the rates is if there’s a grace period between mod to non-mod on the rate limits. Say my bot doesn’t receive the UNMOD message straight away as they are cached and sent in bulk, I won’t know until maybe 10 seconds afterwards that I’m no longer actually a mod. Perhaps I can do this using the tags though and/or kraken API.
Finally, very rare case scenario. Can I have 2 connections from the same IP in the same channel and be modded and send 100 messages from 1, then 100 messages from the other?