← All concepts

Concept

Predicates

The engine behind scheduling, and how to drive content from live data.

Every playlist in Screenly plays according to a rule. For most people that rule is a time window set in the dashboard. Underneath, it is a predicate, and the predicate engine is what lets scheduling react to live conditions, not only the clock.

These pages are for developers who want to go past the dashboard: what a predicate is, how the time-based ones work, and how to drive content from your own data.

Topics

3 topics · 5 min read
  1. 1 What a predicate is A predicate is a boolean rule that decides whether a playlist plays. Every playlist has one, and the engine checks it many times a second.
  2. 2 Writing predicates Predicates use time and date values in milliseconds, so they are usually generated in code rather than typed by hand.
  3. 3 Reacting to live data Predicates only evaluate time and date on the device. To react to external data, your code pushes an updated predicate to the Screenly API, which reaches an online screen over its live connection almost at once.
Start reading →