diff --git a/docs/src/content/docs/reference/mcp-gateway.md b/docs/src/content/docs/reference/mcp-gateway.md index e84b2cfa69..6563f8a685 100644 --- a/docs/src/content/docs/reference/mcp-gateway.md +++ b/docs/src/content/docs/reference/mcp-gateway.md @@ -225,6 +225,7 @@ Each server configuration MUST support: | `env` | object | No | Environment variables for the server process | | `type` | string | No | Transport type: "stdio" or "http" (default: "stdio") | | `url` | string | Conditional** | HTTP endpoint URL for HTTP servers | +| `registry` | string | No | URI to the installation location when MCP is installed from a registry. This is an informational field used for documentation and tooling discovery. Applies to both stdio and HTTP servers. Example: `"https://api.mcp.github.com/v0/servers/microsoft/markitdown"` | | `tools` | array[string] | No | Tool filter for the MCP server. Use `["*"]` to allow all tools (default), or specify a list of tool names to allow. This field is passed through to agent configurations and applies to both stdio and http servers. | | `headers` | object | No | HTTP headers to include in requests (HTTP servers only). Commonly used for authentication to external HTTP servers. Values may contain variable expressions. | @@ -1181,6 +1182,48 @@ Implementations SHOULD provide: } ``` +#### A.5 Servers with Registry Field + +The `registry` field documents the MCP server's installation location in an MCP registry. This is useful for tooling discovery and version management. + +```json +{ + "mcpServers": { + "markitdown": { + "registry": "https://api.mcp.github.com/v0/servers/microsoft/markitdown", + "container": "node:lts-alpine", + "entrypointArgs": ["npx", "-y", "@microsoft/markitdown"], + "type": "stdio" + }, + "filesystem": { + "registry": "https://api.mcp.github.com/v0/servers/modelcontextprotocol/filesystem", + "container": "node:lts-alpine", + "entrypointArgs": ["npx", "-y", "@modelcontextprotocol/server-filesystem"], + "type": "stdio" + }, + "custom-api": { + "registry": "https://registry.example.com/servers/custom-api/v1", + "type": "http", + "url": "https://api.example.com/mcp", + "headers": { + "Authorization": "Bearer ${API_TOKEN}" + } + } + }, + "gateway": { + "port": 8080, + "domain": "localhost", + "apiKey": "gateway-secret-token" + } +} +``` + +**Notes**: +- The `registry` field is informational and does not affect server execution +- It can be used with both stdio (containerized) and HTTP servers +- Registry-aware tooling can use this field for discovery and version management +- The field complements other configuration fields like `container`, `entrypointArgs`, or `url` + ### Appendix B: Gateway Lifecycle Examples #### B.1 Closing the Gateway diff --git a/docs/src/content/docs/reference/tools.md b/docs/src/content/docs/reference/tools.md index df0458221d..8e45cee973 100644 --- a/docs/src/content/docs/reference/tools.md +++ b/docs/src/content/docs/reference/tools.md @@ -230,7 +230,45 @@ mcp-servers: allowed: ["send_message", "get_channel_history"] ``` -**Options**: `command` + `args` (process-based), `container` (Docker image), `url` + `headers` (HTTP endpoint), `env` (environment variables), `allowed` (tool restrictions). See [MCPs Guide](/gh-aw/guides/mcps/) for setup. +**Options**: `command` + `args` (process-based), `container` (Docker image), `url` + `headers` (HTTP endpoint), `registry` (MCP registry URI), `env` (environment variables), `allowed` (tool restrictions). See [MCPs Guide](/gh-aw/guides/mcps/) for setup. + +### Registry Field + +The `registry` field specifies the URI to an MCP server's installation location in an MCP registry. This is useful for documenting the source of an MCP server and can be used by tooling to discover and install MCP servers: + +```yaml wrap +mcp-servers: + markitdown: + registry: "https://api.mcp.github.com/v0/servers/microsoft/markitdown" + command: "npx" + args: ["-y", "@microsoft/markitdown"] +``` + +**When to use**: +- **Document server source**: Include `registry` to indicate where the MCP server is published +- **Registry-aware tooling**: Some tools may use the registry URI for discovery and version management +- **Both stdio and HTTP servers**: Works with both `command`-based stdio servers and `url`-based HTTP servers + +**Examples**: + +```yaml wrap +# Stdio server with registry +mcp-servers: + filesystem: + registry: "https://api.mcp.github.com/v0/servers/modelcontextprotocol/filesystem" + command: "npx" + args: ["-y", "@modelcontextprotocol/server-filesystem"] + +# HTTP server with registry +mcp-servers: + custom-api: + registry: "https://registry.example.com/servers/custom-api" + url: "https://api.example.com/mcp" + headers: + Authorization: "Bearer ${{ secrets.API_TOKEN }}" +``` + +The `registry` field is informational and does not affect server execution. It complements other configuration fields like `command`, `args`, `container`, or `url`. ## Related Documentation