V
V
Viplayer2020-03-10 19:29:45
PHP
Viplayer, 2020-03-10 19:29:45

How to make sure that the VK bot does not spam when users are added to the conversation in bulk?

The bot has a greeting that it gives out when the user is invited to the conversation, if you add, for example, 50 participants at a time, it sends 50 SMS.

I want that when "a lot" of events about an invite came, he would simply be silent, and not spam, and if there were 2-3 people, then he would answer.

Tell me, how can I catch the number of requests per second, what can I do to regulate this process?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
Stockholm Syndrome, 2020-03-10
@StockholmSyndrome

if events arrive at the same time, they will be in an array

W
Wwwoper, 2020-03-10
@Wwwoper

Create a condition to check the number of invitees at a time

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question