agent/google/mcp/README.md
Snider 3782514acf
feat(cli): integrate MCP server (#71)
Exposes core CLI commands as MCP tools for AI agents.

This change introduces a Go-based MCP server that wraps the
existing core CLI commands (`go test`, `dev health`, `dev commit`),
providing structured JSON responses.

This allows AI agents to interact with the core CLI in a structured,
type-safe manner.

The implementation includes:
- A new Go HTTP server in `google/mcp/`
- Handlers for each of the core CLI commands
- Unit tests for the handlers with a mock `core` executable
- Documentation for the new MCP tools
- Integration with the `code` plugin via `plugin.json`
2026-02-02 07:14:50 +00:00

67 lines
1,003 B
Markdown

# Core CLI MCP Server
This directory contains an MCP server that exposes the core CLI commands as tools for AI agents.
## Tools
### `core_go_test`
Run Go tests.
**Parameters:**
- `filter` (string, optional): Filter tests by name.
- `coverage` (boolean, optional): Enable code coverage. Defaults to `false`.
**Example:**
```json
{
"tool": "core_go_test",
"parameters": {
"filter": "TestMyFunction",
"coverage": true
}
}
```
### `core_dev_health`
Check the health of the monorepo.
**Parameters:**
None.
**Example:**
```json
{
"tool": "core_dev_health",
"parameters": {}
}
```
### `core_dev_commit`
Commit changes across repositories.
**Parameters:**
- `message` (string, required): The commit message.
- `repos` (array of strings, optional): A list of repositories to commit to.
**Example:**
```json
{
"tool": "core_dev_commit",
"parameters": {
"message": "feat: Implement new feature",
"repos": [
"core-agent",
"another-repo"
]
}
}
```