[DOCS] Documentation: Wrong parameter order - server name must precede --env in MCP setup

Resolved 💬 2 comments Opened Feb 13, 2026 by kmamedick Closed Feb 16, 2026

Documentation Type

Incorrect/outdated documentation

Documentation Location

https://code.claude.com/docs/en/mcp

Section/Topic

option-3-add-a-local-stdio-server

Current Documentation

Current (Incorrect) Documentation

claude mcp add --transport stdio --env AIRTABLE_API_KEY=YOUR_KEY airtable \
  -- npx -y airtable-mcp-server

What's Wrong or Missing?

Error Produced

When following the documented syntax, users get this error:

Invalid environment variable format: airtable, environment variables should be added as: -e KEY1=value1 -e KEY2=value2

Suggested Improvement

Correct Syntax

The server name must come before any --env flags:

claude mcp add --transport stdio airtable \
  --env AIRTABLE_API_KEY=YOUR_KEY \
  -- npx -y airtable-mcp-server

Suggested Fix

Update the documentation example to show the correct parameter order. The current example misleads users about where to place the server name in relation to environment variables.

Impact

High - Prevents users from using a feature

Additional Context

Using claude code version 2.1.41

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