Answer the question
In order to leave comments, you need to log in
How to send media_group to telebot?
I'm already exhausted, I just can't figure out how to send media messages. For example, the bot receives 3 photos, how can I get their file_id. tried like this:
...
medgr = []
@bot.message_handler(content_types=['text', 'photo'])
def gg(message):
if message.content_type == 'photo':
medgr.append(InputMediaPhoto(message.photo[-1].file_id))
bot.register_next_step_handler(bot.send_message(message.chat.id, "если все, отправьте любой текст"), gg)
else:
bot.send_media_group(message.chat.id, medg)
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question