I want to get a logged in user's private YouTube video details using the v3 API. I have already extended my Google Oauth authentication with YouTube scope. The login process was success. The owner of the private video is the logged in user.
However if I use the following request I got a valid success message but with a 0 result.
My request:
https://www.googleapis.com/youtube/v3/videos?part=contentDetails,snippet&id=VIDEO_ID&key=API_KEY
Response:
{
"kind": "youtube#videoListResponse",
"etag": "\"xxxxxxxxxxxxxxxxxxxxxxxxxxxxx\"",
"pageInfo": {
"totalResults": 0,
"resultsPerPage": 0
},
"items": []
}
Any idea what can be the problem?
Finally I have found the problem. The Google OAuth access token was not part of the request header. After including it in the request the response gave me the correct result.