Show / Hide Table of Contents

Class PlaylistsResource

The "playlists" collection of methods.

Inheritance
System.Object
PlaylistsResource
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Google.Apis.YouTube.v3
Assembly: Google.Apis.YouTube.v3.dll
Syntax
public class PlaylistsResource

Constructors

PlaylistsResource(IClientService)

Constructs a new resource.

Declaration
public PlaylistsResource(IClientService service)
Parameters
Type Name Description
IClientService service

Methods

Delete(String)

Deletes a playlist.

Declaration
public virtual PlaylistsResource.DeleteRequest Delete(string id)
Parameters
Type Name Description
System.String id

The id parameter specifies the YouTube playlist ID for the playlist that is being deleted. In a playlist resource, the id property specifies the playlist's ID.

Returns
Type Description
PlaylistsResource.DeleteRequest

Insert(Playlist, String)

Creates a playlist.

Declaration
public virtual PlaylistsResource.InsertRequest Insert(Playlist body, string part)
Parameters
Type Name Description
Playlist body

The body of the request.

System.String 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.

Returns
Type Description
PlaylistsResource.InsertRequest

List(String)

Returns a collection of playlists that match the API request parameters. For example, you can retrieve all playlists that the authenticated user owns, or you can retrieve one or more playlists by their unique IDs.

Declaration
public virtual PlaylistsResource.ListRequest List(string part)
Parameters
Type Name Description
System.String part

The part parameter specifies a comma-separated list of one or more playlist 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 playlist resource, the snippet property contains properties like author, title, description, tags, and timeCreated. As such, if you set part=snippet, the API response will contain all of those properties.

Returns
Type Description
PlaylistsResource.ListRequest

Update(Playlist, String)

Modifies a playlist. For example, you could change a playlist's title, description, or privacy status.

Declaration
public virtual PlaylistsResource.UpdateRequest Update(Playlist body, string part)
Parameters
Type Name Description
Playlist body

The body of the request.

System.String 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.

Note that this method will override the existing values for mutable properties that are contained in any parts that the request body specifies. For example, a playlist's description is contained in the snippet part, which must be included in the request body. If the request does not specify a value for the snippet.description property, the playlist's existing description will be deleted.

Returns
Type Description
PlaylistsResource.UpdateRequest
Back to top