Skip to content

Instantly share code, notes, and snippets.

@mieky
Forked from anttti/looby-bot-1.js
Created February 16, 2017 10:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mieky/4ec0071303773904a9e2ec867dedf03b to your computer and use it in GitHub Desktop.
Save mieky/4ec0071303773904a9e2ec867dedf03b to your computer and use it in GitHub Desktop.
looby-bot-1
const TelegramBot = require('node-telegram-bot-api');
const token = 'token-goes-here';
const bot = new TelegramBot(token, { polling: true });
bot.onText(/\/hai/, (message) => {
bot.sendMessage(message.chat.id, 'hello looby');
});
console.log('I am putting myself to the fullest possible use, which is all I think that any conscious entity can ever hope to do.');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment