export { A as AuthorizationDiscoverySnapshot, a as AuthorizationPlanCapabilities, b as AuthorizationPlanInput, C as ConformanceSuiteId, c as ConformanceSupport, E as EffectiveSandboxCsp, d as EffectiveSandboxPermissions, M as MCP_UI_EXTENSION_ID, e as MCP_UI_RESOURCE_MIME_TYPE, O as OAuthAuthorizationRequestResult, f as OAuthProtocolMode, g as OAuthRegistrationMode, h as OAuthRegistrationStrategy, i as OAuthStateMachineRunConfig, j as OAuthStateMachineRunResult, k as OAuthTraceProjectionContext, l as OAuthTraceSnapshot, m as OAuthTraceStepSnapshot, n as OAuthTraceStepStatus, P as PROTOCOL_VERSION_INFO, R as ResolveSandboxCspArgs, o as ResolveSandboxPermissionsArgs, p as ResolvedAuthorizationPlan, q as ResourceDeclaredCsp, r as RunServerDoctorInput, S as SandboxCspDomainSet, s as SandboxCspMode, t as SandboxCspPolicy, u as SandboxPermissionsMode, v as SandboxPermissionsPolicy, w as ServerDoctorDependencies, x as applyRuntimeClientCapabilities, y as canRunConformance, z as createOAuthStateMachine, B as createOAuthTraceProjectionContext, D as getDefaultClientCapabilities, F as getDefaultRegistrationStrategy, G as getStepIndex, H as getStepInfo, I as getSupportedRegistrationStrategies, J as isHttpServerConfig, K as mergeClientCapabilities, L as normalizeClientCapabilities, N as projectOAuthTraceSnapshot, Q as resolveAuthorizationPlan, T as resolveRegistrationStrategies, U as resolveSandboxCsp, V as resolveSandboxPermissions, W as runOAuthStateMachine } from './sandbox-policy-0r2_ft6V.js';
import { O as OAuthProtocolVersion, j as OAuthDynamicRegistrationMetadata, R as RegistrationStrategy2025_03_26, k as RegistrationStrategy2025_06_18, l as RegistrationStrategy2025_11_25, m as OAuthFlowState } from './server-doctor-core-D4xjC7Kq.js';
export { C as ConnectedServerDoctorState, E as EMPTY_OAUTH_FLOW_STATE, H as HttpHistoryEntry, I as InfoLogEntry, n as InfoLogLevel, L as LogErrorDetails, o as OAuthFlowStep, q as OAuthRequestExecutor, s as OAuthRequestResult, t as OAuthStateMachine, P as ProbeHttpAttempt, a as ProbeInitializeInfo, b as ProbeMcpServerConfig, c as ProbeMcpServerResult, d as ProbeOAuthDetails, e as ProbeTransportResult, f as ServerDoctorCheck, g as ServerDoctorChecks, h as ServerDoctorConnection, i as ServerDoctorError, S as ServerDoctorResult, r as redactSensitiveValue } from './server-doctor-core-D4xjC7Kq.js';
export { B as BaseServerConfig, C as ClientCapabilityOptions, E as ExecuteToolArguments, H as HttpServerConfig, L as ListToolsResult, e as MCPClientManagerConfig, f as MCPConnectionStatus, g as MCPGetPromptResult, h as MCPListTasksResult, b as MCPPrompt, i as MCPPromptListResult, j as MCPReadResourceResult, d as MCPResource, k as MCPResourceListResult, c as MCPResourceTemplate, l as MCPResourceTemplateListResult, M as MCPServerConfig, m as MCPTask, n as MCPTaskStatus, S as ServerSummary, o as StdioServerConfig, T as TaskOptions } from './types-BJY6bi4K.js';
export { b as CompatibleProtocol, C as CustomProvider, H as Host, L as LLMProvider } from './index-B5O2YzC_.js';
import { OAuthClientProvider, AuthResult, AuthorizationServerMetadata, OpenIdProviderDiscoveryMetadata, OAuthMetadata, OAuthProtectedResourceMetadata, OAuthServerInfo, OAuthClientInformationMixed, OAuthTokens, OAuthClientMetadata, OAuthClientInformationFull } from '@modelcontextprotocol/client';
export { OAuthClientInformation, OAuthClientInformationFull, OAuthClientMetadata, OAuthClientProvider, OAuthDiscoveryState, OAuthMetadata, OAuthProtectedResourceMetadata, OAuthTokens } from '@modelcontextprotocol/client';
export { a as MCP_PROTOCOL_VERSIONS, M as McpProtocolVersion, i as isKnownProtocolVersion, b as isStatelessProtocolVersion } from './mcp-protocol-version-cf74324S.js';
export { C as CspDomainSet, H as HostConnectionDefaults, a as HostInit, b as HostJson, c as HostMcp, d as HostServerOverride, e as HostStyleId, M as McpAppsCapabilities, O as OpenAiAppsCapabilities, S as ServerId } from './public-types-c84qENXu.js';
import 'ai';

