https://github.com/kailuser/botforge
BotForge - tiny telegram api library
https://github.com/kailuser/botforge
telegram telegram-api telegram-bot-api
Last synced: 10 months ago
JSON representation
BotForge - tiny telegram api library
- Host: GitHub
- URL: https://github.com/kailuser/botforge
- Owner: KailUser
- License: mit
- Created: 2024-01-25T06:24:11.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-27T04:44:44.000Z (over 2 years ago)
- Last Synced: 2025-08-21T07:41:44.587Z (10 months ago)
- Topics: telegram, telegram-api, telegram-bot-api
- Language: Python
- Homepage: https://pypi.org/project/BotForge/
- Size: 8.79 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# BotForge - Telegram Bot Library
BotForge is a lightweight Python library designed to simplify the development of Telegram bots. It provides a simple interface to interact with the Telegram Bot API and includes features for handling commands.
## Features
- Easy setup for Telegram bots
- Command handling with decorators
- Simplified interaction with the Telegram Bot API
## Installation
You can install BotForge using pip:
```bash
pip install BotForge
```
## Usage
```python
# Import BotForge and necessary modules
import time
from functools import wraps
from BotForge import BotForge, CommandContext
# Initialize BotForge with your bot token
bot = BotForge(token="YOUR_BOT_TOKEN")
# Define command handlers using decorators
@bot.command_handler("/start")
def hello(ctx):
bot.send_message(ctx.chat_id, f"Hello, {ctx.username}")
@bot.command_handler("/help")
def help_command(ctx):
bot.send_message(ctx.chat_id, f"Hello again! {ctx.username}")
# Start the bot
bot.start()
```
## Contributing
Contributions are welcome! If you have any ideas, bug reports, or feature requests, please open an issue on the [GitHub repository](https://github.com/KailUser/BotForge).
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
Replace `"YOUR_BOT_TOKEN"` with the actual token of your Telegram bot.