Repository navigation
docs(unstable-v2): align the name uniqueness rules for mcpServers and env - #2890
Merged
Merged
Conversation
… env Two name uniqueness rules differed between places that state them. - The session setup page requires each MCP server `name` to be unique within `mcpServers` and says Agents reject duplicates with `-32602`. The schema descriptions of `name` did not say so. They now do. - `env` names were MUST be unique for terminal authentication, with no rule for a Client that receives duplicates, and SHOULD be unique for stdio MCP servers, where the last entry wins. Terminal authentication now uses the stdio rule: each entry SHOULD have a unique name, and otherwise the last entry with a given name wins. The terminal authentication change is on the authentication page, in the `AuthMethodTerminal` schema description, in the migration guide and in the Auth Methods RFD.
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
Two name uniqueness rules differed between the places that state them.
name: the session setup page requires eachnameto be unique withinmcpServersand says Agents reject duplicates with-32602. The schema descriptions ofnamedid not mention it.envnames: terminal authentication said every entry MUST have a uniquenameand gave no rule for a Client that receives duplicates. Stdio MCP servers say each entry SHOULD have a uniquenameand that the last entry wins (docs(schema): reject duplicate stdio env names #2693).Changes
name: thenamedescription onMcpServerStdio,McpServerHttpandMcpServerAcpnow says it MUST be unique withinmcpServersand that Agents reject a request with a duplicatenamewith-32602. The page is unchanged.env: eachenventry SHOULD have a uniquename. Otherwise the last entry with a given name wins. This is the stdio MCP rule, without the option to reject, because the entries arrive in theinitializeresponse. Changed in:draft/copyAuthMethodTerminal.envschema descriptionThe schema changes are description text only. They regenerate
schema/v2/schema.json,schema/v2/schema.unstable.jsonand bothschema.mdxpages.Implementations
Checked on 2026-11-19 against the default branch of each repository.
enventries into a map in order, so the last entry with a given name already wins.claude-agent-acpadvertises terminal methods withargsand noenv.Checks
cargo fmtand the spell check pass.