Story Playlists
Preview a story playlist filter
POST
https://api.tunio.ai/ v1/ story-playlists/ previewThe stories a filter playlist would air, before it is saved, a page at a time. Only filter is read from the body.
Query parameters
| Name | Type | Description |
|---|---|---|
| cursor | string | next_cursor from the previous page |
| limit | integer | Page size, 1-100; other values fall back to 30 |
Request body
The filter (title, kind, intro_uuid and outro_uuid are not needed)
| Name | Type | Description |
|---|---|---|
| filter | object | Picks the stories of a filter playlist; absent or empty fields do not narrow. Ignored for a
manual playlist. |
| age_max | integer | Highest age rating of the stories: 0, 6, 12, 16 or 18, not below age_min; absent for no
upper bound. |
| age_min | integer | Lowest age rating of the stories: 0, 6, 12, 16 or 18; absent for no lower bound. |
| category | string | Category slug (lowercase letters, digits and dashes, up to 40), as in the story library;
absent or empty for any. |
| duration_max | integer | Longest story to take, in seconds, 60-36000; absent or 0 for any length. |
| language | string | Language code such as en or pt-BR; absent or empty for any. |
| intro_uuid | string | UUID of a file of the caller's library aired before a slot's stories; null or empty for none. |
| kind | string | manual (stories added one by one, in order) or filter (every story matching filter). Set on
create only; the kind of a playlist does not change. |
| outro_uuid | string | UUID of a file of the caller's library aired after a slot's stories; null or empty for none. |
| title | string | Title of the playlist, 1-200 characters. |
Request example
01{02 "filter": {03 "age_max": 12,04 "age_min": 0,05 "category": "fantasy",06 "duration_max": 1800,07 "language": "en"08 },09 "intro_uuid": "",10 "kind": "filter",11 "outro_uuid": "",12 "title": "Bedtime stories"13}
Responses
| Name | Type | Description |
|---|---|---|
| next_cursor | string | Cursor of the next page, null on the last page. |
| stories | array | One page of stories. |
| [item]Required | object | - |
| success | boolean | Always true on success. |
| total | integer | How many stories match in all. |
| Name | Type | Description |
|---|---|---|
| message | string | Error code or human-readable error details. |
| success | boolean | Always false for error payloads. |
| Name | Type | Description |
|---|---|---|
| message | string | Error code or human-readable error details. |
| success | boolean | Always false for error payloads. |
| Name | Type | Description |
|---|---|---|
| message | string | Error code or human-readable error details. |
| success | boolean | Always false for error payloads. |
| Name | Type | Description |
|---|---|---|
| message | string | Error code or human-readable error details. |
| success | boolean | Always false for error payloads. |
| Name | Type | Description |
|---|---|---|
| message | string | Error code or human-readable error details. |
| success | boolean | Always false for error payloads. |
| Name | Type | Description |
|---|---|---|
| message | string | Error code or human-readable error details. |
| success | boolean | Always false for error payloads. |