Skip to Content
Browse the Docs▾

Update a workflow

PATCH/api/v1/workflows/{id}

Change a workflow's name, schedule, steps, destination or status. Steps are replaced whole.

curl -X PATCH -H "Authorization: Bearer $REVNU_API_TOKEN" \
  -H "content-type: application/json" \
  -d '{"scheduleText":"every weekday at 08:30 Europe/London"}' \
  https://revnu.com/api/v1/workflows/j57…

Body

Any of name, description, scheduleText, steps, deliverTo, status ("live" or "paused"), with the same limits as create, including the size of the whole workflow, which is checked when name or steps change. steps replaces the whole list, so send back the steps you are not changing and keep their id so run history stays attached. A changed scheduleText is re-resolved after the write.

Response

{ "workflow": { … } }, the updated workflow with its new version. 400 names a broken limit, such as a workflow too big for one run. 404 for an unknown or another account's workflow. 409 when deliverTo is not a connected destination; the message lists the options.

Frequently Asked Questions

Which scope does this need?

workflows:write. A token without it gets 403 with requiredScope in the body. GET /me shows a token's scopes.

Are responses cached?

Every response is Cache-Control: no-store, so nothing between you and Revnu caches it.