Path: csiph.com!usenet.pasdenom.info!aioe.org!news.stack.nl!newsfeed.xs4all.nl!newsfeed4.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.039 X-Spam-Evidence: '*H*': 0.92; '*S*': 0.00; 'parameters': 0.04; 'json': 0.07; 'mentions': 0.09; 'subject:script': 0.09; 'url:github': 0.09; 'api': 0.11; 'sections': 0.14; 'from:addr:mrabarnett.plus.com': 0.16; 'from:addr:python': 0.16; 'from:name:mrab': 0.16; 'message-id:@mrabarnett.plus.com': 0.16; 'suggest?': 0.16; 'wrote:': 0.18; 'looked': 0.18; 'thu,': 0.19; 'putting': 0.22; 'header:User-Agent:1': 0.23; 'file.': 0.24; 'script': 0.25; 'least': 0.26; 'skip:" 20': 0.27; 'header:In- Reply-To:1': 0.27; 'rest': 0.29; 'wondering': 0.29; 'am,': 0.29; "i'm": 0.30; 'url:mailman': 0.30; 'sep': 0.31; 'txt': 0.31; "user's": 0.31; 'subject:all': 0.32; 'url:python': 0.33; 'screen': 0.34; 'problem': 0.35; 'subject:with': 0.35; 'there': 0.35; 'module.': 0.36; 'right?': 0.36; 'url:listinfo': 0.36; 'url:org': 0.36; 'list': 0.37; 'displays': 0.38; 'e.g.': 0.38; 'to:addr :python-list': 0.38; 'bill': 0.39; 'to:addr:python.org': 0.39; 'url:mail': 0.40; 'ago.': 0.61; 'simple': 0.61; 'youtube': 0.65; 'url:0': 0.67; 'header:Reply-To:1': 0.67; '26,': 0.68; 'reply- to:no real name:2**0': 0.71; 'url:youtube': 0.71; '(none': 0.84; "it'd": 0.84; 'reply-to:addr:python.org': 0.84; 'url:feeds': 0.84; 'joel': 0.91; '2013': 0.98 X-CM-Score: 0.00 X-CNFS-Analysis: v=2.1 cv=bKAvfpOZ c=1 sm=1 tr=0 a=0nF1XD0wxitMEM03M9B4ZQ==:117 a=0nF1XD0wxitMEM03M9B4ZQ==:17 a=0Bzu9jTXAAAA:8 a=LqG8EI-UCiYA:10 a=Qq8EZeuK9OoA:10 a=ihvODaAuJD4A:10 a=OUOv7kDek9cA:10 a=8nJEP1OIZ-IA:10 a=EBOSESyhAAAA:8 a=8AHkEIZyAAAA:8 a=NHlP9jQ3IlEA:10 a=SeT8-YqtAAAA:8 a=jK3bGrtaAAAA:8 a=1XWaLZrsAAAA:8 a=_kH1obqLAAAA:8 a=vnREMb7VAAAA:8 a=_d7dBBR1YFsyBG2MgaMA:9 a=wPNLvfGTeEIA:10 a=ejdhhJg72H0A:10 X-AUTH: mrabarnett:2500 Date: Thu, 26 Sep 2013 19:33:35 +0100 From: MRAB User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:24.0) Gecko/20100101 Thunderbird/24.0 MIME-Version: 1.0 To: python-list@python.org Subject: Re: Download all youtube favorites with youtube-dl script References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list Reply-To: python-list@python.org List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 58 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1380220411 news.xs4all.nl 15881 [2001:888:2000:d::a6]:35120 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:54847 On 26/09/2013 19:14, Bill wrote: > Joel Goldstick wrote: >> >> >> >> On Thu, Sep 26, 2013 at 11:13 AM, Bill > > wrote: >> >> I have been using the script youtube-dl >> http://rg3.github.io/youtube-__dl/ >> >> And I was wondering if there is a way to download all of a user's >> favorites or uploads. >> >> The script has a functionality to download all videos in a txt file. >> So if there is a way using the youtube API or JSON (none of which I >> am familiar with) to bring up a list of all these videos then it'd >> be a simple case putting these urls into a file. >> >> The problem is youtube displays favorites or user uploads in pages >> or infinite scroll. So it is difficult to access them by the >> BeautifulSoup module. >> >> >> What do you suggest? >> -- >> https://mail.python.org/__mailman/listinfo/python-list >> >> >> >> Have you looked at the youtube API? That would be better than screen >> scraping. https://developers.google.com/youtube/getting_started >> >> >> -- >> Joel Goldstick >> http://joelgoldstick.com > > I remember looking at this a while ago. These are the relevant sections > of the API: > > https://developers.google.com/youtube/2.0/developers_guide_protocol?hl=en#User_Uploaded_Videos > > https://developers.google.com/youtube/2.0/developers_guide_protocol?hl=en#Favorite_Videos > > The problem with the API is that with both of these, it only brings up > 25 videos e.g. https://gdata.youtube.com/feeds/api/users/scooby1961/uploads > > Unless I'm missing something? There must be a way to bring up all of > them on one page right? Or at least cycle through the rest of them. > You _are_ missing something. That section of "#User_Uploaded_Videos" mentions the parameters "start-index" and "max-results". > Same problem with favorties: > https://gdata.youtube.com/feeds/api/users/adambuxton/favorites/ >