Automations

Add a trigger to an automation

Provide exactly one schedule: a frequency cron expression for recurring runs, every_seconds for a fixed interval, or a scheduled_at timestamp for a one-time run. More than one returns 400 schedule_conflict. every_seconds must be a positive integer (400 invalid_every_seconds); values from 1 to 59 are raised to the 60-second minimum, returned as every_seconds: 60 with a schedule_interval_raised entry in warnings. Only the automation's creator can change it; workspace owners and admins can pause or delete it. Anyone else receives 403 automation_owner_only. A system automation (include=system) is changed only by workspace owners and admins (403 workspace_agent_admin_only); any member may add a trigger to it, which runs as that member, and remove their own triggers.

<sub>Scope: automations:write</sub>

post/v3/organizations/{orgId}/automations/{automationId}/triggers

Request

  • Base URL: https://api.reasonmachines.com
  • URL: https://api.reasonmachines.com/v3/organizations/{orgId}/automations/{automationId}/triggers
  • Auth: HTTP bearer

Request body

frequencystring

Cron expression, e.g. 0 3 * * *, for a recurring trigger.

every_secondsinteger

Fixed interval in seconds, a positive integer. Alternative to frequency. The scheduler's minimum is 60 seconds: values from 1 to 59 are stored and returned as 60 with a schedule_interval_raised warning; zero or less returns 400 invalid_every_seconds.

scheduled_atstring date-time

Run-at time for a one-time trigger. Alternative to frequency.

enabledboolean

Response

Created.

idstring
kind'schedule' | 'github_event' | 'webhook'
enabledboolean
run_kindstring nullable
last_fired_atstring date-time nullable
created_atstring date-time
updated_atstring date-time

Changes

No recorded changes to this operation across all 1 revision of this API.