Skip to main content

A utility for quickly generating projects on aiogram 3

Project description

🚀 TelegramBotCLI

A lightweight command-line utility for quickly generating professional project structures for Aiogram 3 bots. Stop wasting time on boilerplate and start coding your logic instantly.

✨ Features

  • Standard & Advanced Templates: Choose between a lightweight setup or a production-ready structure.
  • Pro Components: Includes Anti-flood Middleware and Admin Filters out of the box.
  • Database Ready: Pre-configured SQLModel (SQLite/PostgreSQL) integration.
  • Smart OS Detection: Suggests the correct run command (python vs python3) for your system.
  • Automated Init: Handles all __init__.py files automatically for clean imports.

📦 Installation

Install the tool directly from PyPI:

pip install telegrambotcli

🌞 How to Start

Open your terminal in the desired project folder and run:

bash

telegrambotcli

You will be prompted to choose a template:

  1. [Standard] : Basic bot with DB, Keyboards, and essential handlers.
  2. [Advanced] : Includes Admin logic, Anti-flood protection, and advanced filtering.

📂 Generated Project Structure

text

your_project/
├── app/
│   ├── database/
│   │   └── database.py    # SQLModel engine & User model
│   ├── filters/           # (Advanced) AdminFilter logic
│   ├── keyboards/
│   │   └── builders.py    # Reply & Inline keyboard templates
│   ├── middlewares/       # (Advanced) Anti-flood middleware
│   └── main.py            # Main Router (Help, Settings, Admin handlers)
├── bot.py                 # Main entry point (Dispatcher & Polling)
├── .env                   # Environment variables (Token, Admin ID)
└── .gitignore             # Pre-configured for Python & VSCode

🚀 Quick Start Guide

  1. Configure: Open the generated .env file and fill in your credentials: env

    BOT_TOKEN="123456:ABC-DEF..."
    ADMIN_ID="987654321"
    
  2. Run: Launch your bot using the suggested command: bash

    python bot.py  # or python3 bot.py
    

🛠 Handlers Included

The generated app/main.py automatically includes:

  • /start, /keyboard, /inline
  • Text filters for "Help 🆘" and "Settings ⚙️" buttons.
  • Admin check for the /admin command (in Advanced mode).

🧑‍💻GitHub repository

Sourse code PyPi page

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

telegrambotcli-0.5.2-py3-none-any.whl (6.6 kB view details)

Uploaded Python 3

File details

Details for the file telegrambotcli-0.5.2-py3-none-any.whl.

File metadata

  • Download URL: telegrambotcli-0.5.2-py3-none-any.whl
  • Upload date:
  • Size: 6.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.13.1

File hashes

Hashes for telegrambotcli-0.5.2-py3-none-any.whl
Algorithm Hash digest
SHA256 286cca26a4a47593e82ee56d6365c61025d4e477bf9c13f77351e937d9950e48
MD5 c4d0cc820479d74ed1e235d6711da8a6
BLAKE2b-256 ee749b01762cc61f7ab21eeff2287e4f22763bdb3a070c14f9f3be6bd31025db

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page