[BUG]
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report (please file separate reports for different bugs)
- [x] I am using the latest version of Claude Code
What's Wrong?
The Notion MCP server (https://mcp.notion.com/mcp) shows "✓ connected" in /mcp menu but fails to authenticate for actual use. The OAuth flow works in Claude Desktop but not in Claude Code CLI.
When checking claude mcp get notion, the status shows "! Needs authentication" despite showing "connected" in the /mcp menu.
Direct access to the MCP URL returns: {"error":"invalid_token","error_description":"Missing or invalid access token"}
What Should Happen?
After running claude mcp add --transport http notion https://mcp.notion.com/mcp and completing the OAuth flow via /mcp, the Notion MCP tools should become available and OAuth tokens should be stored in ~/.claude.json for authentication.
Error Messages/Logs
Status: ! Needs authentication
Direct URL test error:
{"error":"invalid_token","error_description":"Missing or invalid access token"}
Config shows no auth tokens:
"mcpServers": {
"notion": {
"type": "http",
"url": "https://mcp.notion.com/mcp"
}
}
Steps to Reproduce
- Run: claude mcp add --transport http notion https://mcp.notion.com/mcp
- Run: /mcp command in Claude Code
- Observe: "claude.ai Notion • ✓ connected" appears
- Run: claude mcp get notion
- Observe: Status shows "! Needs authentication"
- Check: cat ~/.claude.json
- Observe: No OAuth tokens stored for notion MCP server
Claude Model
None
Is this a regression?
I don't know
Last Working Version
_No response_
Claude Code Version
2.1.29
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
VS Code integrated terminal
Additional Information
Root cause: Claude Code CLI is authenticated with claude.ai but OAuth tokens for MCP servers are not shared/accessible. Claude Desktop likely has a browser-based OAuth flow that Claude Code lacks.
Expected config structure (not present):
"mcpServers": {
"notion": {
"type": "http",
"url": "https://mcp.notion.com/mcp",
"auth": {
"type": "oauth",
"token": "..."
}
}
}
This works in Claude Desktop, suggesting the issue is specific to Claude Code CLI's OAuth handling for MCP servers.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