Skip to main content

Duplicate Variable Names

Yes, in different scopes. A variable either applies to all servers or is scoped to one MCP server. A name must be unique within a scope, so you can have:
  • one API_GITHUB_COM_ACCESS_TOKEN for all servers, and
  • one API_GITHUB_COM_ACCESS_TOKEN for each server that needs a different value.
A server uses its own variable first and falls back to the one for all servers. See Per-Server Variables & Credentials. Creating a second variable with the same name in the same scope is rejected with 409 Conflict.

Strategy

To use different credentials for the same provider, for example a staging and a production GitHub account:
  1. Create an MCP server for each environment.
  2. Give each server its own value for the same variable name. On the server’s Configuration tab, use Override or turn on This server only when adding the variable.
This is simpler than inventing different variable names, because the provider’s tool headers stay the same.