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

download video files from SRF Player (state-run Swiss Radio and Television) #981

Closed
ghost opened this issue Jul 2, 2013 · 20 comments
Closed

Comments

@yasoob
Copy link
Contributor

@yasoob yasoob commented Jul 3, 2013

The transport medium for the video is rtmp. Lets see what i can do.

@yasoob
Copy link
Contributor

@yasoob yasoob commented Jul 5, 2013

We get the rtmp url by quering http://www.srf.ch/webservice/cvis/segment/<vid id>/.json? In the first url you mentioned the video id is 28e1a57d-5b76-4399-8ab3-9097f071e6c5 and so on. Lets see what i can do further.

@yasoob
Copy link
Contributor

@yasoob yasoob commented Jul 8, 2013

BTW srf already has the option which allows anyone to download the video. It is available under the video with the name Speichern . Am i missing something or is it so @Lehrerin ?

@ghost
Copy link
Author

@ghost ghost commented Jul 8, 2013

that's true. Would prefer youtube-dl support, because of use within shell script.

@yasoob
Copy link
Contributor

@yasoob yasoob commented Jul 8, 2013

No problem :) and i found some videos which do not support downloading so
it will be useful to have youtube-dl support. But you will have to be
patient. It will take some time to make an IE for it.

On Mon, Jul 8, 2013 at 11:41 PM, Lehrerin notifications@github.com wrote:

that's true. Would prefer youtube-dl support, because of use within shell
script.


Reply to this email directly or view it on GitHubhttps://github.com//issues/981#issuecomment-20626795
.

@phihag
Copy link
Contributor

@phihag phihag commented Jul 8, 2013

@yasoob Can you post a video URL without downloading support as a test case?

@yasoob
Copy link
Contributor

@yasoob yasoob commented Jul 8, 2013

Lehrerin has already posted those but still here you go :

http://www.srf.ch/player/tv/10vor10/video/snowden-beantragt-asyl-in-russland?id=28e1a57d-5b76-4399-8ab3-9097f071e6c5
http://www.srf.ch/player/tv/tagesschau/video/edward-snowden-lehnt-russisches-asyl-angebot-ab?id=832b156e-adf9-44ed-b346-ca35c1076eec
http://www.srf.ch/player/tv/schweiz-aktuell/video/christian-wanner-tritt-von-der-politischen-buehne-ab?id=793ce2ff-e35e-4638-a657-72ba51688cfd
@phihag
Copy link
Contributor

@phihag phihag commented Jul 8, 2013

@yasoob Every single one has a Speichern button and allows downloads, both from Germany and the US.

@yasoob
Copy link
Contributor

@yasoob yasoob commented Jul 9, 2013

No yesterday I found some videos which didnot have a download
button.......but what you are saying is that every video has a download
button so I think in pakistan not every video is available for download.
Once I get back on my pc I will post the url of the video which didn't have
the download button.

@yasoob
Copy link
Contributor

@yasoob yasoob commented Jul 12, 2013

This video does not have a download button. Not in Pakistan atleast. Does it show on your side ?

@phihag
Copy link
Contributor

@phihag phihag commented Jul 12, 2013

Oh, you're right, nice test case.

@hansdampf
Copy link

@hansdampf hansdampf commented Feb 8, 2014

based on the infos of this thread I was able to write download.sh that downloads movies from srf.ch, either provide url of the detail entry, like this:

./download.sh "http://www.srf.ch/player/tv/guetnachtgschichtli/video/guetnachtgschichtli-11-das-alphorn-vom-18-11-2013?id=fadc0e5a-8643-4f2c-aff2-8a1d41a0b4f4"

or provide any page with many videos on it and the script downloads them all:

./download.sh http://www.srf.ch/player/tv/suche?query=olivia+guetnachtgschichtli

important: you need to have rtmpdump installed. And the rtmp streams are not that stable, that's why it needs the resume loop. Other than that the script should be quite straightforward.

