How to get youtube metadata while playing using video.js 7 - youtube

Video.js provides a method to get video metadata such as player.duration(). This works for regular mp4 videos. Is it possible to get information about license and title of YouTube videos?

You may check in this link the list of parameters that this query (Videos: list) supports.
The part parameter specifies a comma-separated list of one or more video resource properties that the API response will include.
If the parameter identifies a property that contains child properties, the child properties will be included in the response. For example, in a video resource, the snippet property contains the channelId, title, description, tags, and categoryId properties. As such, if you set part=snippet, the API response will contain all of those properties.

Related

Youtube API - Video Category ID assignables

i would like to ask a question regarding the difference between "assignable": true and "assignable":false. There are some videoCategory IDs that are marked as "assignable":false and can't be pulled via the API call.
Could you advice on this as there are some videoCategories that are key to our search. Thank you!
According to the docs, assignable is true if and only if the respective category is actually attributable (assignable) to any video's meta data.
In other words, one can call for endpoints Videos.insert or Videos.update setting (assigning) snippet.categoryId if and only if that category ID identifies a video category that has its property assignable set to true.

How to retrieve videos from playlist from particular category

How to retrieve videos from a playlist from a particular category? Is that even possible to do?
I did try this call :
https://www.googleapis.com/youtube/v3/videos?part=snippet%2CcontentDetails%2Cstatistics&maxResults=50&myRating=like&chart=mostPopular&videoCategoryId=10
But no luck
You may use the Search: list method which returns a collection of search results that match the query parameters specified in the API request.
By default, a search result set identifies matching video, channel, and playlist resources, but you can also configure queries to only retrieve a specific type of resource.

How to get the end screen element with an end_screen_element_id from Youtube API

With a channel reporting job, we can get the end_screen_element_ids for a given video. These IDs look like GUIDs.
The question is : How do we query the Youtube API to get what video/channel/... these end_screen_element_ids points to ?
Thanks!
You may use the reportTypes.list method. This returns a list of report types that the channel or content owner can retrieve. Each item in the list contains an id property, which identifies the report's ID, and you need this value to schedule a reporting job.

Cant find Youtube data v3 for channel list

Friends,
I want to search in the query, channels that belong to a certain category (categoryId).
In the example of the app console(https://developers.google.com/apis-explorer/),its ok.
But when I try to run the task with my key, the search returns no result.
i use this key:
https://www.googleapis.com/youtube/v3/channels?part=snippet&categoryId=GCQmVhdXR5ICYgRmFzaGlvbg&key={YOUR_API_KEY}
Try to use the videoCategoryId parameter which filters video search results based on their category. If you specify a value for this parameter, you must also set the type parameter's value to video.
You may encounter a badRequest (400) invalidSearchFilter error if the request contains an invalid combination of search filters and/or restrictions.
Note that you must set the type parameter to video if you set a value for the eventType, videoCaption, videoCategoryId, videoDefinition, videoDimension, videoDuration, videoEmbeddable, videoLicense, videoSyndicated, or videoType parameters.

Youtube API, iOS. Get items from 2 playlist

I have playlist A and playlist B.
Can I request for items from A and B in one request? I need to get mix of this playlists
This is an other example where checking the documentation will help
PlayLists.list
id string The id parameter specifies a comma-separated list of the
YouTube playlist ID(s) for the resource(s) that are being retrieved.
In a playlist resource, the id property specifies the playlist's
YouTube playlist ID.
you can send more then one play list id you just need to separate them with a comma. Use the try me at the bottom of the page to test it.

Resources