--- alias: user-guide-automation-task-core-ontimer tags: - automation tasks description: "This task emits an event when a timer expires, triggering defined actions repeatedly" --- # On timer :iot-timer-timer-lg: The **On timer** task emits an event if the timeout period expires without being refreshed. ![Screenshot showing a timer interface with interval and timestamp fields.](../images/on_timer.png) ## Inputs | Name | Data Type | Description | | ------------------- | --------- | ---------------------------------------------------------------------------------------------------------- | | Interval | `Integer` | Interval to emit | | NumberOfOccurrences | `Integer` | Number of occurrences to trigger the cron job after activation/reactivation. Leave 0 to ignore the counter | | Enable/Disable | `any` | Activates the timer execution | ## Outputs | Name | Data Type | Description | | --------- | ---------- | ------------------------------------------------------ | | Timestamp | `DateTime` | Current time upon execution | | Success | `Boolean` | If there was no problem emits a true | | Error | `Error` | Error that occurred during the processing of this task | ## Settings | Name | Data Type | Default | Description | | ------------------- | --------- | ------- | ------------------------------------------------------------------------------------------------------------------ | | Auto Enable | `Boolean` | true | Activates the cronjob execution | | Interval | `Integer` | 10000 | Trigger the timer every number of milliseconds | | NumberOfOccurrences | `Integer` | 0 | Default number of occurrences to trigger the cron job after activation/reactivation. Leave 0 to ignore the counter | ## Behavior The Timeout task, allows the user to set actions that occur every set amount of time, for a set number of times.