1.1.11 • Published 9 months ago
regraf v1.1.11
Introduction
Bots are special Telegram accounts designed to handle messages automatically. Users can interact with bots by sending them command messages in private or group chats. These accounts serve as an interface for code running somewhere on your server.
Regraf is a continuation of the Telegraf@3.
Features
- Full Telegram Bot API 7.1 support
- Telegram Payment Platform
- HTML5 Games
- Inline mode
- Incredibly fast
- Vercel/Firebase/Glitch/Heroku/AWS λ/Whatever ready
http/https/fastify/Connect.js/express.jscompatible webhooks- Easy to extend
TypeScripttypings
Installation
npm install regrafor using yarn:
yarn add regrafDocumentation
Regraf developer docs in development.
Examples
const { Regraf } = require('regraf')
const bot = new Regraf(process.env.BOT_TOKEN)
bot.start((ctx) => ctx.reply('Welcome!'))
bot.help((ctx) => ctx.reply('Send me a sticker'))
bot.on('sticker', (ctx) => ctx.reply('👍'))
bot.hears('hi', (ctx) => ctx.reply('Hey there'))
bot.launch()const { Regraf } = require('regraf')
const bot = new Regraf(process.env.BOT_TOKEN)
bot.command('oldschool', (ctx) => ctx.reply('Hello'))
bot.command('modern', ({ reply }) => reply('Yo'))
bot.command('hipster', Regraf.reply('λ'))
bot.launch()There's some cool examples too.
1.1.9
9 months ago
1.1.8
10 months ago
1.1.7
12 months ago
1.1.11
9 months ago
1.1.10
9 months ago
1.1.1
1 year ago
1.1.0
1 year ago
1.0.9
1 year ago
1.0.8
1 year ago
1.1.6
1 year ago
1.0.7
1 year ago
1.1.5
1 year ago
1.0.6
1 year ago
1.1.4
1 year ago
1.0.5
1 year ago
1.1.3
1 year ago
1.0.4
1 year ago
1.1.2
1 year ago
1.0.3
1 year ago
1.0.11
1 year ago
1.0.10
1 year ago
1.0.13
1 year ago
1.0.12
1 year ago
1.0.2
1 year ago
1.0.1
1 year ago
1.0.0
1 year ago