Oauth2 callback error: Missing client_id

Describe the problem/error/question

When I link my account using the mcp OAuth2 credential and successfully authorize, it automatically redirects to the /rest/oauth2-credential/callback address, but the page displays missing parameters

Error: Client authentication failed (e.g., unknown client, no client authentication included, or unsupported authentication method).

More details
{"error":"invalid_client","error_description":"Missing client_id"}

Failed to connect. The window can be closed now.

What is the error message (if any)?

Error: Client authentication failed (e.g., unknown client, no client authentication included, or unsupported authentication method).

More details
{"error":"invalid_client","error_description":"Missing client_id"}

Failed to connect. The window can be closed now.

Please share your workflow

(Select the nodes on your canvas and use the keyboard shortcuts CMD+C/CTRL+C and CMD+V/CTRL+V to copy and paste the workflow.)


Share the output returned by the last node

Information on your n8n setup

  • n8n version: 2.2.4
  • Database (default: SQLite): SQLite
  • n8n EXECUTIONS_PROCESS setting (default: own, main):own
  • Running n8n via (Docker, npm, n8n cloud, desktop app):desktop app
  • Operating system: windows

ensure there are no extra spaces in your client ID

Yes, I can use the same configuration in MCP Inspector, but I’m not sure why it fails in n8n

Is your n8n instance available on the web, like can other services contact it?