BLAZOGRAM - is a library for make Telegram Bots
Project description
BLAZOGRAM - A library for make Telegram Bots.
Install
$ pip install blazogram
Example Usage
from blazogram import Bot, Dispatcher, BlazeLocale
from blazogram.types import Message, CallbackQuery, ReplyKeyboardMarkup, KeyboardButton
from blazogram.filters import Command, Data
from blazogram.enums import ParseMode
import asyncio
async def start_command(message: Message):
kb = ReplyKeyboardMarkup()
button = KeyboardButton(text='BUTTON')
kb.add_button(button)
await message.answer(text='Hello World!', reply_markup=kb)
async def some_func(callback: CallbackQuery):
await callback.answer(text='Hello World!', show_alert=True)
async def main():
bot = Bot(token='YOUR-BOT-TOKEN', parse_mode=ParseMode.HTML)
dp = Dispatcher()
dp.message.register(start_command, Command("start"))
dp.callback_query.register(some_func, Data("BUTTON_DATA"))
await bot.skip_updates()
try:
await dp.start_polling(bot)
finally:
await bot.session.close()
if __name__ == '__main__':
asyncio.run(main())
Developer - @Blaze_Egor
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
blazogram-2.1.tar.gz
(16.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
blazogram-2.1-py3-none-any.whl
(27.7 kB
view details)
File details
Details for the file blazogram-2.1.tar.gz.
File metadata
- Download URL: blazogram-2.1.tar.gz
- Upload date:
- Size: 16.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fc0409eee4e92b05f592bca9b98d798da66993c7a260d4e859aaaff10915aa7e
|
|
| MD5 |
02c78941881f0dfad9091248e337d07d
|
|
| BLAKE2b-256 |
c33ee7aeb21c7f078a9fad62e52a3d01d55504993ddbe84c6e8a076a19404e57
|
File details
Details for the file blazogram-2.1-py3-none-any.whl.
File metadata
- Download URL: blazogram-2.1-py3-none-any.whl
- Upload date:
- Size: 27.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.2 CPython/3.11.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c30654991aad86a6e5ec551b6523d6bcb5f1523093c9b0fe6f2b0e27bc3f29d3
|
|
| MD5 |
a18ba6638de9ff771c8d64920465234c
|
|
| BLAKE2b-256 |
5d03bd29a4827b447c8d47d9b2143ac62875d684120282e6946d6b892166bc68
|