Skip to content

Add fix tool to MCP server#9035

Merged
pelikhan merged 2 commits intomainfrom
copilot/add-fix-tool-to-mcp-server
Jan 5, 2026
Merged

Add fix tool to MCP server#9035
pelikhan merged 2 commits intomainfrom
copilot/add-fix-tool-to-mcp-server

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Jan 5, 2026

The MCP server now exposes the fix command as a tool, enabling AI agents to automatically apply codemods to workflow files through the Model Context Protocol.

Changes

  • Added fix tool to MCP server (pkg/cli/mcp_server.go)

    • Supports workflows (array of workflow IDs), write (boolean), and list_codemods (boolean) parameters
    • Wraps gh aw fix command as subprocess
    • Returns formatted text showing applied fixes
  • Updated documentation (pkg/cli/mcp_server.go)

    • Added fix tool to available tools list in command help
  • Added tests (pkg/cli/mcp_server_test.go, pkg/cli/mcp_server_fix_test.go)

    • Updated expected tools list
    • Added integration tests for dry-run, write, and list-codemods modes

Usage

{
  "name": "fix",
  "arguments": {
    "workflows": ["my-workflow"],
    "write": true
  }
}

The tool applies codemods that migrate deprecated syntax (e.g., timeout_minutestimeout-minutes).

Original prompt

Add a new tool "fix" in the mcp-server that wraps the "fix" command.


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Copilot AI changed the title [WIP] Add new tool 'fix' wrapping the 'fix' command in mcp-server Add fix tool to MCP server Jan 5, 2026
Copilot AI requested a review from pelikhan January 5, 2026 22:46
@pelikhan pelikhan marked this pull request as ready for review January 5, 2026 22:54
@pelikhan pelikhan merged commit 17dce93 into main Jan 5, 2026
4 checks passed
@pelikhan pelikhan deleted the copilot/add-fix-tool-to-mcp-server branch January 5, 2026 22:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants