I'm using youtube api v3 for updating video parameters:
var resource = {
id: videoId,
snippet: {
title: "my title",
description: "my description",
tags: tagsArray,
categoryId: '22',
},
YouTube.Videos.update(resource, 'id,snippet');
But when I use these code the default language puts English in order to use my default channel language Spanish. I would like to put Spanish like language. How can I put the language in the youtube video with google youtube api v3?
I don't see anything in the oficial documentation: https://developers.google.com/youtube/v3/docs/videos/update?hl=es
Related
When I'm getting the response from Youtube's API for some videos, the contentRating is empty:
"contentDetails":{
"duration":"PT1H24M43S",
"dimension":"2d",
"definition":"sd",
"caption":"true",
"licensedContent":true,
"regionRestriction":{
"allowed":[
"US"
]
},
"contentRating":{
},
"projection":"rectangular"
},
...but the embed player says that "This video is age-restricted and only available on YouTube" and as a result my app is embedding videos that are unplayable for some users.
In contentRating, I was expecting to find "ytRating": "ytAgeRestricted" but unfortunately this isn't true in some cases!
Is another (bulletproof) way to find out if the video is age restricted?
As per docs:
contentDetails.contentRating.ytRating
A rating that YouTube uses to identify age-restricted content.
But that doesn't seem to work as documented, here's the example: https://www.youtube.com/watch?v=IUc0wyae-WI
API response:
{
"items": [
{
"id": "U9x_WdDwATA",
"contentDetails": {
"contentRating": {},
},
}
]
}
Notice that contentRating.ytRating isn't set which means that the video doesn't have age-restriction according to API.
But actually it's not the case: https://www.youtube.com/embed/IUc0wyae-WI?hl=en
This video is age-restricted and only available on YouTube. Learn more
Watch on YouTube
Where's my mistake? Or is it the bug in YouTube API v3?
try to find playabilityStatus:
see for more details:
Use the YouTube API to check if a video is embeddable
This is undocumented API existing for long time, so exploring it is up
to developer. I am aware of "status" (ok/fail), "errorcode" (100 and
150 in my practice), "reason" (string description of error). I am
getting duration ("length_seconds") this way because oEmbed does not
provide this information (strange, but true) and I can hardly motivate
every employer to get keys from youTube to use official API
Description: Teams display wrong values in app static tab and 'what can i do' input command
For example,value 'élément' display '�l�ment',it seems that Teams can not recognize the char 'é'
Manifest Version: 1.5
Language: fr-fr
Manifest.json
{
//hide bot other message
"localizationInfo": {
"defaultLanguageTag": "en",
"additionalLanguages": [
{
"languageTag": "fr-fr",
"file": "fr-fr.json"
}
]
}
}
fr-fr.json
{
"$schema": "https://developer.microsoft.com/fr-fr/json-schemas/teams/v1.5/MicrosoftTeams.Localization.schema.json",
"name.short": "Test",
"name.full": "TestFullName",
"description.short": "short description example",
"description.full": "full description example",
"staticTabs[0].name": "Nouveautés",
"bots[0].commandLists[0].commands[0].title": "Restaurer élément",
"bots[0].commandLists[0].commands[0].description": "Restaurer élément for test",
}
This issue has been solved when I check the installer bot package.It seems that the App Studio can not recognize some words like 'é'. So close this issue!
#Lin's Master, for all the French regions, you need to set your "languageTag" = "fr". Please follow this documentation.
Im here to ask if it's possible to fully use youtube data api v3 with angular 2+, the documentation just have examples from javascript like authentication, playlist videos, insert a playlist and search of videos (samples)
I'm trying to upload a video, using parameter like:
(gapi.client as any).youtube.videos.insert({
"resource": {
// Video title and description
"snippet": {
"title": "Test",
"description": "Test video upload via YouTube API"
},
"status": {
"privacyStatus": "private"
}
},
"part": "snippet,status,id",
"media": {
"body": video
})
My problem is that even like this, it always return error 404 : "The request does not include the video content.", documentation says the videos needs to be video/* or application/octet-stream, and my video object is a File extended from Blob.
What could i'm possibly doing wrong?
If it's the video file, what I have to do to work?
PS: "(gapi.client as any).youtube" has this any, because youtube is not a property from the interface, its loaded.
Solved
I'm brazilian then I was searching portuguese documentation, that is quite poor, when changed to English, I found 2 archives cors_upload.js and upload_video.js JS samples in the documentation, converted then to typescript and now it works.
When you upload a video to YouTube you may get a Includes copyrighted content flag in the video manager. Then when you go and check the video you see a message under the "copyright" section:
You have x copyright claims on your video. and below this is a Details section displaying interesting information like:
"CONTENT","CLAIMANT","POLICY" and it shows the time region where this claimed content is located in the video. What i would like to know is if Youtube's or Google's API can give us this same information?
Try using Videos: list.
Send HTTP request using this format:
GET https://www.googleapis.com/youtube/v3/videos
If successful, this method returns a response body with this sample video resource:
"contentDetails": {
"licensedContent": boolean,
"regionRestriction": {
"allowed": [
string
],
"blocked": [
string
]
},
"status": {
"privacyStatus": string,
"publishAt": datetime,
"license": string,
"publicStatsViewable": boolean
}