A Python Telegram bot with a Flask web panel for tracking RSS feeds, Reddit users, X users, and generic sources. Uses SQLite for storage.
- Install dependencies:
Requirements now include the
python -m pip install -r requirements.txt
python-telegram-bot[job-queue]extra. - Copy
.envand setBOT_TOKEN. - Run the web panel:
python -m src.web
- Run the bot:
python -m src.bot
- Track sources by type:
rss,reddit_user,x_user,generic - Subscribe a chat via
/subscribeor/start - Subscribe a channel via
/subscribechannel @channel_nameor through the web panel - Unsubscribe via
/unsubscribe - Add sources with
/addsource - Manage sources and subscriptions in the web panel
/start- Subscribe the current chat/subscribe- Subscribe the current chat to updates/subscribechannel <@username|chat_id>- Subscribe a channel (bot must be admin)/unsubscribe- Unsubscribe the current chat/addsource <type> <identifier> [name]- Add a new feed source/removesource <id>- Remove a source/sources- List all tracked sources/status- Show bot statistics
- The bot polls feeds periodically using
FETCH_INTERVALfrom.env. - The database is stored in
data.dbby default. - For channel subscriptions, the bot must be an admin in the channel to post messages.
- Channel usernames can be specified with
@prefix (e.g.,@mychannel) or use the channel's negative ID (e.g.,-1001234567890).