我正在使用官方的Vimeo PHP客户端。我可以上传视频,并将其设置privacy.embed为whitelist。然后文档告诉我:要将域添加到白名单,请向发送PUT请求/videos/{video_id}/privacy/domains/{domain}。我试过了$privacy_uri = $uri . "/privacy/domains/testdomain.tld";$domain_add_response = $client->request($privacy_uri);哪里-$uri是/vimeo/<video_id> -$client 出生于new Vimeo(CLIENT_ID, CLIENT_SECRET, VIMEO_TOKEN);问题打印$domain_add_response我得到一个405错误,可能是由于Allow(请参阅以下响应转储)Array( [body] => [status] => 405 [headers] => Array ( [Server] => nginx [Content-Type] => application/json [Allow] => PUT,DELETE,OPTIONS [X-Vimeo-DC] => ge [Accept-Ranges] => bytes [Via] => 1.1 varnish [Content-Length] => 0 [Date] => Mon, 15 Apr 2019 08:30:47 GMT [Connection] => keep-alive [X-Served-By] => cache-bwi5125-BWI, cache-mxp19820-MXP [X-Cache] => MISS, MISS [X-Cache-Hits] => 0, 0 [X-Timer] => S1555317047.232635,VS0,VE148 [Vary] => Accept-Encoding ))我想我必须PUT 在请求中设置方法,但是...如何?
1 回答
- 1 回答
- 0 关注
- 162 浏览
添加回答
举报
0/150
提交
取消