title: How to send messages to all telegram bot users from a list of ids in a database at once using npm library Telegraf
body: <p>i have selected all ids of my telegram bot users from mysql database and want to send messages to them at once.I have tried</p>
  
  <pre><code>con.query("SELECT id FROM account",function (err,res) {
             res.forEach(function (message) {
                 ctx.telegram.sendMessage(message.id, ctx.message.text)
     })
  })
  </code></pre>
  
  <p>but it sends each message to a user at a time.i want to send the message to all users at once using an array of all ids as in telegram api</p>