Attach the implementation plan to the active work item
spec.attach_planChanges dataCreates, updates or deletes something in your workspace.What it does
After the story-plan prompt: records the plan document you committed (repo-relative path, commit sha and the file's content md5 from npx @testmaze/mcp docs manifest --dir docs/specs) on the active work item for this branch. The story's Definition of Ready then shows the plan, and reviewers find it from the story. Requires an active work item (spec.start_work). Returns the updated workItem.
Ask your agent
You don’t call spec.attach_plan yourself. Say something like this to Claude Code, Cursor or another MCP-connected agent:
- “Attach docs/specs/AAts-…-saved-card.md as the plan for this story”
Inputs
| Name | Type | Description |
|---|---|---|
branchrequired | string | Current git branch, from git rev-parse --abbrev-ref HEAD in the repository root. |
planPathrequired | string | Repo-relative path of the plan, e.g. "docs/specs/<storyId>-<slug>.md". |
commitShaoptional | string | The commit that added the plan. |
md5optional | string | Content md5 of the plan file, from docs manifest. |
The MCP call
What the agent’s MCP client sends (placeholders in angle brackets):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "spec.attach_plan",
"arguments": {
"branch": "<branch>",
"planPath": "<planPath>"
}
}
}Connect your agent
npx -y @testmaze/mcp init tmt_xxx claude mcp add tm --scope project -- npx -y @testmaze/mcp
Create the token in your Test Maze workspace under Settings → MCP. Setup for Cursor, Cline, Gemini CLI and Codex CLI is shown there too.
More spec-based development tools
- Check the spec-based development rules and your active work item
spec.status - Declare the user story or test case a code change is for
spec.start_work - Close the active work item on a branch
spec.finish_work - Show which commits implement a story or test case
spec.trace - Check a commit message carries a valid Testmaze-Ref trailer
spec.check_commit