Episode

@Serializable
data class Episode(val audioPreviewUrl: String? = null, val description: String? = null, val durationMs: Int, val explicit: Boolean, externalUrlsString: Map<String, String>, val href: String, val id: String, val images: List<SpotifyImage>? = null, val isExternallyHosted: Boolean, val isPlayable: Boolean, language: String? = null, showLanguagesPrivate: List<String>, val name: String, releaseDateString: String? = null, val releaseDatePrecisionString: String? = null, val resumePoint: ResumePoint? = null, val show: SimpleShow, val type: String, val uri: EpisodeUri) : CoreObject, Playable(source)

An episode (podcast) on Spotify

Parameters

audioPreviewUrl

A URL to a 30 second preview (MP3 format) of the episode. null if not available.

description

A description of the episode.

durationMs

The episode length in milliseconds.

explicit

Whether or not the episode has explicit content (true = yes it does; false = no it does not OR unknown).

images

The cover art for the episode in various sizes, widest first.

isExternallyHosted

True if the episode is hosted outside of Spotify’s CDN.

isPlayable

True if the episode is playable in the given market. Otherwise false.

name

The name of the episode.

releaseDatePrecisionString

The precision with which release_date value is known: "year", "month", or "day".

resumePoint

The user’s most recent position in the episode. Set if the supplied access token is a user token and has the scope SpotifyScope.UserReadPlaybackPosition.

type

The object type: "episode".

show

The show on which the episode belongs.

Constructors

Link copied to clipboard
constructor(audioPreviewUrl: String? = null, description: String? = null, durationMs: Int, explicit: Boolean, externalUrlsString: Map<String, String>, href: String, id: String, images: List<SpotifyImage>? = null, isExternallyHosted: Boolean, isPlayable: Boolean, language: String? = null, showLanguagesPrivate: List<String>, name: String, releaseDateString: String? = null, releaseDatePrecisionString: String? = null, resumePoint: ResumePoint? = null, show: SimpleShow, type: String, uri: EpisodeUri)

Properties

Link copied to clipboard
@Transient
lateinit var api: GenericSpotifyApi

The API client associated with the request

Link copied to clipboard

This Playable as a local track, or else null if it is an episode or track.

Link copied to clipboard

This Playable as an episode (podcast), or else null if it is a local track or track.

Link copied to clipboard
open val asTrack: Track?

This Playable as a track, or else null if it is a local track or episode (podcast).

Link copied to clipboard
@SerialName(value = "audio_preview_url")
val audioPreviewUrl: String? = null
Link copied to clipboard
val description: String? = null
Link copied to clipboard
@SerialName(value = "duration_ms")
val durationMs: Int
Link copied to clipboard
Link copied to clipboard

Known external URLs for this object

Link copied to clipboard
open override val href: String

A link to the Spotify web api endpoint associated with this request

Link copied to clipboard
open override val id: String

The Spotify id of the associated object

Link copied to clipboard
val images: List<SpotifyImage>? = null
Link copied to clipboard
@SerialName(value = "is_externally_hosted")
val isExternallyHosted: Boolean
Link copied to clipboard
@SerialName(value = "is_playable")
val isPlayable: Boolean
Link copied to clipboard

A list of the languages used in the episode, identified by their ISO 639 code.

Link copied to clipboard
Link copied to clipboard

The date the episode was first released, for example "1981-12-15". Depending on the precision, it might be shown as "1981" or "1981-12".

Link copied to clipboard
@SerialName(value = "release_date_precision")
val releaseDatePrecisionString: String? = null
Link copied to clipboard
@SerialName(value = "resume_point")
val resumePoint: ResumePoint? = null
Link copied to clipboard
Link copied to clipboard
open override val type: String
Link copied to clipboard
open override val uri: EpisodeUri

The URI associated with the object

Functions