I’m trying to connect Asana’s MCP server (https//mcp.asana.com/v2/mcp) to Claude Code (Anthropic’s CLI tool for developers). The same Asana MCP connector works perfectly in Claude Desktop App, but fails in the CLI version.
The problem:
Claude Code CLI uses a local HTTP server for the OAuth callback (e.g. http//localhost:40128/callback). When the OAuth flow redirects to this URL, Asana rejects it with:
▎ invalid_request: The redirect_uri parameter does not match a valid url for the application.
This happens because Asana’s OAuth only accepts:
- HTTPS URLs for web applications
- urn:ietf:wg:oauth:2.0:oob for native/CLI applications
Asana does not allow http//localhost redirect URIs, which is the standard loopback redirect method for native apps per RFC 8252 - OAuth 2.0 for Native Apps .
What I’ve tried:
- Direct connection (type: “http” in .mcp.json) — fails with “Incompatible auth server: does not support dynamic client registration”
- Registered OAuth app in Asana Developer Console with http//localhost:40128/callback as redirect URI — Asana rejects the redirect_uri during authorization
- Using urn:ietf:wg:oauth:2.0:oob — the auth code is displayed in the browser, but Claude Code’s local server expects a callback and can’t receive it
- mcp-remote proxy (npx mcp-remote https//mcp.asana.com/v2/mcp) — same localhost redirect issue
Why it works in Claude Desktop but not Claude Code:
Claude Desktop uses a server-side OAuth flow with Anthropic’s pre-registered redirect URI (hosted by Anthropic). Claude Code CLI runs locally and needs a loopback redirect, which Asana blocks.
Environment:
- Windows 11
- Claude Code CLI (latest)
- Claude Desktop App (latest) — Asana connector works here
Request:
Could Asana please support http//localhost (loopback) redirect URIs for OAuth apps? This is the standard method for native/desktop OAuth clients per RFC 8252 and is supported by most OAuth providers (Google, GitHub, Microsoft, etc.). Without it, developer CLI tools like Claude Code, Cursor, and similar cannot authenticate with Asana’s MCP server.
Alternatively, if there’s a way to use a Personal Access Token with the Asana MCP server instead of OAuth, that would also solve the problem for CLI use cases.
Remark: I removed the colon from https: because new are only allowed to post two links.
Cheers
Kai