feat(mcp): implement MCP server with 210 tools for full platform management#11
Merged
feat(mcp): implement MCP server with 210 tools for full platform management#11
Conversation
…gement Add a complete MCP (Model Context Protocol) server in mcp/ that mirrors the Temps CLI functionality, enabling AI agents to manage the entire Temps deployment platform programmatically. MCP server highlights: - 210 tools across 30 domain modules (projects, deployments, environments, domains, backups, monitors, containers, services, DNS, error tracking, etc.) - OpenAPI SDK generated via @hey-api/openapi-ts from live spec - Hand-written TempsClient with GET/POST/PUT/PATCH/DELETE/WS methods - WebSocket support for container runtime logs - O(1) tool dispatch registry - 103 integration tests, all passing against dev instance - Published as @temps-sdk/mcp (npx/bunx executable) Also includes: - providers: auto-generate secret_key for MinIO, refine parameter strategies - web: add RustFS service logo and improve service type detection - cli: add table header styling helper - CLAUDE.md: comprehensive rewrite with error handling, resilience, and testing guidance - scripts: add analytics seed data utilities
- CRITICAL: Replace curl|sh acme.sh install with git clone (RCE risk) - HIGH: Remove explicit ~/.temps/.secrets path (credential exposure) - HIGH: Replace 15 secret-like example tokens with <YOUR_...> placeholders - MEDIUM: Add npm package provenance note with org/repo links - MEDIUM: Add Security Considerations section for external data handling - LOW: Add boundary/sanitization guidance for prompt injection surface
…l path
- Wrap JSON examples containing {braces} in backticks when generating
MDX format, preventing acorn parser from treating them as JSX expressions
- Remove explicit ~/.temps/.secrets path from generated docs footer
- Applied to both docs.ts and generate-docs.ts
Replace @temps/cli with @temps-sdk/cli and bare 'temps' commands with 'bunx @temps-sdk/cli' across CLI.md and CLI.mdx. Remove the npm install -g instruction since the CLI is used via bunx.
The deployment logs endpoint returns raw JSONL text, but the MCP client always ran JSON.parse on responses, causing silent failures. - Add getRaw() method to TempsClient for plain-text endpoints - Rewrite get_deployment_logs to show a pipeline stage summary table with status icons and durations, followed by parsed JSONL log content with level-appropriate formatting
- Bump package version from 0.1.1 to 0.1.3 in package.json. - Add detailed usage instructions for tool categories in index.ts. - Introduce a help command that displays available tool categories and environment variables. - Update integration test to reflect new validation criteria for tool registration. - Add new analytics tool definitions in analytics.ts for enhanced project metrics tracking. - Improve environment resource update descriptions for clarity in environments.ts.
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
mcp/) that mirrors the Temps CLI, exposing 210 tools across 30 domain modules for AI agents to manage the entire Temps platform programmatically@hey-api/openapi-ts; hand-writtenTempsClientwith REST + WebSocket support for container logs@temps-sdk/mcp(executable vianpx/bunx)Additional changes
secret_keyfor MinIO, refine parameter strategies for service creationadd-visitors,backfill-recent,boost-today)MCP Server Architecture
How to use
{ "mcpServers": { "temps": { "command": "npx", "args": ["@temps-sdk/mcp"], "env": { "TEMPS_API_URL": "https://your-instance.example.com", "TEMPS_API_KEY": "your-api-key-here" } } } }