@phihag
Copy link
Contributor

@phihag phihag commented Feb 8, 2014

@hansdampf Are you willing to put that script under Unlicense? Than we could try to integrate it into youtube-dl.

@hansdampf
Copy link

@hansdampf hansdampf commented Feb 9, 2014

@phihag sure, added the section. If you integrate it, please add the note that it is meant for backup purposes and not to spread the video. Sfdrs doesn't provide a download link for some of the vids and I want to respect that. Personally I wrote it to download "Guetnachtgschichtli" videos for my kids and upload them to my google drive account, which acts as a "video store" for all the videos they ought to watch in the evening.

@hansdampf
Copy link

@hansdampf hansdampf commented Feb 9, 2014

@phihag oh and the script still needs some debugging. I did about 3-4 runs now with each about 10 video downloads. One time I ran into a "connection refused" problem and that might be because I ran into some sort of throttling mechanism.

@phihag phihag mentioned this issue Mar 14, 2014
@ghost
Copy link
Author

@ghost ghost commented Jul 30, 2014

would be great to have SRF player support in youtube-dl. Any progress? thanks

@yan12125
Copy link
Collaborator

@yan12125 yan12125 commented Apr 16, 2015

I've implemented the extractor. For the video mentioned by @yasoob

http://www.srf.ch/play/tv/top-gear/video/jaguar-xk120-shadow-und-tornado-dampflokomotive?id=677f5829-e473-4823-ac83-a1087fe97faa

I can't play the video in the browser but I can download it with
youtube-dl. The error message in the browser is "Aus rechtlichen Gründen stand dieses Video nur innerhalb eines bestimmten Zeitraums zur Verfügung". I can't find out where this message comes from, so I just ignore it. Note I'm in Taiwan, GMT+8

@MaEtUgR
Copy link

@MaEtUgR MaEtUgR commented Feb 26, 2017

"Aus rechtlichen Gründen stand dieses Video nur innerhalb eines bestimmten Zeitraums zur Verfügung"

just means you are officially not able to watch it anymore because it's too old now.

Thank you for integrating this feature! in some rare cases it's so useful to archive a video for private use.

@idotter
Copy link

@idotter idotter commented Jan 14, 2018

Hey,
Tried to download some audio examples like e.g. https://www.srf.ch/play/radio/popupaudioplayer?id=53ec7fd0-ed59-4ac5-98aa-4ca4bba85ca8 youtube-dl tells me "Unsupported URL"
Any chance to have this working? @phihag

@jhuesser
Copy link

@jhuesser jhuesser commented Nov 23, 2018

Sorry to dig out an old thread, but had the same problem. @idotter This is the URL of an embeded player. You need to click the "Play SRF" button on the lower right corner to get the actual URL. for your audio sample it's https://www.srf.ch/play/radio/audio-srf-1/audio/lukas-gerber-wo-mir-als-buebe-emal?id=53ec7fd0-ed59-4ac5-98aa-4ca4bba85ca8&station=69e8ac16-4327-4af4-b873-fd5cd6e895a7

It worked fine for me:

youtube-dl.exe "https://www.srf.ch/play/radio/audio-srf-1/audio/lukas-gerber-wo-mir-als-buebe-emal?id=53ec7fd0-ed59-4ac5-98aa-4ca4bba85ca8&station=69e8ac16-4327-4af4-b873-fd5cd6e895a7"
[SRGSSR] 53ec7fd0-ed59-4ac5-98aa-4ca4bba85ca8: Downloading JSON metadata
[download] Destination: Lukas Gerber - «Wo mir als Buebe emal»-53ec7fd0-ed59-4ac5-98aa-4ca4bba85ca8.mp3
[download] 100% of 1.40MiB in 00:00
@ytdl-org ytdl-org locked as resolved and limited conversation to collaborators Nov 23, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
7 participants
You can’t perform that action at this time.