Tutorial
Run a workflow from the API
Call a saved workflow from code, Zapier, Make, or n8n. Start with polling, then switch to webhooks when the run needs to feed another system.
Before you start
Estimated time: 6 min
- A paid LLMWeave plan
- A saved workflow in The Loom
- An API key with workflows:read and workflow_runs:create scopes
Create a scoped API key
2 minOpen Settings, create an API key, and copy it when it is shown. For most scripts, grant workflows:read and workflow_runs:create. Add webhooks:manage only if you are creating standing webhook subscriptions.
Find the workflow id
1 minUse GET /api/v1/workflows to list the workflows your key can run, or copy the id from the workflow URL in The Loom. If your key has a workflow allowlist, only those workflows are visible.
Trigger the run
3 to 5 minPOST to /api/v1/workflows/{workflow_id}/runs with input_text. If the workflow declares params, fetch GET /api/v1/workflows/{workflow_id} first and send a params object using the returned select, number, text, and boolean definitions.
Send an Idempotency-Key header, such as a UUID, so a network retry does not start the same workflow twice.
Poll or use a webhook
5 to 10 minFor a simple script, poll GET /api/v1/workflow-runs/{run_id} every few seconds until status is completed, failed, cancelled, or awaiting_input.
For Zapier, Make, n8n, or your own queue, pass webhook_url when creating the run, or create a standing webhook subscription. Webhook payloads are signed, and the API reference at /docs/api has copy-paste verification snippets.
Handle human review pauses
2 minIf status is awaiting_input, the workflow is paused for a human-review step. Send the reviewer to the app link from the API response or webhook payload. The v1 API does not have an approve/resume endpoint yet.
Keep going
Set up a multi-step workflow in The Loom
Use The Loom when one prompt is not enough. Build draft, critique, research, and review steps, then let the workflow run in the background.
Intermediate · 4 minGround a weave in current sources with web search
Turn on web search when the answer depends on today’s facts: prices, product pages, news, docs, or anything else that can go stale.