Playlists: creation, update, assignment
Endpoints of the playlist controller: list, card, creation, full-body update, binding to screens with the points field, copy with screens, deletion.
The playlistA set of files with a playback schedule that is assigned to screens or networks. controller creates and updates playlists (files with durations plus a schedule: dates, hours, weekdays, periodicity) and binds them to screens in one request via the points field. Base URL http://api.advision.digital, header Authorization: Bearer $ADV_T. The main rule: playlistA set of files with a playback schedule that is assigned to screens or networks./patch is sent with the full body, so first GET, then change, then write.
Method and path | What it does | Important |
|---|---|---|
| PlaylistA set of files with a playback schedule that is assigned to screens or networks. list | Response key is |
| One playlistA set of files with a playback schedule that is assigned to screens or networks. with files, schedule and screenA device running the Advision player that shows content; the cabinet calls it a media device. list | Fields |
| Create a playlistA set of files with a playback schedule that is assigned to screens or networks. | Body in the table below; |
| Update a playlistA set of files with a playback schedule that is assigned to screens or networks. | Same body as on creation, complete: omitted fields are reset (schedule, |
| Delete playlists: | Irreversible; screens lose this content |
| Copy together with all screens and channel layout | On large lists the gateway returns 504 after ~50 s, but the copy is created: do not retry, look for |
| Copy without screens | No parameter adds screens to the copy |
Body of playlist/post and playlist/patch
Minimal body: {"name": "Promo October", "category": null, "type": "BACKGROUND", "filesOrder": "ASC", "fromDate": "2026-10-01 00:00:00", "toDate": "2026-10-31 23:59:59", "fromTime": "08:00:00", "toTime": "22:00:00", "influencePlaylist field: Active goes on air, Passive is only stored.": "ACTIVE", "weekDays": [0,1,2,3,4,5,6], "files": [{"id": <FILE_ID>, "duration": 15}]}
Field | Type | Required | Note |
|---|---|---|---|
| string | yes | PlaylistA set of files with a playback schedule that is assigned to screens or networks. name |
| null or number | yes | Usually |
| string | yes |
|
| string | yes |
|
| datetime | yes | Validity period |
| time | yes | Playback hours within the day |
| time | no | Second playback windowA zone of the screen (A to G) with its own size, position and playlists.; returned by the API, pass it unchanged in a patch |
| array | yes | 0 = Sunday … 6 = Saturday. An empty array = the playlistA set of files with a playback schedule that is assigned to screens or networks. never enters the schedule |
| string | yes |
|
| number | for | Seconds between insert starts. Always pass it in a patch, otherwise the period is reset |
| number | yes | File from the media library |
| number | yes | Seconds on screenA device running the Advision player that shows content; the cabinet calls it a media device.; for video equals the clip length. Without it the request fails with |
| number | no | Screens to assign the playlistA set of files with a playback schedule that is assigned to screens or networks. to; the value fully replaces the list |
| various | no | Undocumented fields returned by the API; pass them from |
| various | no | Computed, do not send on write |
Create a playlist
curl: curl -s -X POST -H "Authorization: Bearer $ADV_T" -H "Content-Type: application/json" -d @playlistA set of files with a playback schedule that is assigned to screens or networks..json http://api.advision.digital/playlistA set of files with a playback schedule that is assigned to screens or networks./post, where playlistA set of files with a playback schedule that is assigned to screens or networks..json holds the body from the table. The response contains the id of the new playlistA set of files with a playback schedule that is assigned to screens or networks..
Python: body = {"name": "Promo October", "category": None, "type": "ADVERTISING", "filesOrder": "ASC", "fromDate": "2026-10-01 00:00:00", "toDate": "2026-10-31 23:59:59", "fromTime": "08:00:00", "toTime": "22:00:00", "weekDays": [0,1,2,3,4,5,6], "influencePlaylist field: Active goes on air, Passive is only stored.": "ACTIVE", "periodicity": 600, "files": [{"id": FILE_ID, "duration": 15}]}; pid = c.post("/playlistA set of files with a playback schedule that is assigned to screens or networks./post", json=body).json()["id"]
Bind a playlist to screens
Pass the screenA device running the Advision player that shows content; the cabinet calls it a media device. list in the points field of playlistA set of files with a playback schedule that is assigned to screens or networks./patch: one request for any number of screens (0.2–1 s); other playlists and the all-day background on the screens stay untouched. The playlistA set of files with a playback schedule that is assigned to screens or networks. always lands in channel 0; a channel field inside points is ignored.
Python: pl = c.get(f"/playlistA set of files with a playback schedule that is assigned to screens or networks./{pid}").json(); pl = pl.get("playlistA set of files with a playback schedule that is assigned to screens or networks.", pl); body = {k: v for k, v in pl.items() if k not in ("access", "points", "pointsTotal", "expiration")}; body["points"] = [{"id": POINT_ID_1}, {"id": POINT_ID_2}]; c.post(f"/playlistA set of files with a playback schedule that is assigned to screens or networks./patch/{pid}", json=body)
The points list is replaced entirely: send a subset and the remaining screens are unbound; omit points and the list stays as it was. Likewise, a patch with a narrowed points removes the playlistA set of files with a playback schedule that is assigned to screens or networks. from some screens. For screens that need the content in another channel use point/patch from the screens reference.
Replace a clip in a playlist that is already playing
Do not create a new playlistA set of files with a playback schedule that is assigned to screens or networks.: upload the new file version, read the playlistA set of files with a playback schedule that is assigned to screens or networks. with GET /playlistA set of files with a playback schedule that is assigned to screens or networks./<PLAYLISTA set of files with a playback schedule that is assigned to screens or networks._ID>, replace files[] with [{"id": <NEW_FILE_ID>, "duration": 15}] and send POST /playlistA set of files with a playback schedule that is assigned to screens or networks./patch/<PLAYLISTA set of files with a playback schedule that is assigned to screens or networks._ID> with the whole body. The playlistA set of files with a playback schedule that is assigned to screens or networks. stays on all screens and the content updates everywhere after sync.
Copy a playlist
curl: curl -s -X POST -H "Authorization: Bearer $ADV_T" http://api.advision.digital/playlistA set of files with a playback schedule that is assigned to screens or networks./copy-with-screens/<PLAYLISTA set of files with a playback schedule that is assigned to screens or networks._ID> creates a copy with screens and channels (the cabinet calls it «Copy with devices»). The "template" pattern: keep a sample playlistA set of files with a playback schedule that is assigned to screens or networks. with the right screenA device running the Advision player that shows content; the cabinet calls it a media device.-to-channel layout, copy it and patch the copy with new files and a narrowed points: two requests instead of hundreds.
Related articles
- How-to · 5 minGet a token and make the first requestWhere to create an API token in the cabinet, how to pass it in the Authorization header and verify it with /user/info.
- ReferenceScreens: reading, schedule, statusesEndpoints of the point controller: screen list and card, daily schedule, content assignment, screen capture, device control, networks.
- ConceptTypical scenarios and pitfallsThe four-step rule (read, back up, write, re-read), patch request pitfalls and ready request sequences for typical tasks.
- ConceptWhat a playlist is and how it reaches the screenA playlist is files plus playback rules. Content appears on the screen after the playlist is assigned and the screen syncs.