---
title: "Update a workflow"
method: POST
path: "/v1/workflows/{workflowId}"
tags: ["Workflows"]
---

# Update a workflow

`POST /v1/workflows/{workflowId}`

Update a workflow's display properties. At least one property must be provided. To change the workflow's mailing list, use the `POST /v1/workflows/{workflowId}/mailing-list` endpoint instead.

## Request body

- union — At least one property must be provided.
  - object
    - `expectedRevisionId` string, nullable, required — The workflow revision token returned by the latest workflow read or mutation. Older workflows may return `null` before their first revision-aware mutation; pass `null` back as `expectedRevisionId` in that case. If the token is stale, the API returns a `409 Conflict` error.
    - `name` string, required — The updated workflow name.
    - `description` string — The updated workflow description.
  - object
    - `expectedRevisionId` string, nullable, required — The workflow revision token returned by the latest workflow read or mutation. Older workflows may return `null` before their first revision-aware mutation; pass `null` back as `expectedRevisionId` in that case. If the token is stale, the API returns a `409 Conflict` error.
    - `name` string — The updated workflow name.
    - `description` string, required — The updated workflow description.

## Response `200`

Workflow properties updated.

- SimplifiedWorkflow
  - `id` string, required — The ID of the workflow.
  - `workflowRevisionId` string, nullable, required — The current workflow revision token. Pass the latest value as `expectedRevisionId` on the next workflow mutation. Will be `null` for workflows without a revision token yet.
  - `status` 'Draft' | 'Sending' | 'Paused' | 'PausedAndQueueing', required
  - `name` string — The name of the workflow.
  - `description` string — The description of the workflow.
  - `mailingListId` string, nullable, required — The ID of the mailing list the workflow sends to.
  - `rootNodeId` string, required — The ID of the root node in the workflow graph.
  - `nodes` object, required — A map of node IDs to simplified node objects. Each node includes `typeName` and `nextNodeIds`, plus type-specific fields when present. To get the full node object, use the `GET /v1/workflows/{workflowId}/nodes/{nodeId}` endpoint.

## Other responses

- `400` — Invalid `workflowId` or request body.
- `401` — Invalid API key.
- `404` — Workflow not found.
- `405` — Wrong HTTP request method.
- `409` — `expectedRevisionId` is stale.

---

[API](https://skmtc.net/loops/apis/loops-openapi-spec.md) · [All operations](https://skmtc.net/loops/apis/loops-openapi-spec/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/loops/loops-openapi-spec/revisions/9cc087257f0d/schema)
