How to send a photo with compressing.
I have the code:
client = TelegramClient(
"session",
api_id=CONFIG["client_api_id"],
api_hash=CONFIG["client_api_hash"]
)
client.connect()
if not client.is_user_authorized():
phone = input("Your phone: ")
code = client.send_code_request(phone)
myself = client.sign_in(phone, input("Your code: "))
# Sending a photo with description
client.send_message(
777000,
"test",
file="https://avatars.mds.yandex.net/get-zen_doc/5295210/pub_60dd6ea6828fb32711ebfc76_60dd7130df4f6532136de7b1/scale_1200"
)
When i run this code i get:
image
But i want this:
image
I tried to add force_document=False
to arguments of method .send_message
but it didn't work
I'm dumppy. force_document=False
is working xD