我想使用视频ID(我的帐户是Pro)请求我的私人视频文件。但是我不知道如何在请求中认证我的帐户。
这就是我所做的!
GET https://api.vimeo.com/videos/{video_id}
身体
{
"grant_type": "client_credentials"
}
标题
"Authorization" : "bearer {access_token}"
"Accept" : "application/vnd.vimeo.user+json;version=3.0,application/vnd.vimeo.video+json;version=3.4"
"Content-Type" : "application/json"
这是对此的追问。
{
"error": "Something strange occurred. Please contact the app owners.",
"link": null,
"developer_message": "No user credentials were provided.",
"error_code": 8003
}
答案 0 :(得分:0)
您正在生成client_credentials
令牌,该令牌只能在Vimeo上检索公共数据。相反,您需要通过OAuth工作流或Vimeo开发人员站点上的个人访问令牌来生成经过身份验证的令牌。这里有更多信息:
https://developer.vimeo.com/api/authentication#using-the-auth-code-grant-step-1 https://developer.vimeo.com/api/guides/start/#generate-access-token
答案 1 :(得分:0)
添加新的APP后,从您的帐户生成access_token。
然后在URL中或作为参数传递access_token
例如https://api.vimeo.com/videos?access_token=***********************&links=https://vimeo.com/29474908