Answer the question
In order to leave comments, you need to log in
Why does it give an error Code №10 - Internal server error when mentioning everyone?
In general, there is such a code
vk.updates.hear(/-send/, async (ctx) => {
if(admin.indexOf(ctx.senderId) === -1) {
return;
}
const response = await vk.api.messages.getChat({
chat_id: 5
})
let users = [];
for(let i = 2; i < response.members_count; i++) {
users[i] = '@id' + response.users[i] + '( )';
}
let text = users.map(x => x).join(' ');
/*const response2 = await vk.api.messages.send({
message: text,
peer_id: ctx.peerId
})*/
ctx.reply(text)
});
Answer the question
In order to leave comments, you need to log in
It is possible that there are too many mentions in the message (maximum 50 per message)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question