Automations
Introduction
Automations let you define reusable media workflows that can be triggered on demand via the API.
You can run Tasks in parallel — for example, a social media app might check if an image is nsfw, get a summary, and create a small thumbnail image. These don't depend on each other so they can all run at the same time.
You can chain tasks together in sequence — for example, a short video app might transcode each upload, then use that video to create a thumbnail.
You can run tasks conditionally based on file properties — for example, a messaging app might only resize images if they're larger than a certain width.
What is an automation?
An automation has a name, an optional description, a workflow array, and a status.
Automation object
Triggering automations
Automations are triggered by sending a POST request to the automation's run endpoint:
This creates a new run that executes the automation's workflow against the provided URL.
Automation statuses
| Status | Description |
|---|---|
active | Automation is enabled and can be triggered |
paused | Automation is disabled and cannot be triggered |
Workflow structure
The workflow is an array of task definitions. Each task in the workflow uses the same format as Runs:
See Workflows for details on sequential chains, parallel execution, and conditional logic.
API Reference
See the API Reference for the full list of automation endpoints and their parameters.