Skip to content
ThirdLayer

Docs > Automations

Triggers

Start Dex automations from cron schedules, one-shot datetimes, integration events, or manual dispatches, with optional pre-run conditions.

A trigger determines when an automation dispatches. Configure trigger in the YAML frontmatter of automations/<name>.md.

Runs repeatedly on a standard 5-field cron schedule evaluated in an explicit IANA timezone. Supported on both personal and shared agents.

trigger:
type: cron
schedule: "0 9 * * 1"
timezone: America/New_York

Always specify an explicit IANA timezone (such as America/New_York, America/Los_Angeles, Europe/London, or UTC) so schedules handle daylight saving transitions predictably.

Runs once at a specific future timestamp. Supported on both personal and shared agents.

trigger:
type: datetime
at: "2026-12-01T14:00:00"
timezone: America/New_York

Starts when a connected integration emits a webhook event (such as a new Gmail message or Slack message). Supported on personal agents only—workspace shared automations reject event triggers at Apply time because webhook subscriptions bind to one user’s integration connection.

trigger:
type: event
integration: gmail
triggerId: new-email-received
delayMinutes: 5
  • integration — Canonical integration slug.
  • triggerId (optional) — Specific provider event trigger ID. Always inspect available triggers for the connected integration rather than guessing IDs.
  • delayMinutes (optional, 0–43200) — Waits before executing (useful when you want a conversation thread to settle before summarizing or drafting a reply).

Runs only when explicitly started from the web UI (Run now), the CLI, or a workflow. Useful for on-demand audits, report generators, or agents invoked by a coordinator.

trigger:
type: manual

Add an optional plain-language condition (up to 4,000 characters) to filter out noisy triggers before committing a full agent run:

condition: >-
Only proceed if the incoming email is from an external customer domain and
asks a question or requests a follow-up. Ignore automated newsletters and
calendar notifications.

For event triggers, Dex runs a lightweight classifier against the incoming event payload and condition before invoking the full agent loop. When the condition does not match, the run is recorded as Skipped with the reason rather than executing tools or generating cards.

Before any triggered run starts, Dex executes admission and eligibility checks:

  1. Active state — Confirms the automation is enabled: true (and for shared members, that membership is on and not Admin-paused).
  2. Requirements and Scope — Verifies that every app/tool listed in AGENT.md’s requires is connected and allowed by the acting user’s Access Scope.
  3. Deduplication — Prevents duplicate dispatches for the same trigger event or scheduled slot (for shared fan-out, each member child run receives a deterministic run ID).
  4. Concurrency — Enforces per-user execution concurrency gating so back-to-back triggers queue cleanly rather than colliding.