I'm using Zend_Gdata_YouTube to interface with the YouTube API to upload videos from my site. The videos are uploaded as "private":
$myVideoEntry->setVideoPrivate();
...and have unique tags and developer tags. An admin can then go into a custom CMS and approve the private user-submitted entries and make them public - at least, that's what I want to do.
In the CMS, I connect to the API as an authenticated user (Zend_Gdata_AuthSub). I can pull the authenticated user's video like so:
$videoFeed = $yt->getuserUploads('default');
This will pull all the videos, both private and public. But when I try to search for a specific video with a search term:
$query = $yt->newVideoQuery();
$query->setSafeSearch('none');
$query->setVideoQuery('puppies');
$videoFeed = $yt->getVideoFeed($query->getQueryUrl(2));
Or by tag:
$query = $yt->newVideoQuery();
$query->setOrderBy('viewCount');
$query->setRacy('include');
$query->setCategory('People/sometag');
// obtain a feed with videos matching the provided tag
$videoFeed = $yt->getVideoFeed($query);
Or by developer tag:
$devTagUrl = 'http://gdata.youtube.com/feeds/api/videos/-/%7Bhttp%3A%2F%2Fgdata.youtube.com' .
'%2Fschemas%2F2007%2Fdevelopertags.cat%7D' . $some_dev_tag;
$videoFeed = $yt->getVideoFeed($devTagUrl);
The private videos will return an empty result. However, if I make the video public, then I can pull it from any of the three methods above - all of which are being executed under an authenticated connection.
How can I pull a private video based on tag or developer tag? Am I missing something? Thanks so much!!