@fillippone I sent you a merit, let me know if it got there right.
I still try to edit the delays after your feedback.
I have no other way unfortunately, the forum refuses me the call, maybe I make too many forum calls?
You are probably making too many requests in a short period of time.
I don't know how your bot works, so I can't help a lot, but mine has a scrapper checking the Recent Merits page every 5 seconds and scrapping every merit < 20 minutes old in there. I also scrape all new posts simultaneously, so it has all the information on the merited post (author being the most important). However, many posts can't be find in my DB since they can be older than the bot itself or something wrong may have happened (e.g connection issues), so if this is the case, the bot goes to the merited post and scrapes it, saving it in the database. If the author of the merited post is subbed to the bot, the bot saves the merit data to the database, otherwise, it just ignores it.
While all of this happens, another instance, which only controls the Telegram Bot logic, pulls all unnotified merits from the database (notified === false) and loops through them. If the author is subbed and has merit notifications turned on, the bot sends the notification and sets notified = true.
You need to set a delay between every request to the forum. I'm assuming what you do is check the user's profile for changes in the merit count, and if noticed an increase, goes to his merit page and scrappes the merit data. If that's the case, you need to set a delay between each time the bot checks an user profile and a delay before going to his merit page when noticed a change.
Ex:
- Checks user 1 profile; no merit change;
- Waits 5 seconds.
- Checks user 2 profile; noticed the merit changed;
- Waits 2 seconds
- Go to user 2 merit page; scrapes and sends notification.
- Waits 5 seconds.
- Checks user 3 profile; [...]
If that's not how you do it, you need to see where the bot is failing the requests, which error it's showing, and set a delay if the issue is the forum's rate-limit.