Last active
August 14, 2019 13:08
-
-
Save AaronCQL/b3580f481e0783b970e7cb4c425a23e7 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const Telegraf = require('telegraf'); | |
| const functions = require('firebase-functions'); | |
| const bot = new Telegraf(functions.config().telegrambot.key); | |
| bot.hears('hi', (ctx) => ctx.reply('Hey there')); | |
| bot.launch(); | |
| exports.bot = functions.https.onRequest((req, res) => { | |
| bot.handleUpdate(req.body, res); | |
| }) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment