@luxia/domain-mcp
v0.0.8
Published
Agnos MCP servers domain plugin
Readme
@luxia/domain-mcp
agnos domain plugin that owns the MCP servers category. One declaration; every agent regenerates its own format.
What it does
- Owns the
mcparray inagnos.json. - Validates declarations against a Zod schema.
- Runs an interactive
agnos mcp addflow that asks for transport, command, args, and env. - Hands each
ResolvedMcpto every active agent'shandles.mcp.onInitialize, which is responsible for rendering the right file format (.mcp.jsonfor Claude Code,.codex/config.tomlfor Codex, and so on).
The domain itself owns no on-disk artifact. Agent plugins fully rewrite their MCP config on every install, which makes the operation idempotent and immune to drift.
Install
You usually get this for free with @luxia/agnos. Standalone:
pnpm add -D @luxia/domain-mcpConfiguration
{
"mcp": [
{
"name": "github",
"transport": "stdio",
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-github"],
"env": { "GITHUB_TOKEN": "${GITHUB_TOKEN}" }
},
{
"name": "linear",
"transport": "http",
"command": "https://mcp.linear.app/sse"
}
]
}Each entry:
name(required) is the server id agents will see.transportis"stdio"(default),"sse", or"http".commandis the executable forstdioor the URL forsse/http.argsandenvare passed through tostdioservers.
CLI
| Command | What it does |
| ------------------------- | --------------------------------------------------------------------------------- |
| agnos mcp add <name> | Add a server interactively. |
| agnos mcp update <name> | Re-resolve a declared server. |
| agnos mcp remove <name> | Remove a server. Agents drop it from their generated configs on the next install. |
License
MIT.
