Schedule Profiles

Save a stream's schedule as a profile

POST
https://api.tunio.ai/v1/schedule-profiles

Captures the stream's current music and/or content schedule into a new private profile of the caller's library, with self-contained playlist snapshots. Apply it later with POST /v1/schedule-profiles/{profile_id}/apply, for example to roll a schedule back.

Request body

Stream and profile name

NameTypeDescription
layersarray
What to capture: music, content, or both (default both when absent or empty).
[item]Requiredstring
-
nameRequiredstring
Display name of the profile.
stream_idRequiredstring
UUID of the stream whose schedule is captured; it must be the caller's.
Request example
01{
02 "layers": [
03 "music",
04 "content"
05 ],
06 "name": "Before holiday changes",
07 "stream_id": "5a0c8a52-2f7e-4c1b-8d3e-9f0a1b2c3d4e"
08}

Responses

NameTypeDescription
profileobject
The profile.
content_slotsinteger
Number of content slots stored in the profile.
created_atstring (date-time)
When the profile was first saved (RFC3339).
has_contentboolean
Whether the profile carries a content schedule layer; a stored but empty layer clears the stream's content schedule on apply.
has_musicboolean
Whether the profile carries a music schedule layer at all, which music_slots cannot tell: a stored but empty layer clears the stream's music schedule on apply.
is_auto_snapshotboolean
true for a snapshot taken automatically before a schedule replace (PUT); only the last 20 per stream are kept. Always false in the public catalog.
music_slotsinteger
Number of music slots stored in the profile.
namestring
Display name of the profile.
profile_idstring
UUID of the profile.
updated_atstring (date-time)
When the profile was last overwritten or renamed (RFC3339).
successboolean
Always true on success.
NameTypeDescription
messagestring
Error code or human-readable error details.
successboolean
Always false for error payloads.
NameTypeDescription
messagestring
Error code or human-readable error details.
successboolean
Always false for error payloads.
NameTypeDescription
messagestring
Error code or human-readable error details.
successboolean
Always false for error payloads.
NameTypeDescription
messagestring
Error code or human-readable error details.
successboolean
Always false for error payloads.
NameTypeDescription
messagestring
Error code or human-readable error details.
successboolean
Always false for error payloads.