---
title: "Edit Plan Endpoint"
method: POST
path: "/api/projects/plan/edit"
tags: ["plan"]
---

# Edit Plan Endpoint

`POST /api/projects/plan/edit`

Edit an existing plan based on user feedback.

This endpoint:
1. Takes the current plan and user feedback
2. Optionally accepts previous edit requests for context
3. Streams the revised plan tokens via Socket.IO
4. Returns the complete revised plan

Args:
    session_id: Session ID for Socket.IO room
    current_plan: The current plan text to edit
    feedback: User's feedback/edit request
    edit_history: Optional JSON array of previous feedback messages
    current_user: Authenticated user info
    
Returns:
    PlanResponse with the revised plan text

## Response `200`

Successful Response

- PlanResponse — Response model for planning endpoint.
  - `success` boolean, required
  - `session_id` string, required
  - `plan` string, nullable
  - `augmented_assets` AugmentedAsset[], nullable
    - `name` string, required
    - `description` string, required
    - `image_url` string, required
  - `error` string, nullable

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.dev/latted/apis/motion-graphics-designer-api.md) · [All operations](https://skmtc.dev/latted/apis/motion-graphics-designer-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/latted/motion-graphics-designer-api/revisions/36d149b525df/schema)
