github / github/copilot-cli

MCP OAuth 3LO (Authorization Code) fails with MCP error -32042: This request requires more information.

Open
#4,371 0 comments 0 reactions 0 assignees View on GitHub
area:authentication area:mcp
Dominant language
Shell
Stars
11.2k
Forks
1.9k
Avg merge
14h 16m
Merged PRs (30d)
6

Description

### Describe the bug

When connecting to an MCP Gateway that has targets configured with OAuth 3LO (Authorization Code grant), tool invocations fail with error -32042 because the client does not support URL elicitation required for the OAuth 3LO flow.

Client should show user URL to authenticate.

### Affected version

GitHub Copilot CLI 1.0.78

### Steps to reproduce the behavior

1. Configure an MCP server target with OAuth 3LO (Authorization Code grant) authentication
2. Connect GitHub Copilot CLI to an MCP gateway that includes this target
3. Invoke any tool from the OAuth 3LO protected target

In this case AWS Bedrock AgentCore GW with MCP protocol version 2025-11-25 was used.
Correct behaviour has been verified with MCP inspector tool.

### Expected behavior

Handle URLElicitationRequiredError (-32042) responses by presenting the elicitation URL to the user and allow the user to complete the OAuth flow in a browser.

### Additional context

_No response_

Contributor guide

Open the contributing guide

Research direction

Reproduce the failure with an MCP gateway target using OAuth 3LO and invoke a protected tool, as described in the issue. Start by tracing how the CLI handles the -32042 URLElicitationRequiredError response; done means the client presents the elicitation URL, lets the user complete authentication in a browser, and then allows the tool invocation to proceed.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws
Domain
authentication, cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
50/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.