【发布时间】:2017-03-15 11:14:21
【问题描述】:
如何获取每个视频的不喜欢和喜欢?我在文档中找不到它
$youtube = new Google_Service_YouTube($client);
$searchResponse = $youtube->search->listSearch('id,snippet', array(
'type' => 'video',
'channelId' => 'UCCQeAYn0EfUNp2-RpJKbG5Q'
));
foreach($searchResponse['items'] as $result) {
$videoID = $result['modelData']['id']['videoId'];
$thumb = $result['modelData']['snippet']['thumbnails']['high']['url'];
$title = $result['modelData']['snippet']['title'];
$description = $result['modelData']['snippet']['description'];
// likes
}
【问题讨论】:
标签: php youtube google-api google-api-php-client youtube-data-api