gleetube/resource/playlists
Types
Filter for playlists.list.
pub type PlaylistFilter {
ByChannelId(channel_id: String)
ById(ids: List(String))
Mine
}
Constructors
-
ByChannelId(channel_id: String) -
ById(ids: List(String)) -
Mine
Valid part values for the playlists resource.
pub type PlaylistPart {
ContentDetails
Id
Localizations
Player
Snippet
Status
}
Constructors
-
ContentDetails -
Id -
Localizations -
Player -
Snippet -
Status
Values
pub fn delete(
client: client.Client,
playlist_id playlist_id: String,
on_behalf_of_content_owner on_behalf_of_content_owner: option.Option(
String,
),
) -> Result(Nil, error.GleeTubeError)
Delete a playlist.
pub fn insert(
client: client.Client,
parts parts: List(PlaylistPart),
body body: json.Json,
on_behalf_of_content_owner on_behalf_of_content_owner: option.Option(
String,
),
on_behalf_of_content_owner_channel on_behalf_of_content_owner_channel: option.Option(
String,
),
) -> Result(playlist.Playlist, error.GleeTubeError)
Insert a new playlist.
pub fn list(
client: client.Client,
parts parts: List(PlaylistPart),
filter filter: PlaylistFilter,
hl hl: option.Option(String),
max_results max_results: option.Option(Int),
on_behalf_of_content_owner on_behalf_of_content_owner: option.Option(
String,
),
on_behalf_of_content_owner_channel on_behalf_of_content_owner_channel: option.Option(
String,
),
page_token page_token: option.Option(String),
) -> Result(playlist.PlaylistListResponse, error.GleeTubeError)
List playlists matching the given filter.
pub fn list_all(
client: client.Client,
parts parts: List(PlaylistPart),
filter filter: PlaylistFilter,
hl hl: option.Option(String),
on_behalf_of_content_owner on_behalf_of_content_owner: option.Option(
String,
),
on_behalf_of_content_owner_channel on_behalf_of_content_owner_channel: option.Option(
String,
),
) -> Result(List(playlist.Playlist), error.GleeTubeError)
Fetch all playlists across all pages.
pub fn update(
client: client.Client,
parts parts: List(PlaylistPart),
body body: json.Json,
on_behalf_of_content_owner on_behalf_of_content_owner: option.Option(
String,
),
) -> Result(playlist.Playlist, error.GleeTubeError)
Update a playlist.