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

Failed to get final url #418

Closed
a3d opened this issue Sep 12, 2012 · 1 comment
Closed

Failed to get final url #418

a3d opened this issue Sep 12, 2012 · 1 comment

Comments

@a3d
Copy link

@a3d a3d commented Sep 12, 2012

Hye, I want to know is there any way to get the "final url" before the video is download by server.
by using this command, the url is not finalize yet, I cant access directly to the video url. I think you understand what I means after youtube changed.

youtube-dl --get-url http://youtube.com/watch?v=Id

What I mean is after Downloading video webpage, Downloading video info webpage, Extracting video information..
is it possible to get the "final url" after extracting video information? Because I know with that final url, the server can download the video from youtube. using --get-url cant get that final url.

why I need this "final url" ?

Currently Im developing php script to download the mp3 from youtube instantly. yes instantly.
Of course it works fine on my pc because the access token is always created.
But on this program, Im stuck. I hope that you can show me how to get the final url.
Thanks.

@phihag
Copy link
Contributor

@phihag phihag commented Sep 27, 2012

The URL you get with --get-url is only valid for requests from the same IP(v4), and with the correct cookies (Use the --cookies option to store those). This is the final URL.

But for your application - as far as I understand, you want to convert on the fly without having to download the whole file - you can just use the -o option to either output to a pipe or stdout (with -o -), can't you?

If that doesn't work, you can also try to download with the cookies saved by --cookies.

@phihag phihag closed this Sep 27, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

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