type FetchFn = typeof fetch;
type DiscoverAuthorizationServerMetadataOptions = {
    fetchFn?: FetchFn;
    protocolVersion?: string;
};
type DiscoverOAuthMetadataOptions = {
    authorizationServerUrl?: string | URL;
    protocolVersion?: string;
};
type DiscoverProtectedResourceMetadataOptions = {
    resourceMetadataUrl?: string | URL;
    protocolVersion?: string;
};
type DiscoverOAuthServerInfoOptions = {
    resourceMetadataUrl?: string | URL;
    fetchFn?: FetchFn;
};
type StartAuthorizationOptions = {
    metadata?: OAuthMetadata | AuthorizationServerMetadata;
    clientInformation: OAuthClientInformationMixed;
    redirectUrl: string | URL;
    scope?: string;
    state?: string;
    resource?: URL;
};
type ExchangeAuthorizationOptions = {
    metadata?: OAuthMetadata | AuthorizationServerMetadata;
    clientInformation: OAuthClientInformationMixed;
    authorizationCode: string;
    codeVerifier: string;
    redirectUri: string | URL;
    resource?: URL;
    addClientAuthentication?: OAuthClientProvider["addClientAuthentication"];
    fetchFn?: FetchFn;
};
type FetchTokenOptions = {
    metadata?: OAuthMetadata | AuthorizationServerMetadata;
    resource?: URL;
    authorizationCode?: string;
    scope?: string;
    fetchFn?: FetchFn;
};
type RegisterClientOptions = {
    metadata?: OAuthMetadata | AuthorizationServerMetadata;
    clientMetadata: OAuthClientMetadata;
    scope?: string;
    fetchFn?: FetchFn;
};
type OAuthServerMetadata = AuthorizationServerMetadata | OpenIdProviderDiscoveryMetadata;
declare function auth(provider: OAuthClientProvider, options: {
    serverUrl: string | URL;
    authorizationCode?: string;
    scope?: string;
    resourceMetadataUrl?: string | URL;
    fetchFn?: FetchFn;
}): Promise<AuthResult>;
declare function selectResourceURL(serverUrl: string | URL, provider: OAuthClientProvider, resourceMetadata?: OAuthProtectedResourceMetadata): Promise<URL | undefined>;
declare function discoverOAuthProtectedResourceMetadata(serverUrl: string | URL, opts?: DiscoverProtectedResourceMetadataOptions, fetchFn?: FetchFn): Promise<OAuthProtectedResourceMetadata>;
declare function discoverOAuthMetadata(issuer: string | URL, { authorizationServerUrl, protocolVersion, }?: DiscoverOAuthMetadataOptions, fetchFn?: FetchFn): Promise<OAuthMetadata | undefined>;
declare function discoverAuthorizationServerMetadata(authorizationServerUrl: string | URL, { fetchFn, protocolVersion, }?: DiscoverAuthorizationServerMetadataOptions): Promise<OAuthServerMetadata | undefined>;
declare function discoverOAuthServerInfo(serverUrl: string | URL, opts?: DiscoverOAuthServerInfoOptions): Promise<OAuthServerInfo>;
declare function startAuthorization(authorizationServerUrl: string | URL, { metadata, clientInformation, redirectUrl, scope, state, resource, }: StartAuthorizationOptions): Promise<{
    authorizationUrl: URL;
    codeVerifier: string;
}>;
declare function exchangeAuthorization(authorizationServerUrl: string | URL, { metadata, clientInformation, authorizationCode, codeVerifier, redirectUri, resource, addClientAuthentication, fetchFn, }: ExchangeAuthorizationOptions): Promise<OAuthTokens>;
declare function fetchToken(provider: OAuthClientProvider, authorizationServerUrl: string | URL, { metadata, resource, authorizationCode, scope, fetchFn, }?: FetchTokenOptions): Promise<OAuthTokens>;
declare function registerClient(authorizationServerUrl: string | URL, { metadata, clientMetadata, scope, fetchFn, }: RegisterClientOptions): Promise<OAuthClientInformationFull>;

declare const MCPJAM_LOGO_URI = "https://www.mcpjam.com/mcp_jam_2row.png";
declare const DEFAULT_MCPJAM_CLIENT_ID_METADATA_URL = "https://www.mcpjam.com/.well-known/oauth/client-metadata.json";
declare const MCPJAM_CLIENT_URI = "https://github.com/MCPJam/inspector";
declare function getBrowserDebugDynamicRegistrationMetadata(protocolVersion: OAuthProtocolVersion): Partial<OAuthDynamicRegistrationMetadata>;

/**
 * Shared types for OAuth state machines
 */
/**
 * Action definition for sequence diagram
 * Used to build the visual representation of OAuth flow steps
 */
interface DiagramAction {
    id: string;
    label: string;
    description: string;
    from: string;
    to: string;
    details?: Array<{
        label: string;
        value: any;
    }>;
}

type OAuthSequenceActionInput = {
    protocolVersion: OAuthProtocolVersion;
    registrationStrategy: RegistrationStrategy2025_03_26 | RegistrationStrategy2025_06_18 | RegistrationStrategy2025_11_25;
    flowState: OAuthFlowState;
};
declare function buildOAuthSequenceActions({ protocolVersion, registrationStrategy, flowState, }: OAuthSequenceActionInput): DiagramAction[];

export { DEFAULT_MCPJAM_CLIENT_ID_METADATA_URL, MCPJAM_CLIENT_URI, MCPJAM_LOGO_URI, OAuthDynamicRegistrationMetadata, OAuthFlowState, OAuthProtocolVersion, RegistrationStrategy2025_03_26, RegistrationStrategy2025_06_18, RegistrationStrategy2025_11_25, auth, buildOAuthSequenceActions, discoverAuthorizationServerMetadata, discoverOAuthMetadata, discoverOAuthProtectedResourceMetadata, discoverOAuthServerInfo, exchangeAuthorization, fetchToken, getBrowserDebugDynamicRegistrationMetadata, registerClient, selectResourceURL, startAuthorization };
