Differences between v3 and v2 of YouTube API - youtube

I'm doing some new work using the YouTube API. I know there are two versions, v2 and v3, but I can't find the differences anywhere. What are the differences?
I know v3 is labeled "experimental". But:
What's better about it?
Other than being experimental, what's worse about it?
Will v2 be phased out?
For new dev work, should I use v2 or v3

Some answers (in my opinion ..)
What's better about it?
Search videos, channels and playlists using freebase topics
https://developers.google.com/youtube/v3/docs/search
Retrieve activities
https://developers.google.com/youtube/v3/docs/activities
Other than being experimental, what's worse about it?
Changes in API calls that you use in your app
For new dev work, should I use v2 or v3
I think the answer depends on what your application should do and the type of application

Related

Will topic based searches work after freebase is deprecated

Freebase will be deprecated starting Tuesday, March 31st, what does this mean for topic based searches with the youtube api? Will these queries still work?
https://www.googleapis.com/youtube/v3/search?part=snippet&relevanceLanguage=en&topicId=%2Fm%2F04qf57&type=video&videoSyndicated=true&key={YOUR_API_KEY}
I think this will be unaffected since Google Knowledge Graph API, which is the replacement of Freebase, is able to search by topicId too.
Do not quote me on this one though as there's really no documented change notes on the Youtube Data API
Also, some SO posts that contains discussions regarding the possible impact and alternatives(as of the moment) to the use of Youtube Data API and topicIds can be found here and here

YouTube Cards API

I am wondering if anybody has any information or news regarding the API (if it exists yet?) of the new YouTube Cards (replacing the old annotations).
Is there any beta api information out yet?
I'm referring to this:
Thank you for your help
You can track the YouTube Developer Blog and also subscribe to the revision history of YouTube Data API v3, in order to get the latest info on the API, as soon as it is available. Currently (as of the last version of the API - April 27, 2015) there is no way to manage Cards, and I suspect that there would not be, at least not anytime soon.
I think so because currently even annotations are not fully supported by YouTube Data API v3 (they only added support for setting invideo annotations in v3). I suppose there is a specific reason that this feature has been missing for so long- maybe they don't want to unleash it because they foresee some problems that may arise if they do. It has been requested numerous times in the past by the community (See the last posts in this thread, where a YouTube representative has answered, also this question).
I'll investigate further to see if I can find any more info on future revisions of the API and will update my answer. Meanwhile, you can submit a feature request for Card Management API here. Good luck!

How to fetch featured videos using the YouTube API v3?

I use some standard feeds of YouTube API v2 like:
http://gdata.youtube.com/feeds/api/standardfeeds/recently_featured
http://gdata.youtube.com/feeds/api/standardfeeds/most_viewed_Music?time=today&v=2
Now, I want to switch to API v3, I have read the doc here: https://developers.google.com/youtube/v3/docs/
There are many resources types and methods, but it seems none is correspond to the old v2 standard feeds, is there any solution for the job ?
You can use videoCategories and guideCategories for that.
Here's the full blog.
GDL video.

YouTube API 3.0 Query Search

I had a working script written in PHP YouTube API 2.0 that would retrieve a feed of videos based on a search query.
Over the couple months it has been getting choppy and it won't consistently retrieve the amount of video views that each video has which is messing up my website.
Does anyone have or know where I can find a working Zend PHP YouTube API 3.0 example that will retrieve videos based on a specific search query?
Anything helps!
Check https://developers.google.com/youtube/v3/code_samples/php
But be aware, that the V3 is still "experimental" and therefore some things might not work as expected ;)
you can find many code samples like https://developers.google.com/youtube/v3/live/code_samples/php
Getting started - https://developers.google.com/gdata/articles/php_client_lib
YouTube API Samples project has a great example. Make sure, you enabled Data API v3 in your dev console first. Also Data API v3 is highly supported and not experimental anymore.

Listing all comments for a video in YouTube API 3.0

Is it possible to get all comments for a video with the new (experimental) YouTube API v 3.0?
I only found how to get "activities" (in their terminology comment is a kind of activity) originating from a given account.
The api page says the api is not feature complete, so it is quite possible that functionality is not yet made available. Although I might've just missed it.
There's no support for retrieving comments using v3 of the API. We can't make any commitments to add in support for reading/writing comments at this time, so if your application depends on them, using v2 is required.

Resources