CreatePlayRequest
Body for POST /play, which reserves the next track for a client. Give
a station_id to play a specific station, a placement_id to let the
server pick within a placement, or an audio_file_id to request a
specific track on an on-demand station.
The client this play belongs to. Required, but may instead arrive as
a cid cookie or a client_id query parameter — see Identifying a
client. Values longer than 23 characters are silently truncated.
Possible values: <= 23 characters
The placement to pull from. Defaults to the credentials' default placement when omitted.
The station to pull from. Defaults to the placement's default station when omitted.
Request a specific audio file. Only honoured for on-demand and
replay stations; asking on a radio station gives
notOnDemandOrReplay (code 23).
Comma-separated list of acceptable codecs, in preference order, e.g.
aac,mp3. Valid codecs are mp3 and aac. If none of the
requested formats exist for the selected track the call reports
formatUnavailable (code 24) — which is delivered as HTTP 200 with
success: false.
mp3Upper bound on the delivered bitrate, in kbps. The server picks the highest available file at or below this value.
Crossfade duration in seconds to apply to this play, overriding the
station's configured value. Read only when at is also supplied
— sent on its own it is ignored, with no error and nothing in the
response to say so.
When true, create a preview play rather than a reportable one. The
resulting audio_file carries preview: true.
falseRequest the song that should play at this seconds offset within the
station. Only meaningful for stations that allow seeking; surfaces
as start_at on the returned play.
{
"client_id": "FgT1_Yzvr_e05ANk2uCYdZi",
"station_id": "727",
"formats": "aac,mp3",
"max_bitrate": 128
}