Automation
An automation defines a set of actions to be performed when defined sensor or event triggers occur.
Automation
Below are the properties for the Automation
. Each property links to the specific details section further down in this page.
Property | Default | Type | Required | Description |
---|---|---|---|---|
automation | AutomationOptions | Yes | Configuration options for the automation. |
Property Details
AutomationOptions
Configuration options for an automation.
Property | Default | Type | Required | Description |
---|---|---|---|---|
name | string | No | The name of the model | |
description | string | No | A brief description of what the model does. | |
metadata | ResourceMetadata | No | Meta information of a resource. In most cases it doesn't affect the system behavior but may be helpful to analyze project resources. | |
enabled | boolean | No | A boolean flag indicating whether the automation is enabled (or not). Defaults to True. | |
actions | array[Any of: (ActionOptions, string)] | No | List of actions that the automation performs when triggered. | |
triggers | EventTrigger | No | List of automation triggers. |
ActionOptions
Configuration options for an action.
Property | Default | Type | Required | Description |
---|---|---|---|---|
name | string | No | The name of the model | |
description | string | No | A brief description of what the model does. | |
metadata | ResourceMetadata | No | Meta information of a resource. In most cases it doesn't affect the system behavior but may be helpful to analyze project resources. | |
automation | string | No | Name of the parent automation that the action belongs to. | |
config | object | Yes | Configuration for the action. | |
type | string | Yes | Type of action. |
EventTrigger
A trigger that triggers an automation based on events or sensors.
Property | Default | Type | Required | Description |
---|---|---|---|---|
events | array[One of: (EventSqlFilter, EventPythonFilter, EventTypeFilter)] | No | List of event filters used to identify events that trigger the automation. | |
sensors | array[Any of: (SensorOptions, string)] | No | List of sensors that trigger the automation. |
EventPythonFilter
An event filter that filters based on Python code.
Property | Default | Type | Required | Description |
---|---|---|---|---|
types | array[string] | Yes | List of event types. | |
python_filter | string | Yes | Python code used to filter events from the event stream. |
EventSqlFilter
An event filter that filters based on an SQL query expression.
Property | Default | Type | Required | Description |
---|---|---|---|---|
types | array[string] | Yes | List of event types. | |
sql_filter | string | Yes | SQL query expression used to filter events from the event stream. |
EventTypeFilter
An event filter that filters based on a list of event types.
Property | Default | Type | Required | Description |
---|---|---|---|---|
types | array[string] | Yes | List of event types. |
SensorOptions
Configuration options for a sensor.
Property | Default | Type | Required | Description |
---|---|---|---|---|
name | string | No | The name of the model | |
description | string | No | A brief description of what the model does. | |
metadata | ResourceMetadata | No | Meta information of a resource. In most cases it doesn't affect the system behavior but may be helpful to analyze project resources. | |
automation | string | No | Name of the parent automation that the sensor belongs to. | |
config | object | Yes | Configuration for the sensor. | |
type | string | Yes | Type of sensor. |
ResourceMetadata
Meta information of a resource. In most cases it doesn't affect the system behavior but may be helpful to analyze project resources.
Property | Default | Type | Required | Description |
---|---|---|---|---|
source | ResourceLocation | No | The origin or source information for the resource. | |
source_event_uuid | string | No | UUID of the event that is associated with creation of this resource. |
ResourceLocation
The origin or source information for the resource.
Property | Default | Type | Required | Description |
---|---|---|---|---|
path | string | Yes | Path within repository files where the resource is defined. | |
first_line_number | integer | No | First line number within path file where the resource is defined. |