Skip to main content

What are triggers?

Triggers are the “when” for your workflows. Instead of only running a workflow by hand (API call or button click), you attach a trigger instance to it: for example “every day at 9 AM” or “when a webhook is called”. Flowra then runs the workflow at that time or when that event happens. Each such rule is a trigger instance — it has a type (schedule, webhook, etc.), a slug, and is linked to a workflow (and optionally to a connected account for OAuth context). So: workflow = what runs; trigger = when it runs (schedule or event).

Example use cases

  • Daily digest — Create a trigger that runs every morning; the workflow fetches emails, summarizes them, and posts to Slack.
  • Webhook from your app — Your backend sends a webhook when an order is placed; the trigger runs a workflow that notifies the team and updates a sheet.
  • Per-user schedules — Each user has a connected account; you create one trigger instance per user so “their” workflow runs with “their” calendar or inbox.

How it works

  1. You have a workflow that you want to run automatically.
  2. You create or update a trigger instance via POST /trigger_instances/{slug}/upsert — you pass the slug (e.g. for schedule), the workflow or connection info, and any schedule or event config. Same slug = idempotent update.
  3. Flowra runs the workflow when the trigger fires. You can list active trigger instances, enable/disable one, or delete it to stop it permanently.
The API lets you list active triggers (with filters), upsert (create/update), change status, and delete.

API endpoints

Get active trigger instances

GET /api/v1/trigger_instances/active returns active trigger instances with optional filters and pagination.
Query parameterDescription
connectedAccountIdsFilter by connected account IDs
authConfigIdsFilter by auth config IDs
trigger_ids, trigger_ids (legacy)Filter by trigger IDs
trigger_names, triggerNames (legacy)Filter by trigger names
showDisabledInclude disabled triggers
page, limit, cursorPagination

Upsert trigger instance

POST /api/v1/trigger_instances/{slug}/upsert creates or updates a trigger instance for the given slug. Request body: UpsertTriggerInstanceDto (see API reference). Use a stable slug to idempotently create or update the instance.

Update trigger status (enable/disable)

PATCH /api/v1/trigger_instances/manage/{triggerId}/status enables or disables a trigger instance by ID. Send the desired status in the request body as defined in the API reference.

Delete trigger instance

DELETE /api/v1/trigger_instances/manage/{triggerId} removes the trigger instance.