Skip to content

Commit c701e72

Browse files
authored
docs(mcp): the verdict an agent receives carries the fix field (#33)
## What Restores the MCP guide paragraph held back from #32. commit-check/commit-check-mcp#32 gives every check a `fix` key: populated with the corrected value when commit-check can name one, empty otherwise. The guide now says so, with a pointer to [Reading the JSON](https://commit-check.com/example/#reading-the-json) for the field's semantics. Merge after commit-check-mcp#32 ships, so the guide describes a released server. Docs-sync tests: 9 passed.
1 parent f38b381 commit c701e72

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

‎docs/guides/mcp.md‎

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,12 @@ Before every commit, validate the message with the commit-check MCP tool
7878
```
7979

8080
The result the agent gets back is the same structured verdict the CLI prints
81-
with `--format json`: a status, and for each check its value, the error and a
82-
suggestion. That is enough for the agent to correct the message on its own.
81+
with `--format json`: a status, and for each check its value, the error, a
82+
suggestion and — when the correction is unambiguous — the corrected value in
83+
`fix`. A type written `Fix` comes back as `"fix": "fix: add x"`, ready to
84+
apply; a subject with no type at all leaves `fix` empty, and the agent works
85+
from the suggestion instead. See [Reading the JSON](../example.md#reading-the-json).
86+
The key is always present; an older commit-check leaves it empty.
8387

8488
## The tools
8589

0 commit comments

Comments
 (0)