Skip to content

feat: add MCP server (gmc mcp)#102

Merged
yasserstudio merged 2 commits into
mainfrom
feat/mcp-server
Jun 22, 2026
Merged

feat: add MCP server (gmc mcp)#102
yasserstudio merged 2 commits into
mainfrom
feat/mcp-server

Conversation

@yasserstudio

Copy link
Copy Markdown
Owner

Summary

  • New @gmc-cli/mcp package — Model Context Protocol server over stdio exposing 12 tools to AI assistants (Claude Desktop, Cursor, VS Code Copilot, etc.)
  • Tools: doctor, accounts_list, accounts_get, products_list, products_get, products_insert, products_delete, datasources_list, issues_account, quota_list, reports_query, preflight
  • CLI command: gmc mcp (lazy-loaded, ~10 KB chunk)
  • Docs page, sidebar entry, reference index, and README MCP section added

Test plan

  • 3 MCP tests pass (tool listing, descriptions, input schemas) via in-memory transport
  • 298 total tests pass (295 existing + 3 new)
  • Build, typecheck, lint all green
  • Manual: add to claude_desktop_config.json, verify tools appear and doctor responds

@socket-security

socket-security Bot commented Jun 22, 2026

Copy link
Copy Markdown

Review the following changes in direct dependencies. Learn more about Socket for GitHub.

Diff Package Supply Chain
Security
Vulnerability Quality Maintenance License
Added@​modelcontextprotocol/​sdk@​1.29.09910010092100
Addedzod@​3.25.7610010010093100

View full report

New @gmc-cli/mcp package with Model Context Protocol server over stdio.
Tools: doctor, accounts, products, datasources, issues, quota, reports,
preflight. Lazy-loaded via gmc mcp command. Works with Claude Desktop,
Cursor, VS Code Copilot, and any MCP-compatible client.
…validation

- Fix loadConfig() call (was passing dir instead of file path)
- Add try/catch + isError on all 12 tool handlers
- Add path traversal guard on preflight dir parameter
- Add numeric validation on account id parameter
- Cap page_size at 250 (API max)
- Extract buildClient helper to reduce boilerplate
- Re-export StdioServerTransport from @gmc-cli/mcp (dedupe SDK)
- Remove SDK deps from CLI package (bundled via mcp)
- Remove publishConfig from private mcp package
- Static imports for node:fs/promises and node:path
@yasserstudio yasserstudio merged commit 3e41613 into main Jun 22, 2026
8 checks passed
@yasserstudio yasserstudio deleted the feat/mcp-server branch June 22, 2026 16:01
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.

1 participant