---
title: "Delete a workflow node"
method: DELETE
path: "/v1/workflows/{workflowId}/nodes/{nodeId}"
tags: ["Workflow nodes"]
---

# Delete a workflow node

`DELETE /v1/workflows/{workflowId}/nodes/{nodeId}`

Delete a single workflow node. If contacts are queued at the node, Loops returns with `"status": "queuedContactsFound"` instead of deleting. Retry with `queuedContactPolicy: "discard"` to delete the node and discard those queued contacts. Confirmed deletion responses include the simplified workflow after the node is removed.

## Request body

- DeleteWorkflowNodeRequest
  - `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.
  - `dryRun` boolean — If `true`, the request will be validated but the workflow will not be modified.
  - `queuedContactPolicy` 'fail' | 'discard' — `fail` returns queued-contact impact instead of mutating. `discard` confirms that matching queued contacts should be discarded. Defaults to `fail` when omitted.

## Response `200`

Delete dry run, queued-contact warning, or deletion result. Confirmed deletion responses include the simplified workflow after the node is removed.

- union
  - WorkflowQueuedContactDeletePreview
    - `status` 'dryRun' | 'queuedContactsFound', required
    - `nodeIds` string[], required — The IDs of the nodes that would be deleted.
    - `queuedContactCount` number, required — The number of queued contacts that would be removed from the workflow due to the node deletion.
  - WorkflowDeletedResponse
    - `status` 'deleted', required
    - `nodeIds` string[], required
    - `workflowRevisionId` string, required — The current workflow revision token. Pass the latest value as `expectedRevisionId` on the next workflow mutation.
    - `queuedContactCount` number, required — The number of queued contacts that were removed from the workflow due to the node deletion.
    - `workflow` SimplifiedWorkflow, required
      - `id` string, required — The ID of the workflow.
      - `url` string, uri, required — The URL of the workflow in the Loops app.
      - `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`, `nodeId`, request body, or delete target.
- `401` — Invalid API key.
- `404` — Workflow or workflow node not found.
- `405` — Wrong HTTP request method.
- `409` — `expectedRevisionId` is stale.

## Changes

> 9 revisions in range; 1 not diffed, 3 could not be searched.

- **2026-07-26** `72d136d738c3` — 2 breaking
  - removed the required property `oneOf[#/components/schemas/WorkflowDeletedResponse]/queuedContactLimitReached` from the response with the `200` status
  - removed the required property `oneOf[#/components/schemas/WorkflowQueuedContactDeletePreview]/queuedContactLimitReached` from the response with the `200` status
- **2026-07-21** `df77516a130a` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/loops/apis/loops-openapi-spec/changes/v1/workflows/:workflowId/nodes/:nodeId/delete.md)

---

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