Templates
Tools for managing templates. A template is a multi-zone layout that defines content areas on the screen — each zone can display a different playlist, web page, or media item simultaneously. Templates also support JavaScript scripting for interactive or dynamic content.
list_templates
List all templates in the account. Returns template objects with id, name, group assignment, and zone configuration.
| Parameter | Type | Required | Description |
|---|---|---|---|
group_id |
string or string[] | No | Filter by template group ID(s) |
group_name |
string or string[] | No | Filter by template group name(s) |
take |
number | No | Results per page |
page |
number | No | Page number (1-based) |
get_template
Get a template by ID including its full zone definitions and scripting. Returns the template’s name, dimensions, group, and an array of zones where each zone defines a screen region with position, size, and content assignment.
| Parameter | Type | Required | Description |
|---|---|---|---|
id |
string | Yes | The template ID |
Creating templates
There is no create_template tool. The API exposes no way to create a template: swagger lists only GET for /templates (no POST), and the GraphQL schema has updateTemplate but no createTemplate. Create templates in the Revel Digital web UI; the API can then read, update and delete them.
update_template
Update a template’s own properties: name, group, dimensions, orientation, tags, background color and script. Only include fields you want to change.
This does not edit zones/modules — the request body has no zones field. Use add_template_module, update_template_module, remove_template_module, reorder_template_modules or batch_update_template_modules for the layout.
| Parameter | Type | Required | Description |
|---|---|---|---|
id |
string | Yes | The template ID |
name |
string | No | Updated name |
group_id |
string | No | Move to this group |
width |
number | No | Updated canvas width |
height |
number | No | Updated canvas height |
orientation |
0 | 90 | 180 | 270 | No | Display orientation — see below |
tags |
string | No | Newline-delimited tags |
script |
string | No | Template script for custom logic |
back_color |
string | No | Background color, e.g. #000000 |
Orientation
orientation is degrees of rotation, not an index:
| Value | Meaning |
|---|---|
0 |
Landscape |
90 |
Portrait |
180 |
Landscape Reversed |
270 |
Portrait Reversed |
1, 2 and 3 are invalid. (The schema documented them as 0-3 before September 2026; live data only ever holds 0, 90, 180 or 270.)
delete_template
Permanently delete a template and its zones/modules. Cannot be undone, and the API cannot recreate a template — only the web UI can. Schedules and playlists referencing this template will have invalid references, so repoint them first.
| Parameter | Type | Required | Description |
|---|---|---|---|
id |
string | Yes | The template ID |
Template Modules / Zones
The following tools edit individual modules (zones) within a template without resending the whole zones array. They are GraphQL-backed — REST’s update_template can only replace the entire zone list at once. “Module” and “zone” are used interchangeably. Module options are type-specific key-value settings (e.g. timezone for a Clock zone, location for a Weather zone).
add_template_module
Add a module/zone to an existing template.
| Parameter | Type | Required | Description |
|---|---|---|---|
templateId |
string | Yes | The template ID to add the module/zone to |
module |
object | Yes | Module/zone definition: name, type (e.g. Playlist, Clock, Weather, Ticker, Web), left, top, width, height (pixels), playlistId, sequence (z-order). See introspect_schema typeName ModuleInput |
update_template_module
Update a single module/zone (reposition, resize, or reassign its playlist). Only include fields you want to change.
| Parameter | Type | Required | Description |
|---|---|---|---|
templateId |
string | Yes | The template ID containing the module/zone |
moduleId |
string | Yes | The module/zone ID to update |
name |
string | No | Updated name |
type |
string | No | Updated type |
left / top |
number | No | Position in pixels |
width / height |
number | No | Size in pixels |
playlistId |
string | No | Playlist assigned to this zone |
sequence |
number | No | Z-order (higher appears in front) |
remove_template_module
Remove a single module/zone by ID.
| Parameter | Type | Required | Description |
|---|---|---|---|
templateId |
string | Yes | The template ID containing the module/zone |
moduleId |
string | Yes | The module/zone ID to remove |
reorder_template_modules
Reorder modules/zones by setting each module’s sequence (z-order).
| Parameter | Type | Required | Description |
|---|---|---|---|
templateId |
string | Yes | The template ID |
moduleSequences |
array | Yes | Each entry: { moduleId, sequence } — the new z-order for that module/zone |
batch_update_template_modules
Update multiple modules/zones in one call (e.g. apply a whole new layout). Each entry targets one module by ID and carries only the fields to change.
| Parameter | Type | Required | Description |
|---|---|---|---|
templateId |
string | Yes | The template ID |
modules |
array | Yes | Module/zone updates, each { moduleId, ...fields } (same fields as update_template_module) |
set_module_options
Set ALL configuration options for a module/zone, replacing any existing options. To change one option without touching the others, use upsert_module_option.
| Parameter | Type | Required | Description |
|---|---|---|---|
templateId |
string | Yes | The template ID |
moduleId |
string | Yes | The module/zone ID |
options |
array | Yes | Complete set of { name, value } options (replaces all existing) |
upsert_module_option
Add or update a single module/zone option, matched by name, leaving the others untouched.
| Parameter | Type | Required | Description |
|---|---|---|---|
templateId |
string | Yes | The template ID |
moduleId |
string | Yes | The module/zone ID |
option |
object | Yes | The { name, value } option to add or update |
remove_module_option
Remove a single module/zone option by name.
| Parameter | Type | Required | Description |
|---|---|---|---|
templateId |
string | Yes | The template ID |
moduleId |
string | Yes | The module/zone ID |
optionName |
string | Yes | The name/key of the option to remove |