React subtree that can access the MCP client context.
OptionalclientClient info for all servers (used for OAuth registration and server capabilities). Can be overridden per-server in addServer() options.
The optional capabilities field sets default MCP capabilities advertised to
every server managed by this provider (e.g. MCP Apps / SEP-1865 extensions).
It is merged with per-server clientOptions.capabilities (per-server takes
precedence) and is stripped from the actual MCP clientInfo wire field.
Optionalcapabilities?: Record<string, unknown>Default capabilities advertised to all servers managed by this provider.
Per-server clientOptions.capabilities are merged on top, with per-server
values taking precedence. Stripped from the MCP clientInfo wire field.
Optionaldescription?: stringClient description
Optionalicons?: { mimeType?: string; sizes?: string[]; src: string }[]Client icons (first icon used as logo_uri for OAuth)
Client name displayed on OAuth consent pages (required)
Optionaltitle?: stringClient title/display name
Client version (required)
OptionalwebsiteUrl?: stringClient website URL (used as client_uri for OAuth)
OptionaldefaultEnable automatic proxy fallback for all servers by default When enabled, if a direct connection fails with FastMCP or CORS errors, automatically retries using proxy configuration
Optionalenabled?: booleanWhether automatic proxy fallback is enabled.
OptionalproxyAddress?: stringProxy endpoint used after direct connection fails.
OptionaldefaultDefault OAuth callback URL for all servers. Can be overridden per-server via the callbackUrl option in addServer(). Useful when the app is mounted at a sub-path (e.g. /inspector) so the OAuth redirect lands on the correct route without requiring a server-side redirect shim.
OptionaldefaultDefault same-origin OAuth BFF URL for browser OAuth requests.
OptionaldefaultDefault proxy configuration for all servers Can be overridden per-server in addServer() options
Optionalheaders?: Record<string, string>Default headers sent to the MCP proxy.
OptionalproxyAddress?: stringDefault MCP proxy endpoint.
OptionaldefaultDefault connection options merged under each server's options (per-server wins).
Useful for app-wide auth UX such as preventAutoAuth or useRedirectFlow.
OptionalenableEnable RPC logging for debugging (browser only) Logs all MCP protocol messages to console
OptionalmcpInitial servers configuration (like Python MCPClient.from_dict) Servers defined here will be auto-connected on mount
OptionalonCallback when an elicitation request is received from any server
The elicitation request details
The ID of the server that sent the request
The name of the server
Function to approve the request
Function to reject the request
OptionalonCallback when a sampling request is received from any server
The sampling request details
The ID of the server that sent the request
The name of the server
Function to approve the request
Function to reject the request
OptionalonCallback when a server is added
OptionalonCallback when a server is removed
OptionalonCallback when a server's state changes
OptionalstorageStorage provider for persisting server configurations When provided, automatically loads servers on mount and saves on changes
Props for McpClientProvider