telegram-send-message

0.0.4 • Public • Published

Create a bot on Telegram

Open Telegram app, search for @BotFather and start the chat. Send /newbot command and follow the instructions. After completing the initial steps, you’ll get the bot token.

How to get your chat ID?

  1. Search on Telegram for @get_id_bot
  2. Enter: /my_id
  3. You'll see your chat id in a few seconds.

How to use it?

You must first import the package

import Telegram from 'telegram-send-message';

And then you can do this to send the message:

Telegram.setToken(YOUR TELEGRAM BOT TOKEN);
Telegram.setRecipient(RECIPIENT CHAT ID);
Telegram.setMessage('Bla bla bla i'm a nerd.');
Telegram.send();

Questions?

Visit my website: http://pimvdmolen.nl

Package Sidebar

Install

npm i telegram-send-message

Weekly Downloads

3

Version

0.0.4

License

none

Last publish

Collaborators

  • pimvdmolen