Vimeo PHP SDK - 如何设置标题/描述?

时间:2017-10-24 20:05:08

标签: php vimeo vimeo-api

上传后,如何使用PHP在Vimeo中设置视频的标题/描述?

$uri = $lib->upload($localfile);
$video_data = $lib->request($uri);
if ($uri)
{
    $link = $video_data['body']['link'];
    $lib->request($uri, array('name' => 'Teste','description' => 'My upload by vimeo php api'), 'PATCH');
    echo "<br>Success $filename was sent to $link ";
}

1 个答案:

答案 0 :(得分:1)

你应该致电:

import pulp
vars = pulp.LpVariable.dicts("var",range(1000),0,None,pulp.LpContinuous)
coeffs = range(1000)
import time
start_time = time.time()
for n in range(1000):  #Ten times building an expression of 1000 elements
    #print n
    pulp.lpSum([coeffs[i] * vars[i] for i in range(1000)])
print("--- %s seconds ---" % (time.time() - start_time))

确保您的令牌已启用编辑范围。

有关范围的更多信息:https://developer.vimeo.com/api/authentication#supported-scopes