Carlos Pisarello
Carlos Pisarello

Reputation: 1284

Get all videos uploaded by my account with a specific tag Vimeo API

I need to get all the videos uploaded by me that contains a specific tag, i'm currently using the Node.js SDK with the current method:

vimeo.request({
    method: 'GET',
    path: '/me/videos'
  }, function (error, body, status_code, headers) {
    if (error) {
      console.log(error)
    }
    console.log(body)
})

And it returns all the videos uploaded on my account succesfully, but i don't know how to get all my videos with the tag 'reel', for example.

Upvotes: 0

Views: 1115

Answers (2)

user6735654
user6735654

Reputation: 33

Old question, but now there is a way to filter or query

curl -X GET 'https://api.vimeo.com/me/videos?filter_tag=yourtag' 
  -H 'Accept: application/vnd.vimeo.*+json;version=3.4' 
  -H 'Authorization: bearer [token]'

or

curl -X GET 'https://api.vimeo.com/me/videos?query=yourtag&query_fields=tags' 
  -H 'Accept: application/vnd.vimeo.*+json;version=3.4' 
  -H 'Authorization: bearer [token]'

Upvotes: 0

Tommy Penner
Tommy Penner

Reputation: 3018

Unfortunately it's not possible to specify a tag and get all videos on an account with that tag. You can only get all public videos on Vimeo with a specified tag.

You can make a request to /me/videos and use the fields parameter to return only the tag metadata, and then iterate through the list to get only the tags you require.

That request might look something like this:

curl -X GET 'https://api.vimeo.com/me/videos?fields=uri,tags' 
  -H 'Accept: application/vnd.vimeo.*+json;version=3.4' 
  -H 'Authorization: bearer [token]' 

https://developer.vimeo.com/api/common-formats#json-filter

Upvotes: 1

Related Questions