mark_story_done
Record a merged story as done, update its ticket and manifest status, clear stale parked reasons, and notify when the plan's final story completes.
Instructions
Mark a story finished: sets its ticket (Plane, when enabled) to Done, sets manifest["stories"][story_key]["status"] to "done", and clears any stale parked_reason. If this was the plan's last remaining story, fires the plan-completion notification.
plan_name: the plan's name, as returned by list_plans or passed to save_plan/ingest_plan. story_key: the story's key within that plan's manifest, as returned by list_ready_stories, check_story_status, or dispatch_story.
Call this only after the story's PR has actually been reviewed and merged —
approve_merge already calls this internally as its last step, so you normally
only need to call mark_story_done directly for a merge that happened outside
the pipeline (e.g. a manual gh pr merge you've already confirmed passed CI).
It does not merge or verify anything; after recording the work as done it
removes the story's worktree and local branch when the worktree is clean and
inside WORKTREE_ROOT. If another dispatch/ingest/interrupt holds the plan's
lock, this is a no-op that returns {"ok": True, "skipped": "locked", ...}
rather than blocking or raising — retry the call rather than assuming failure.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"plan_name": "<plan_name>",
"story_key": "<story_key>"
},
"name": "mark_story_done"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| plan_name | Yes | ||
| story_key | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||