class Subscriptions extends Resource (View source)

The "subscriptions" collection of methods.

Typical usage is:

 $youtubeService = new Google\Service\YouTube(...);
 $subscriptions = $youtubeService->subscriptions;

Methods

delete(string $id, array $optParams = [])

Deletes a resource. (subscriptions.delete)

insert(string|array $part, Subscription $postBody, array $optParams = [])

Inserts a new resource into this collection. (subscriptions.insert)

listSubscriptions(string|array $part, array $optParams = [])

Retrieves a list of resources, possibly filtered.

Details

delete(string $id, array $optParams = [])

Deletes a resource. (subscriptions.delete)

Parameters

string $id
array $optParams

Optional parameters.

Exceptions

Exception

Subscription insert(string|array $part, Subscription $postBody, array $optParams = [])

Inserts a new resource into this collection. (subscriptions.insert)

Parameters

string|array $part

The part parameter serves two purposes in this operation. It identifies the properties that the write operation will set as well as the properties that the API response will include.

Subscription $postBody
array $optParams

Optional parameters.

Return Value

Subscription

Exceptions

Exception

SubscriptionListResponse listSubscriptions(string|array $part, array $optParams = [])

Retrieves a list of resources, possibly filtered.

(subscriptions.listSubscriptions)

Parameters

string|array $part

The part parameter specifies a comma-separated list of one or more subscription resource properties that the API response will include. If the parameter identifies a property that contains child properties, the child properties will be included in the response. For example, in a subscription resource, the snippet property contains other properties, such as a display title for the subscription. If you set part=snippet, the API response will also contain all of those nested properties.

array $optParams

Optional parameters.

Return Value

SubscriptionListResponse

Exceptions

Exception