Mcp Add/code/commands/cli/mcp-add
Add MCP servers.
Supported options and rules: --transport stdio|http|sse; --scope user|project; repeatable --env KEY=VALUE; repeatable --header NAME=VALUE; --timeout DURATION; repeatable --include-tool TOOL; repeatable --exclude-tool TOOL; --required.
The canonical syntax string as recorded in the catalogue. It is authoritative — it is never reconstructed from the option and argument lists below.
Subcommand of ctxdex code mcp
namestringRequiredposition 1Name or identifier of the item referenced by this command.
command_or_urlurlRequiredposition 2For stdio MCP, the executable command; for HTTP/SSE MCP, the server URL.
argsstringOptionalposition 3Additional command arguments; valid for stdio MCP transport.
yesDefaults, allowed values, conflicts and scope come from the catalogue; blank fields mean the catalogue records nothing, not that the constraint is absent.
--transport <enum>enumOptionalChoose the MCP transport protocol. Allowed values: stdio, http, sse.
stdio, http, sse--scope <enum>enumOptionalChoose the scope in which the setting, registration or package state is read or written. Allowed values: user, project.
user, project--env <string>stringOptionalPass an environment variable to a stdio MCP server; repeatable. This option may be repeated.
yes--header <string>stringOptionalPass an HTTP header to an HTTP/SSE MCP server; repeatable. This option may be repeated.
yes--timeout <duration>durationOptionalSet the MCP connection or operation timeout.
--include-tool <string>stringOptionalExpose only the named MCP tool(s); repeatable. This option may be repeated.
yes--exclude-tool <string>stringOptionalHide the named MCP tool(s); repeatable. This option may be repeated.
yes--requiredbooleanOptionalMark the MCP server as required for the relevant configuration. Default: False.
falseWith options
WITH OPTIONSctxdex code mcp add github https://mcp.example.com --transport http --scope project
Add MCP servers.
Representative options
WITH OPTIONSctxdex code mcp add github https://mcp.example.com --transport http --scope project --timeout 30s
Shows representative optional controls available for this command.
Nothing recorded — this command is offered in the default session, with no repository, authentication, capability or platform requirement attached to it.
/mcp addInteractive3 of 5 products mapped
Command-level mappings against 5 audited products, each with its documentation source and capture date. No documented equivalent means the audit found nothing in that product’s official documentation — it is not a claim that the product lacks the capability.
Every canonical command was reviewed against all 5 products in one pass captured 2026-09-18. A product with no mapping is a reviewed finding of no documented equivalent, not an unreviewed pair.
Captured 2026-09-18 · 238 commands × 5 products
gemini mcp addcodex mcp addcopilot mcp add