import telebot from telebot import types bot = telebot . TeleBot ( 'TOKEN' ) f = open ( 'photo.jpg' , 'rb' ) @bot.message_handler ( commands = [ 'start' ] ) def main ( message ) : markup = types . InlineKeyboardMarkup ( row_width = 1 ) bt1 = types . InlineKeyboardButton ( 'TEXT' , callback_data = 'text' ) bt2 = types . InlineKeyboardButton ( 'TEXT' , callback_data = 'text1' ) bt3 = types . InlineKeyboardButton ( 'TEXT' , callback_data = 'text2' ) markup . add ( bt1 , bt2 , bt3 ) bot . send_photo ( message . chat . id , f , reply_markup = markup ) bot . polling ( non_stop = True )
bot.send_photo(message.chat.id, f, reply_markup=markup)
bot.send_message(message.chat.id, "TEXT")