feat(middleware): implement MCP server with 29 tools (#30)#31
Merged
alexey-pelykh merged 1 commit intomainfrom Feb 26, 2026
Merged
feat(middleware): implement MCP server with 29 tools (#30)#31alexey-pelykh merged 1 commit intomainfrom
alexey-pelykh merged 1 commit intomainfrom
Conversation
Add a standalone MCP server that exposes 29 RemoteClaw-specific tools to CLI subprocess agents via stdio transport. Tools are organized into four categories: session management (7), channel messaging (10), cron scheduling (7), and gateway admin (5). Key components: - mcp-server.ts: Entry point with env-based configuration - mcp-handlers/: Tool handlers delegating to gateway via callMcpGateway - mcp-side-effects.ts: NDJSON writer/reader for tracking sent messages and cron additions - mcp-tools.ts: Registration orchestrator Co-Authored-By: Claude Opus 4.6 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
McpHandlerContextshared across all handlersNew Files
src/middleware/mcp-server.tssrc/middleware/mcp-tools.tssrc/middleware/mcp-handlers/context.tsMcpHandlerContexttypesrc/middleware/mcp-handlers/session.tscallMcpGatewayhelpersrc/middleware/mcp-handlers/message.tssrc/middleware/mcp-handlers/cron.tssrc/middleware/mcp-handlers/gateway.tssrc/middleware/mcp-side-effects.tsTest plan
pnpm tsgo) passes cleanpnpm lint) passes clean (0 warnings, 0 errors)pnpm format) passes cleanCloses #30
🤖 Generated with Claude Code