Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Telegram (t.me) #23376

Closed
5 tasks done
jasomdotnet opened this issue Dec 11, 2019 · 8 comments
Closed
5 tasks done

Add support for Telegram (t.me) #23376

jasomdotnet opened this issue Dec 11, 2019 · 8 comments
Labels
out-of-scope site-support-request Add extractor(s) for a new domain

Comments

@jasomdotnet
Copy link

  • I'm reporting a new site support request
  • I've verified that I'm running youtube-dl version 2019.11.28
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that none of provided URLs violate any copyrights
  • I've searched the bugtracker for similar site support requests including closed ones (yes, nothing)

Example URLs

Description

Hi, add support for Telegram. It's social network with more then 200 million users. See this press release: https://telegram.org/blog/200-million Twitter or Instagram is similar service like Telegram.

@jasomdotnet jasomdotnet added the site-support-request Add extractor(s) for a new domain label Dec 11, 2019
@ghost
Copy link

ghost commented Dec 14, 2019

Telegram is not video streaming website, Telegram is not a social network, Telegram is a instant messaging system, with it's own transport protocol.

You can't watch videos by just clicking on "t.me/xxx" link, because there is no video streaming on t.me website - all video's accessible only using telegram protocol(you must have installed client, or use web-client), not directly via http(-s).

Implementing this is different from main goal and current architecture of YouTube-dl, also it requires adding some pretty huge Telegram client library to youtube-dl dependencies(like Telethon or pyrogram).

Also, I think, it's don't have any practical purpose - inside telegram you can literally just right-click and select "download" on any video - there is no any downloading restriction's like on streaming websites.

@jasomdotnet
Copy link
Author

Also, I think, it's don't have any practical purpose - inside telegram you can literally just right-click and select "download" on any video - there is no any downloading restriction's like on streaming websites.

I found out this later.

@jasomdotnet
Copy link
Author

Leaving this open if anybody wants to add additional comments

@Linux-joy
Copy link

Hi @sergey-rufanov,

You can't watch videos by just clicking on "t.me/xxx" link, because there is no video streaming on t.me website - all video's accessible only using telegram protocol(you must have installed client, or use web-client), not directly via http(-s).

If I access t.me messages with my firefox browser and if they embed videos or voice messages, I can watch/hear them directly within the browser. So, videos or voice messages might accessed via http(-s) by the browser – ant not via telegram protocol? Or, the telegram protocol is build in the browser?

Also, I think, it's don't have any practical purpose - inside telegram you can literally just right-click and select "download" on any video - there is no any downloading restriction's like on streaming websites.

But I think it might have a practical purpose: On my desktop computer (in my case the OS is Linux, but I think that there would be a real purpose for other OSs, too) I want to watch/hear telegram videos or voice messages on an external application like mpv for better (means: more exactly) forward/backwards skipping inside the videos or voice messages. mpv uses youtube-dl to access to videos etc. and then play them without downloading them permanently. If I actually want to cause a familar behaviour, I first have to download the video etc. to my "/tmp"-directory and then access to it via mpv or a similar application. So, to simplify the whole procedure, the Telegram (t.me) support should be added to youtube-dl.

@aatv
Copy link

aatv commented Dec 6, 2020

ytdl is compatible with t.me/xyz/123 media content when you add ?embed=1 suffix:

youtube-dl https://t.me/police_frequency/19788?embed=1

[generic] 19788?embed=1: Requesting header
WARNING: Could not send HEAD request to https://t.me/police_frequency/19788?embed=1: HTTP Error 501: Not Implemented
[generic] 19788?embed=1: Downloading webpage
WARNING: Falling back on generic information extractor.
[generic] 19788?embed=1: Extracting information
[download] Downloading playlist: Telegram Widget
[generic] playlist Telegram Widget: Collected 1 video ids (downloading 1 of them)
[download] Downloading video 1 of 1
[download] Destination: Telegram Widget-19788embed=1.mp4
[download] 100% of 1.25MiB in 00:00
[download] Finished downloading playlist: Telegram Widgetmp4 link that can played by mpv

@mayeaux
Copy link

mayeaux commented Nov 20, 2021

@aatv I LOVE YOU THANK YOU OMG

@bertsky
Copy link

bertsky commented Nov 27, 2021

Another use-case: if t.me says Media is too big (for the browser) and only offers view in telegram.

The ?embed=1 suffix method does not work in my case.

@mayeaux
Copy link

mayeaux commented Nov 29, 2021

Another use-case: if t.me says Media is too big (for the browser) and only offers view in telegram.

The ?embed=1 suffix method does not work in my case.

I just ran into that too. RIP.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
out-of-scope site-support-request Add extractor(s) for a new domain
Projects
None yet
Development

No branches or pull requests

6 participants