Skip to content

Commit a2111af

Browse files
committed
Add documentation for CLI header support
- Document --header flag usage with examples - Explain header format requirements - Clarify transport support (HTTP, SSE, not STDIO) - Add authentication examples with API keys and bearer tokens
1 parent da5595f commit a2111af

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -389,6 +389,9 @@ npx @modelcontextprotocol/inspector --cli https://my-mcp-server.example.com
389389
# Connect to a remote MCP server (with Streamable HTTP transport)
390390
npx @modelcontextprotocol/inspector --cli https://my-mcp-server.example.com --transport http --method tools/list
391391

392+
# Connect with custom headers for authentication
393+
npx @modelcontextprotocol/inspector --cli https://my-mcp-server.example.com --transport http --method tools/list --header "Authorization: Bearer your-token" --header "X-API-Key: your-api-key"
394+
392395
# Call a tool on a remote server
393396
npx @modelcontextprotocol/inspector --cli https://my-mcp-server.example.com --method tools/call --tool-name remotetool --tool-arg param=value
394397

0 commit comments

Comments
 (0)