RevnuDocs
Browse the Docs▾

API Reference / Run a workflow now

Run a workflow now

POST/api/v1/workflows/{id}/runs

Start a workflow's next run within about a minute, without changing its schedule.

Last updated

curl -X POST -H "Authorization: Bearer $REVNU_API_TOKEN" -H "Content-Type: application/json" \
  -d '{"clientRequestId":"wf-h97-first-run"}' \
  https://revnu.com/api/v1/workflows/h97…/runs

Body

{ clientRequestId? }. Both the body and the field are optional. clientRequestId (1 to 128 characters of A-Z a-z 0-9 _ . : -) makes the call safe to retry: the same id on the same workflow returns the same run.

Response

202 { "run": { id, status: "queued", startedAt }, "deduplicated": false }. The run starts within about a minute and then shows in GET /workflows/{id}/runs under the same id, moving from queued to running and then done or failed.

deduplicated: true means no new run was queued: the clientRequestId was seen before, or the workflow already has a run queued or running, and run is that one.

Code Meaning
409 error is paused (resume it first), schedule_pending (the schedule is still being set up, so retry shortly) or schedule_error (fix scheduleText).

Agents: this page is also markdown at /docs/workflow-run.md, answers Accept: text/markdown, and is listed in /docs/llms.txt.

Frequently Asked Questions

No. The workflow keeps running on its schedule. The one exception: when the next scheduled run is less than an hour away, this run replaces it, so the agent doesn't do the same work twice in a row.