Open aproni34f opened 2 years ago
You need to use an access token authenticated to your user with the private
scope to access private videos.
This also means you cannot pass the access token by the ?access_token query parameter.
You can generate a new access token on the developer site, https://developer.vimeo.com/, and access private videos in the showcase using
GET https://api.vimeo.com/users/USER_ID/albums/ALBUM_ID/videos
with headers
Authorization: bearer <the_token_generated>
I am actually using vimeo php library: https://github.com/vimeo/vimeo.php
$vimeo->request("/users/$user_id/albums/$album_id/videos");
But I am not talking about private video, but Hide from Vimeo videos:
https://vimeo.zendesk.com/hc/en-us/articles/224817847-Manage-your-video-s-privacy-settings
This applies to both hide from Vimeo and private videos.
The PHP library will automatically add the authentication header for you, but you do need to use a private, authenticated token. You also can't pass the token via query string - in the PHP library, you need to use, ex,
$client = new Vimeo(client_id, client_secret, access_token);
$client->request('/users/USER_ID/albums/ALBUM_ID/videos');
You will only see hide from Vimeo videos if the access token is authenticated to the user who owns the videos.
I do use it like this, but for token, I just generated new token with :
private public
scopes but I still get empty results.
Btw, this is my clients album I am trying to view, and he has higher user privileges. I am just basic user. Will this work? Or only album users can see hidden videos?
Only users who have permission to see the videos will have access to them.
You'll need to use either a token authenticated to the owner, or authenticated to some other user that has access to view them.
How other user (in this case me) gets access to view them?
They can add you as a team member and grant you permission to either the folder or the videos they would like you to have access to.
There are some docs available on managing teams, https://vimeo.zendesk.com/hc/en-us/articles/224818687-Add-and-remove-team-members-on-your-account, but if they have issues they should reach out to support https://vimeo.com/help/contact.
I have a showcase with videos hidden in privacy settings.
When I try to query to get all videos I get empty response.
https://api.vimeo.com/users/USER_ID/albums/ALBUM_ID/videos?access_token=TOKEN
I just get empty results.
Is api not meant to return hidden videos?