TelegramChatBot

所属分类:聊天室
开发工具:Python
文件大小:0KB
下载次数:0
上传日期:2024-03-29 18:54:43
上 传 者sh-1993
说明:  TelegramChatBot将与技术相关的新闻文章获取和发布到指定的Telegram频道。
(TelegramChatBot fetches and posts technology-related news articles to a specified Telegram channel.)

文件列表:
requirements.txt
telegram_tech_news_bot.py

# Telegram Tech News Bot ## Overview This Telegram bot fetches and posts technology-related news articles to a specified Telegram channel. It utilizes the News API to fetch news and the Telegram Bot API to post news articles to the channel. ## Features 1.Fetches random technology-related news using the News API. 2.Formats news articles into a readable format with titles, descriptions, and URLs. 3.Posts formatted news to a specified Telegram channel using the Telegram Bot API. 4.Randomly selects a technology keyword for each news fetch to provide variety. ## Requirements - Python 3.x - `requests` library (`pip install requests`) ## Setup Clone the repository: ``` git clone https://github.com/tamilselvanarjun/TelegramChatBot.git ``` ## Install the required library: ``` pip install requests ``` Replace placeholders in the script: Replace your_telegram_bot_token with your actual Telegram bot token. Replace your_telegram_channel_id with your actual Telegram channel ID. Replace your_news_api_key with your actual News API key. ## Usage Run the script: ``` python telegram_tech_news_bot.py ``` The bot will fetch a technology keyword, fetch news related to that keyword, format the news, and post it to the specified Telegram channel. ## Contributing Contributions are welcome! If you encounter any issues or have suggestions, please open an issue or submit a pull request. ## License This project is licensed under the MIT License - see the LICENSE file for details.

近期下载者

相关文件


收藏者