How to schedule a time-based workflow
A time-based Smart Workflow runs at set times instead of waiting for a sensor reading. Use it to switch devices on or off at fixed times, or to submit a recurring work request.
Quick Summary
Click Smart Workflows, then New workflow. Choose Time-based and click Continue. Set the Run schedule, add an action, then click Create & activate.
Before you begin
- Smart Workflows is in the sidebar under Work for Facility Owners and Organization Admins.
- To queue device commands, the device's Asset Type needs named commands. See How to send device commands.
- To submit work requests, you need a request template. See Raise a work order automatically.
- For planned maintenance on assets, PM schedules are usually the better tool. Use a time-based workflow for device control or a simple recurring request.
Step 1: Start a time-based workflow
- From the sidebar, click Smart Workflows.
- Click New workflow.
- Choose Time-based ("Trigger on a fixed schedule") and click Continue.
- Enter a name in the Schedule name... box, such as
Lobby lights off at night. - Optional: open Details to add a Description and Tags.
Step 2: Set the run schedule
Under Run schedule ("Define when this workflow triggers automatically."), choose one option:
| Option | Fields |
|---|---|
| Once | Date and Time |
| Daily | Time each day |
| Weekly | Day of week and Time |
| Monthly | Day of month (1-31) and Time |
| Custom (Cron) | Cron expression, in the format "minute hour day-of-month month day-of-week" |
For Custom (Cron), enter one minute from 0 to 59 and one hour from 0 to 23. Keep the month field as *. You can specify days of the month or days of the week, with the other field set to *. Use 0 for Sunday through 6 for Saturday.
The Timezone is your organization's timezone and cannot be changed here. Check the Schedule preview: line, such as "Every day at" followed by your time, before you save.
Step 3: Add actions
Under Trigger these actions, click Add action and choose an Action Type. Time-based workflows offer two:
| Action Type | What it does | Fields |
|---|---|---|
| Trigger IoT assets | Queues a named command for a device | IoT Asset, Command |
| Submit request | Creates a work request from a request template | Request Template |
Email, SMS and alarm actions are only available in condition-based workflows. "Scheduled workflows cannot add staff alerts."
Step 4: Save
- Create & activate saves the schedule and turns it on.
- Save as draft saves it without turning it on.
Example: switch lobby lights off every evening
Situation: The lobby lighting relay Lobby lighting relay has a named command Lights Off. You want it sent at 22:00 every day.
- Click Smart Workflows, then New workflow. Choose Time-based and click Continue.
- Name it
Lobby lights off at night. - Under Run schedule, choose Daily and set Time each day to
22:00. - Click Add action, choose Trigger IoT assets, click + Select IoT asset, pick
Lobby lighting relayand set Command toLights Off. - Click Create & activate.
Result: Every evening at 22:00 Infodeck queues Lights Off for the relay. A queued command is not confirmed as delivered, so check the lights on the first evening.
Example: monthly fire extinguisher check request
Situation: You want a request on the first day of each month to check the extinguishers in Main Building.
- Create a time-based workflow named
Monthly extinguisher check. - Choose Monthly, set Day of month (1-31) to
1and Time to08:00. - Add Submit request and choose your extinguisher-check request template.
- Click Create & activate.
Example: weekday mornings with a cron expression
To run at 07:30 Monday to Friday, choose Custom (Cron) and enter 30 7 * * 1-5.
Change or stop a schedule
From the Smart Workflows list, use the row menu to View details, Edit, Duplicate, Enable or Disable, or Delete a workflow.
You can change the time of a Daily, Weekly or Monthly schedule when you edit it. For other schedules, such as Once or a cron expression that covers several days, the timing is locked: "Schedule timing can't be changed here yet. To change when this runs, recreate the schedule." Use Duplicate, set the new timing, then delete the old one.
For time-based schedules, the Triggers column shows a dash. Hover over it to see "Not recorded for time-based schedules".
Troubleshooting
| Problem | What to check |
|---|---|
| It ran at the wrong hour | Schedules use the organization timezone. Check Timezone and the Schedule preview: line. |
| "Enter a valid cron expression." | Use five parts separated by spaces: minute, hour, day of month, month, day of week. |
| "Add at least one action." | Add Trigger IoT assets or Submit request before saving. |
| A device did not respond | The command was queued, but delivery depends on your network server and the device. See How to send device commands. |
| It did not run at all | Check that the workflow is Enabled and was not left as a draft. |
Related articles
Need help? Contact Infodeck Support