---
title: "Update a pending plan"
method: PUT
path: "/api/v1/plan/{id}"
tags: ["Multi-Agent Planning"]
---

# Update a pending plan

`PUT /api/v1/plan/{id}`

## Request

- Base URL: `https://orchestrator.getaxonflow.com`
- URL: `https://orchestrator.getaxonflow.com/api/v1/plan/{id}`
- Auth: none declared
- TypeScript: <https://skmtc.dev/getaxonflow/apis/axonflow-orchestrator-api/docs/api/v1/plan/:id/put.ts> (a function with typed inputs; its response is checked against the schema)

Update a plan that has not yet been executed.
Uses optimistic locking via the `version` field — the request must include
the expected current version. If the version doesn't match, returns 409.

Only plans with status `pending` can be updated.

## Path parameters

- `id` string, required

## Request body

- UpdatePlanRequest
  - `version` integer, required: Expected current version (for optimistic locking)
  - `execution_mode` 'auto' | 'parallel' | 'sequential' | 'balanced' | 'confirm' | 'step': New execution mode
  - `domain` string: New domain
  - `metadata` object: Additional metadata to set

## Response `200`

Plan updated successfully

- UpdatePlanResponse
  - `success` boolean
  - `plan_id` string
  - `version` integer: New version number after update
  - `status` string

## Other responses

- `404`: Plan not found
- `409`: Version conflict (plan was modified by another request)
- `413`: The request body is over 1 MiB (1,048,576 bytes), refused whole before it is decoded, in this route's `{success, error}` envelope: `error` begins `request_too_large: `. Nothing is gated, planned or run (#4249).

---

[API](https://skmtc.dev/getaxonflow/apis/axonflow-orchestrator-api.md) - [All operations](https://skmtc.dev/getaxonflow/apis/axonflow-orchestrator-api/llms.txt) - [OpenAPI document](https://skmtc.dev/getaxonflow/apis/axonflow-orchestrator-api/revisions/f408ef3ec9dd?raw)
