Answer the question
In order to leave comments, you need to log in
Getting photo in aiogram bytes?
hello, I want to get a photo into a variable without downloading the photo that the user attaches to the /photo command,
here is the code:
@dp.message_handler(commands=['photo'], commands_prefix="/.!?~-+")
async def version(message: types.Message):
# тут типа код как бот получает фото, но я не знаю как написать данный код...
im = Image.open(photo)
im = im.rotate(180)
await message.answer(f'получил фото', parse_mode='Markdown')
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