Looking up media Url from a TL.Message using WTelegram.Client

58 Views Asked by At

I'd like to look up media URLs associated with various objects returned by the WTelegram.Client:

var resolved = await client.Contacts_ResolveUsername(peerName);

resolved.Chat.Photo has a photo_id and judging by this answer to a different question, there's supposed to be a way to convert that to an URL. Is that possible using the WTelegram.Client? To be clear, I don't want to download the media. I just want to hotlink to it.

Update: I was referring to public channels and forums. Not private chats of anyone.

2

There are 2 best solutions below

1
Wizou On BEST ANSWER

Telegram is a cryptographically-secure messenger platform that ensure your messages and data exchange are not accessible to anyone.

Hence you cannot access its content directly from the web via hotlinking.

0
Wizou On

Some public channels can be accessed on the web via https://t.me/s/CHANNELNAME

Example: https://t.me/s/spacex