From 550e0b6440c1ea747733814aab2ba6d7de7a6947 Mon Sep 17 00:00:00 2001 From: pri10088 Date: Sun, 6 Oct 2024 21:13:38 +0530 Subject: [PATCH] Updated bot.py and added .gitignore file --- .gitignore | 1 + bot.py | 7 +++++-- 2 files changed, 6 insertions(+), 2 deletions(-) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..eba74f4 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +venv/ \ No newline at end of file diff --git a/bot.py b/bot.py index 7bf6f9d..6573520 100644 --- a/bot.py +++ b/bot.py @@ -6,7 +6,7 @@ # Constants BOT_USERNAME: Final = 'xyz' -BOT_TOKEN: Final = "your token" +BOT_TOKEN: Final = os.getenv("BOT_TOKEN") COINGECKO_API_URL: Final = "https://api.coingecko.com/api/v3" # Conversation states @@ -62,7 +62,10 @@ async def show_main_menu(update: Update, context: ContextTypes.DEFAULT_TYPE) -> keyboard = [ [InlineKeyboardButton("Top 100 Cryptocurrencies", callback_data='top100')], [InlineKeyboardButton("Trending Cryptocurrencies", callback_data='trending')], - [InlineKeyboardButton("Search Cryptocurrency", callback_data='search')] + [InlineKeyboardButton("Search Cryptocurrency", callback_data='search')], + [InlineKeyboardButton("Litecoin (LTC)", callback_data='crypto:litecoin')], + [InlineKeyboardButton("Dogecoin (DOGE)", callback_data='crypto:dogecoin')], + [InlineKeyboardButton("Cardano (ADA)", callback_data='crypto:cardano')], ] reply_markup = InlineKeyboardMarkup(keyboard) text = "Welcome to the Crypto Price Bot! What would you like to do?"