---
title: "Update a workflow"
method: PATCH
path: "/api/v1/workflows/{id}"
tags: ["API Reference"]
---

# Update a workflow

`PATCH /api/v1/workflows/{id}`

## Request

- Base URL: `https://revnu.com`
- URL: `https://revnu.com/api/v1/workflows/{id}`
- Auth: HTTP bearer

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

Requires the `workflows:write` scope.

**Response.** `{ "workflow": { … } }`, the updated workflow with its new `version`. `404` for an unknown or another account's workflow. `409` when `deliverTo` is not a connected destination; the message lists the options.

## Path parameters

- `id` string, required

## Request body

- object

## Response `200`

{ "workflow": { … } }, the updated workflow with its new version. 404 for an unknown or another account's workflow. 409 when deliverTo is not a connected destination; the message lists the options.

- object
  - `workflow` object, required
    - `workflowId` string, required
    - `url` string, required
    - `version` number, required
    - `name` string, required
    - `description` string, required
    - `status` 'live' | 'paused' | 'proposed', required
    - `scheduleText` string, required
    - `scheduleEcho` string, nullable, required
    - `scheduleError` string, nullable, required
    - `deliverTo` string, nullable, required
    - `requestedBy` string, nullable, required
    - `nextRunAt` number, nullable, required
    - `steps` object[], required
      - `gate` object
        - `label` string
        - `on` boolean, required
      - `id` string, required
      - `title` string, required
      - `details` string[], required

## Other responses

- `400`: The request is malformed; the error names the problem.
- `401`: Missing, malformed, unknown or revoked token.
- `402`: `setup_pending`: the account hasn't started its trial. Finish setup with `GET /setup`.
- `403`: The token lacks the scope in `requiredScope`.
- `404`: Unknown id, or another account's id.
- `409`: A settled refusal: `invalid_action` (see `actions`) or `rejected`.
- `429`: Rate limited.
- `503`: Temporarily unavailable; retry the same call.

---

[API](https://skmtc.dev/revnu/apis/revnu-api.md) · [All operations](https://skmtc.dev/revnu/apis/revnu-api/llms.txt) · [OpenAPI document](https://skmtc.dev/revnu/apis/revnu-api/revisions/52e523c2db61?raw)
