Cron

The cron extension works with cron formatted strings to create time based triggers. The cron extension is a great way to scheduling operations around time.

This extension does not take an extension level config and is focused on interfaces.


Trigger Interface

Provides a trigger that checks the current time against a cron string.

OptionTypeRequiredDescription
key[String]YesUnique slug id for the component
schedule[String]YesCron string to check time against. i.e. */2 * * * *
name[String]NoFriendly display name of component. Useful for UI.
actions[List]NoList of registered actions to fire.

Config Examples

Here is a config of a complete cron trigger.

"trigger": [{
    "key": "cron_trigger_1",
    "name": "Every 2 Mins"
    "interface": "cron",
    "schedule": "*/2 * * * *",
    "actions": [".example_toggle.turn_on"]
}]

The configuration above would turn_on a example_toggle every 2 minutes.