codex/codex-rs/codex-mcp/src
thomas 6baa076eb6 Allow extensions to select MCP protocol mode per HTTP server (#44571)
## Why

Extension-owned HTTP MCP servers previously inherited the default protocol mode. Extensions need to select a mode for their own server independently of other HTTP servers.

## What changed

- Add `McpServerContribution::SetWithProtocolMode` and re-export `McpProtocolMode` through the extension API.
- Carry the winning registration's protocol override through catalog resolution and materialization, and apply it to Streamable HTTP connections.
- Preserve existing defaults when no override is present. Selecting a protocol mode does not grant host-owned Apps cache access or environment authority.

## Testing

Add coverage for registration precedence and materialization, and extend cache isolation tests to cover explicit protocol selection. Add an integration test verifying that extension servers can select either the legacy or newer protocol while other HTTP servers retain the default mode.

GitOrigin-RevId: 606cecc03094a93258ffc433849f575020b81473
History 2026-09-10 16:02:59 +00:00
..
codex_apps Upgrade rmcp to 3.0.0 (#36001) 2026-07-29 17:38:20 +00:00
connection_manager Reuse MCP bindings while cached servers remain dormant (#44121) 2026-09-09 10:51:24 +00:00
mcp Report OAuth authentication failures in MCP status snapshots (#44359) 2026-09-10 01:05:56 +00:00
rmcp_client Report runtime MCP connection status (#40068) 2026-08-22 05:54:43 +00:00
snapshots Support package-style MCP server names (#41700) 2026-08-30 16:45:34 +00:00
agent_plugin_config.rs Add Agent Plugins MCP config parsing (#36796) 2026-08-03 20:36:59 +00:00
auth_changes.rs Notify opted-in stdio MCP servers of auth changes (#43428) 2026-09-07 10:37:46 +00:00
auth_changes_tests.rs Notify opted-in stdio MCP servers of auth changes (#43428) 2026-09-07 10:37:46 +00:00
auth_elicitation.rs Support Codex Apps auth elicitations (#19193) 2026-05-06 07:18:00 +00:00
binding.rs Keep refreshed MCP tool catalogs with their clients (#43031) 2026-09-05 15:04:46 +00:00
binding_clients.rs Limit MCP catalog pagination (#36039) 2026-07-29 22:37:09 +00:00
binding_tests.rs Propagate Apps tool refreshes to existing threads (#43900) 2026-09-08 19:56:25 +00:00
catalog.rs Allow extensions to select MCP protocol mode per HTTP server (#44571) 2026-09-10 16:02:59 +00:00
catalog_tests.rs Allow extensions to select MCP protocol mode per HTTP server (#44571) 2026-09-10 16:02:59 +00:00
client_capabilities.rs Restrict MCP user verification and add workspace-scoped identity (#43524) 2026-09-07 17:26:10 +00:00
client_capabilities_tests.rs Restrict MCP user verification and add workspace-scoped identity (#43524) 2026-09-07 17:26:10 +00:00
client_tool_catalog.rs Propagate Apps tool refreshes to existing threads (#43900) 2026-09-08 19:56:25 +00:00
codex_apps.rs [codex-apps] Filter optional file fields by tool schema (#31686) 2026-07-09 14:32:23 -07:00
connection_manager.rs Allow extensions to select MCP protocol mode per HTTP server (#44571) 2026-09-10 16:02:59 +00:00
connection_manager_tests.rs Allow extensions to select MCP protocol mode per HTTP server (#44571) 2026-09-10 16:02:59 +00:00
elicitation.rs Add opt-in MCP user-verification transport (#43352) 2026-09-07 04:33:22 +00:00
elicitation_tests.rs Restrict MCP user verification and add workspace-scoped identity (#43524) 2026-09-07 17:26:10 +00:00
event_stream.rs Prepare MCP connections for coordinated OAuth refresh (#42128) 2026-09-01 20:26:57 +00:00
executor_environment_http_client.rs Resolve HTTP MCP bearer tokens in executor environments (#39926) 2026-08-21 12:50:15 +00:00
lib.rs Add MIME-filtered resource listing for Codex Apps (#44548) 2026-09-10 14:22:21 +00:00
openai_docs_source_attribution.rs Attribute OpenAI docs MCP requests to Codex (#33424) 2026-07-15 20:54:54 +00:00
openai_docs_source_attribution_tests.rs Attribute OpenAI docs MCP requests to Codex (#33424) 2026-07-15 20:54:54 +00:00
pagination.rs Raise the host-owned Codex Apps catalog limit (#36772) 2026-08-03 17:06:46 +00:00
pagination_tests.rs Limit MCP catalog pagination (#36039) 2026-07-29 22:37:09 +00:00
plugin_config.rs Harden MCP OAuth callback handling (#40691) 2026-08-25 20:26:23 +00:00
plugin_config_tests.rs Harden MCP OAuth callback handling (#40691) 2026-08-25 20:26:23 +00:00
resource_client.rs Add MIME-filtered resource listing for Codex Apps (#44548) 2026-09-10 14:22:21 +00:00
resource_origin.rs Honor app link settings for MCP tool approvals (#42056) 2026-09-01 13:43:27 +00:00
rmcp_client.rs Propagate Apps tool refreshes to existing threads (#43900) 2026-09-08 19:56:25 +00:00
runtime.rs Add MIME-filtered resource listing for Codex Apps (#44548) 2026-09-10 14:22:21 +00:00
server.rs Prepare MCP connections for coordinated OAuth refresh (#42128) 2026-09-01 20:26:57 +00:00
server_tests.rs Preserve MCP compatibility with older executors (#39979) 2026-08-21 17:21:30 +00:00
tool_catalog_cache.rs Reuse MCP bindings while cached servers remain dormant (#44121) 2026-09-09 10:51:24 +00:00
tools.rs Propagate Apps tool refreshes to existing threads (#43900) 2026-09-08 19:56:25 +00:00
trusted_access.rs Attach verified access context to eligible plugin MCP calls (#41005) 2026-08-27 00:02:26 +00:00
trusted_access_tests.rs Add trusted access context for MCP metadata (#40992) 2026-08-26 22:54:10 +00:00
user_verification_elicitation.rs Restrict MCP user verification and add workspace-scoped identity (#43524) 2026-09-07 17:26:10 +00:00