Tracks SEP-2127 (MCP Server Cards) as an experimental extension while the SEP
itself is under review. The schema.ts is structured to be lifted directly into
schema/draft/schema.ts of the main spec when Server Cards graduate -- only the
inlined MetaObject and Icon definitions need to be removed during migration.
- schema.ts: ServerCard, Server, Repository, Remote, Package, Argument, Input,
KeyValueInput, etc. plus inlined MetaObject and Icon
- scripts/generate-schema.ts: typescript-json-schema with 2020-12 transforms
- scripts/validate-examples.ts: ajv validator over examples/{ServerCard,Server}/
- examples/: 2 valid + 4 invalid Server Card cases, 1 valid Server case
- README: status, layout, schema URL conventions, graduation plan
- CI workflow: check + validate + format on every PR
27 lines
729 B
JSON
27 lines
729 B
JSON
{
|
|
"$schema": "https://static.modelcontextprotocol.io/schemas/v1/server.schema.json",
|
|
"name": "example-org/with-package",
|
|
"version": "0.4.2",
|
|
"description": "Server document with a locally-runnable npm package.",
|
|
"repository": {
|
|
"url": "https://github.com/example-org/with-package",
|
|
"source": "github"
|
|
},
|
|
"packages": [
|
|
{
|
|
"registryType": "npm",
|
|
"identifier": "@example-org/with-package",
|
|
"version": "0.4.2",
|
|
"runtimeHint": "npx",
|
|
"transport": { "type": "stdio" },
|
|
"environmentVariables": [
|
|
{
|
|
"name": "EXAMPLE_API_KEY",
|
|
"description": "Example API key.",
|
|
"isRequired": true,
|
|
"isSecret": true
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|