For the complete documentation index, see llms.txt. This page is also available as Markdown.

Triggers

Introduction

Triggers are the starting point of an automation workflow. They define when something should happen and belong to a supported resource.

When a trigger matches an event or schedule, it evaluates its associated Conditions. If the conditions are met, it executes the linked Actions.

Triggers are typically accessed via the triggers relation on the targetable entity.

Model Definition

Relations

Key
Relation
Type
Relation Field(s)

actions

Morph Many

-

conditions

Morph Many

-

targetable

(Polymorphic)

Morph To

targetable_id, targetable_type

Targetable Types

  • action - Attaches the Trigger to an Action.

  • form - Attaches the Trigger to a Form.

  • taskTemplate - Attaches the Trigger to a TaskTemplate.

Capabilities

Create

Create a new Trigger.

Definition

POST /api/triggers

Request Keys

Key
Type
Default
Description

targetable_type*

string

-

Selects one of the supported Targetable Types.

targetable_id*

integer

-

ID of the targetable entity instance.

lang_id

string

system language

Language for translatable Trigger fields. If omitted, the system language is used.

title*

string

-

Display title of the Trigger.

allow_parallel

boolean

false

Whether multiple executions may run in parallel.

active

boolean

true

Whether the Trigger is active.

sort_number

integer

-

Sort order within the targetable context.

Keys with * are required.

Example Request

Example Response

Update

Update an existing Trigger.

Definition

PUT /api/triggers/{trigger}

Route Parameters

Parameter
Type
Description

trigger

integer

Trigger ID.

Request Keys

Key
Type
Default
Description

targetable_type

string

-

Selects one of the supported Targetable Types.

targetable_id

integer

-

ID of the new targetable entity instance.

lang_id

string

-

Updated language for translatable Trigger fields.

title

string

-

Updated title of the Trigger.

allow_parallel

boolean

-

Updated parallel execution behavior.

active

boolean

-

Updated active state.

sort_number

integer

-

Updated sort order.

Behavior

Only submitted keys are updated.

Example Request

Example Response

Delete

Delete a Trigger.

Definition

DELETE /api/triggers/{trigger}

Route Parameters

Parameter
Type
Description

trigger

integer

Trigger ID.

Example Request

Example Response

Last updated