Skip to main content
A trigger controls when and how an integration flow runs. Triggers are defined with trigger() or pollingTrigger() and collected in the triggers field of component().

TriggerDefinition type

scheduleSupport and synchronousResponseSupport

Both fields accept one of three string values:

TriggerResult shape

The perform function of a trigger must return a TriggerResult:

Webhook trigger example

A webhook trigger receives an inbound HTTP request and passes its payload to subsequent steps:

Scheduled trigger example

A scheduled trigger fires on a recurring schedule (cron) configured by the integration builder:

Instance lifecycle handlers

onInstanceDeploy and onInstanceDelete run when an instance using this trigger is deployed or deleted. These are useful for registering and deregistering webhooks with a third-party service:

Webhook lifecycle handlers

For more granular webhook management, use webhookLifecycleHandlers instead of onInstanceDeploy/onInstanceDelete. This allows different behavior during create and delete:

Polling triggers

A polling trigger periodically calls an action to check for new events or records. Use pollingTrigger() instead of trigger() for this pattern.

PollingTriggerDefinition type

The perform function for polling triggers receives a PollingContext that extends ActionContext with a polling object:

Polling trigger example

pollingTrigger() automatically sets triggerType: "polling" on the returned object. You do not need to set it manually.