Vimeo API php连接问题

时间:2016-01-15 20:30:15

标签: php api get request vimeo

我正在使用Vimeo API尝试显示我的视频。我在developer.vimeo.com/apps/上设置了一个应用程序,同时还为应用程序创建了身份验证令牌。我已经下载并包含了发现here的Vimeo-Php API,但我仍然没有运气显示任何内容,更不用说特定的视频,群组等了。我已经发布了在Github上推荐的简单步骤来验证Vimeo因为我相信我在路上遗漏了一些东西。

/*includeds at the top of my file */ 
include("../vimeo/autoload.php");

//following variables from developer.vimeo.com/apps/MYAPPID
$client_id = 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
$client_secret = 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';
$clientToken = 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX';

$lib = new Vimeo($client_id, $client_secret, $clientToken);
$search_results = $lib->request('/videos', array('page' => 1, 'per_page' => 50, 'query' => urlencode($_GET['query']), 'sort' => 'relevant', 'direction' => 'desc', 'filter' => 'CC'));
return $search_results;

0 个答案:

没有答案