简体   繁体   English

向所有机器人用户发送新消息

[英]Send new message for all bot users

I'm trying to understand telegram api (with node js) and now got this question. 我试图理解电报api(与节点js),现在得到了这个问题。 Is it really to create "form" and send custom message for all who using this bot? 是否真的为所有使用此bot的人创建“表单”并发送自定义消息? Ie without restarting bot send message :) 即不重新启动机器人发送消息:)

The only way is: 唯一的方法是:

You need to store all the users IDs somewhere. 您需要将所有用户ID存储在某个地方。 And after that you can sendMessage to all that IDs one by one. 然后,您可以将Message一对一地发送到所有ID。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 您如何向对机器人发送的消息做出反应的用户发送 DM? (不和谐.JS) - How do you send a DM to users that react to a bot sent message? (Discord.JS) Discord bot 没有获得所有用户 - Discord bot not getting all users 如何使用 npm 库 Telegraf 从数据库中的 id 列表一次向所有电报机器人用户发送消息 - How to send messages to all telegram bot users from a list of ids in a database at once using npm library Telegraf 私信直接发消息欢迎新用户加入服务器 - Send a direct message on private message to welcome new users who join the server 如何收集对 bot 消息的 8 个反应,然后 bot 发送另一条消息 - How to collect 8 reactions on bot's message and then bot send another message 当我的机器人在 discord 中的所有服务器中联机时,如何发送启动消息。 吗? - How to send a startup message when my bot gets online in all servers it is in discord. Js? 如何向我的机器人在 v14 discord.js 中的所有 discord 服务器发送消息? - How would I send a message to all discord servers my bot is in v14 discord.js? 对来自机器人的消息的反应=来自机器人的新消息 - Reaction to a message from the bot=new message from the bot Facebook向多个用户发送消息 - Facebook send message to multiple users 如何让我的机器人获取已经从频道中的用户发送的随机消息,并在触发自动响应时发送该随机消息 - How to get my bot to get random messages that are already sent from users in a channel and send that random message when an autoresponse is triggered
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM