0
透過YouTube API v3和PHP您可以輕鬆地訂閱頻道。的YouTube API V3 PHP - 退訂?
$resourceId = new Google_Service_YouTube_ResourceId();
$resourceId->setChannelId($_GET['id']);
$resourceId->setKind('youtube#user');
$subscriptionSnippet = new Google_Service_YouTube_SubscriptionSnippet();
$subscriptionSnippet->setResourceId($resourceId);
$subscription = new Google_Service_YouTube_Subscription();
$subscription->setSnippet($subscriptionSnippet);
$subscriptionResponse = $youtube->subscriptions->insert('id,snippet',
$subscription, array());
但是我如何取消訂閱頻道?它不記錄
這是爲了這個,我發現的唯一的幫助,但它並沒有說如何使用PHP API做到這一點:https://developers.google.com/youtube/v3/docs/subscriptions/delete