Skip to content

Commit 8782cfe

Browse files
committed
Update server entry spec doc.
1 parent 83c8ab5 commit 8782cfe

File tree

1 file changed

+18
-53
lines changed

1 file changed

+18
-53
lines changed

docs/server-entry-spec.md

Lines changed: 18 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,10 @@
22

33
This document defines the specification for MCP server entries in the Docker MCP Gateway catalog system.
44

5-
Server entries can be found in legacy catalog files such as `.docker/mcp/catalogs/docker-mcp.yaml` under the `registry` property. They can also be used to define an mcp server by writing a yaml file and using it as a CLI flag for profiles or catalogs via `--server file://my-server.yaml`.
5+
Server entries can be defined for an mcp server by writing a yaml file and using it as a CLI flag for profiles or catalogs via `--server file://my-server.yaml`.
6+
7+
**A note about legacy catalogs:** Legacy catalogs such as `.docker/mcp/catalogs/docker-mcp.yaml` or http://desktop.docker.com/mcp/catalog/v3/catalog.yaml use a similar schema for servers under the `registry` property. However, this spec is intended for defining server configurations for MCP Profiles and OCI Catalogs. Thus, it's expected that this spec will drift from what exists in legacy catalogs.
8+
69

710
## Example Server Entry YAML
811

@@ -27,6 +30,7 @@ allowHosts:
2730
| `title` | string | **Yes** | Human-readable display name for the server. |
2831
| `description` | string | **Yes** | Brief description of the server's capabilities and purpose. |
2932
| `icon` | string | No | URL to an icon/logo representing the server. |
33+
| `readme` | string | No | URL to a README file with detailed documentation for the server. |
3034

3135
### Container Configuration (for type: "server")
3236

@@ -115,33 +119,28 @@ allowHosts:
115119
|-------|------|----------|-------------|
116120
| `name` | string | Yes | Tool identifier (unique within the server). |
117121
| `description` | string | No | Human-readable description of what the tool does. |
118-
| `parameters` | Parameters | No | JSON Schema for tool input parameters. |
119-
| `container` | Container | No | Container configuration for POCI (per-invocation) tools. |
120-
121-
**Parameters Object Structure:**
122-
123-
| Field | Type | Required | Description |
124-
|-------|------|----------|-------------|
125-
| `type` | string | Yes | JSON Schema type (typically `object`). |
126-
| `properties` | map[string]Property | Yes | Parameter definitions. |
127-
| `required` | []string | No | List of required parameter names. |
122+
| `arguments` | []ToolArgument | No | Tool argument definitions (only set for OCI catalogs, not legacy catalogs). |
123+
| `annotations` | ToolAnnotations | No | Tool annotations with hints about behavior (only set for OCI catalogs). |
128124

129-
**Property Object Structure:**
125+
**ToolArgument Object Structure:**
130126

131127
| Field | Type | Required | Description |
132128
|-------|------|----------|-------------|
133-
| `type` | string | Yes | JSON Schema type (`string`, `number`, `boolean`, `array`, etc.). |
134-
| `description` | string | No | Parameter description. |
129+
| `name` | string | Yes | Argument name. |
130+
| `type` | string | No | JSON Schema type (`string`, `number`, `boolean`, `array`, etc.). |
131+
| `desc` | string | No | Description of the argument. |
135132
| `items` | Items | No | For array types, defines the item schema. |
133+
| `optional` | boolean | No | Whether the argument is optional. Default: false. |
136134

137-
**Container Object Structure (for POCI tools):**
135+
**ToolAnnotations Object Structure:**
138136

139137
| Field | Type | Required | Description |
140138
|-------|------|----------|-------------|
141-
| `image` | string | Yes | Docker image for tool execution. |
142-
| `command` | []string | No | Command to execute in the container. |
143-
| `volumes` | []string | No | Volume mounts for tool execution. |
144-
| `user` | string | No | User to run the tool container as. |
139+
| `title` | string | No | Human-readable title for the tool. |
140+
| `readOnlyHint` | boolean | No | Hint that the tool only reads data and does not modify state. |
141+
| `destructiveHint` | boolean | No | Hint that the tool may perform destructive operations. |
142+
| `idempotentHint` | boolean | No | Hint that the tool is idempotent (repeated calls have the same effect). |
143+
| `openWorldHint` | boolean | No | Hint that the tool interacts with external systems/world. |
145144

146145
### Configuration Schema
147146

@@ -362,40 +361,6 @@ remote:
362361
icon: https://www.cloudflare.com/favicon.ico
363362
```
364363

365-
### Type: "poci"
366-
367-
POCI (Per-Invocation Container) servers where each tool invocation runs in an isolated container.
368-
369-
**Required fields:**
370-
- `name`
371-
- `type: "poci"`
372-
- `tools` (with container configurations)
373-
374-
**Example:**
375-
```yaml
376-
name: curl
377-
description: Standard curl tool.
378-
title: Curl
379-
type: poci
380-
tools:
381-
- name: curl
382-
description: Run a curl command.
383-
parameters:
384-
type: object
385-
properties:
386-
args:
387-
type: array
388-
description: The arguments to pass to curl
389-
items:
390-
type: string
391-
required:
392-
- args
393-
container:
394-
image: alpine/curl@sha256:91d382c9e54af78781801b670ae3fbba5af04adf3274ba51960ab0030a417099
395-
command:
396-
- '{{args|into}}'
397-
```
398-
399364
## Best Practices
400365

401366
1. **Naming**: Use lowercase, hyphen-separated names (e.g., `github-official`, `aws-core-mcp-server`)

0 commit comments

Comments
 (0)