Claude Code 依照網路教學文章串接 Notion MCP 卻遇到 Unknown OAuth client 錯誤訊息。本文說明改用 mcp-remote 串接的成功安裝方法。
![]() |
| Generated with Gemini |
問題狀況
依照 Claude 官方網站文件 [1] 的教學步驟,嘗試加入 Notion MCP 卻遇到 Unknown OAuth client 錯誤訊息。以下使用 macOS 為例:
1. 開啟終端機 APP
2. 輸入以下指令
claude mcp add --transport http notion https://mcp.notion.com/mcp
終端機顯示
Added HTTP MCP server notion with URL: https://mcp.notion.com/mcp to local config
File modified: /Users/帳號名稱/.claude.json [project: /Users/帳號名稱]
3. 輸入指令,進入 claude 對話視窗
claude
4. 在 ❯ 符號後,輸入 /mcp 指令「查看或管理 MCP 服務器連接」(Manage MCP servers)
/mcp
可以看到「notion • A needs authentication」
5. 敲擊鍵盤上下鍵,切換到 notion,然後按 Enter → 上下鍵切換到 Authenticate,然後按 Enter
6. 中間顯示一串像亂碼的連結,程式會自動打開瀏覽器解決方式
exit 或 Ctrl+D
claude mcp remove notion3. 輸入指令,改安裝 mcp-remote
claude mcp add notion npx -- -y mcp-remote https://mcp.notion.com/mcp4. 瀏覽器跳出「Connect with Notion MCP」畫面,點選「Continue」按鈕。這次沒有遇到錯誤,而是「Authorization successful! You may close this window and return to the CLI.」成功訊息。
claude
6. 在 ❯ 符號後,輸入 /mcp 指令「查看或管理 MCP 服務器連接」(Manage MCP servers)
/mcp
可以看到「notion ✅ connected」
7. 輸入 Esc 按鍵,離開 MCP 服務器連接 (伺服器連結清單)請幫我建立新的 Notion 頁面,標題為「測試頁面」、內容為「測試用內容」
過程中會詢問
Do you want to proceed?
1. Yes
2. Yes, and don't ask again for notion - notion-create-pages commands in /Users/帳號名稱/Downloads
3. No
可以直接按 「1. Yes」,如果不想日後建立 Notion 頁面,需要反覆經過同意,則可以選擇「2. Yes, and don't ask again for notion」。
約數分鐘後,可以看到 Claude Code 依照提示詞建立了 Notion 頁面。代表 Claude Code 已經順利串接 Notion MCP。其他使用方式可參考連結 [3]。
問題分析
第一種安裝方法,產生的認證連結
https://mcp.notion.com/authorize?response_type=code&client_id=https%3A%2F%2Fclaude.ai%2Foauth%2Fclaude-
code-client-metadata&code_challenge=XXX&code_challenge_method=S
256&redirect_uri=http%3A%2F%2Flocalhost%3A52406%2Fcallback&state=XXX&resource=https%3A%2F%2Fmcp.notion.com%2Fmcp
觀察到 client_id 變數欄位值是「https://claude.ai/oauth/claude-code-client-metadata」這並非真的 client_id,導致 Notion 認證失敗,而產生「Unknown OAuth client」錯誤訊息。Claude Code 版本 2.1.80 後,在 Claude Code 專案上已經有許多使用者,回報這個問題 [4][5][6][7][8]。
「Solve Claude Code MCP Dynamic Client Registration (DCR) issues with mcp-remote」文章中 [9] 提到:
MCP 早期認證規範碎片化,導致伺服器與客戶端支援度不一致。Claude Code 目前強制要求 Dynamic Client Registration (DCR),但 DCR 在 2025-11-25 規格中只是 MAY(可選)。 ... 使用者在連接 GitHub MCP 時常遇到錯誤:“Incompatible auth server: does not support dynamic client registration” 因為 GitHub MCP 並未支援 DCR。
因此建議使用 mcp-remote 繞過使用 HTTP-based MCP Server,而改用本地程式 stdio-based MCP Server ,透過預先註冊 (pre-registered) OAuth Client 的資訊,完成認證過程。
版本資訊
2.1.119 (Claude Code)
參考資料
- 透過 MCP 將 Claude Code 連接到工具 - Claude Code Docs https://code.claude.com/docs/zh-TW/mcp
- Connecting to Notion MCP - Notion Docs https://developers.notion.com/guides/mcp/get-started-with-mcp
- Claude Desktop + MCP + Notion API Complete Setup Guide for Windows Users | Claude https://claude.ai/public/artifacts/3831d5d6-ae84-4708-b261-9afa64f7538d
- [BUG] Claude Code does not work with MCP servers that does not implement Dynamic Client Registration · Issue #3273 · anthropics/claude-code https://github.com/anthropics/claude-code/issues/3273
- MCP OAuth regression: client metadata document redirect_uris missing port causes auth failure for providers supporting CIMD · Issue #37747 · anthropics/claude-code https://github.com/anthropics/claude-code/issues/37747
- Linear MCP OAuth fails with "Invalid client" — metadata-URL clientId + ephemeral loopback port · Issue #47185 · anthropics/claude-code https://github.com/anthropics/claude-code/issues/47185
- MCP OAuth: "does not support dynamic client registration" despite clientId configured · Issue #38102 · anthropics/claude-code https://github.com/anthropics/claude-code/issues/38102
- [BUG] HTTP OAuth MCP servers silently fail in Claude Code inside Claude Desktop — no error, no guidance · Issue #46623 · anthropics/claude-code https://github.com/anthropics/claude-code/issues/46623
- Isaac on DevSecOps • Solve Claude Code MCP Dynamic Client Registration (DCR) issues with mcp-remote https://misaac.me/blog/solve-mcp-dcr-issues-with-mcp-remote/








留言
張貼留言