import type { McpToolContext } from '../types.js'; import { getApiDescriptionFromFs } from '../docs-mcp/tools/openapi/utils.js'; export type UpstreamAuthScheme = { kind: 'raw'; } | { kind: 'bearer'; } | { kind: 'apiKey'; header: string; } | { kind: 'cookie'; name: string; } | { kind: 'oauth2ClientCredentials'; tokenUrl: string; scopes: string[]; }; export type UpstreamAuthRoute = { pattern: RegExp; path: string; method: string; schemes: string[]; }; export type UpstreamApiAuth = { schemes: Record; defaultScheme: string; routes: UpstreamAuthRoute[]; descriptions?: Record; }; export type SchemeChoice = { name: string; label: string; description?: string; }; type SecuritySchemeLoader = typeof getApiDescriptionFromFs; export declare const DEFAULT_SCHEME_NAME = "default"; export declare function resolveUpstreamApiAuth(context: McpToolContext, apiRelativePath: string, loadDescription?: SecuritySchemeLoader): Promise; export declare function schemeChoicesOf(auth: UpstreamApiAuth, names: readonly string[]): SchemeChoice[]; export declare function credentialHeadersOf(schemes: Record): string[]; export declare function orderedSchemesOf(schemes: Record): string[]; export declare function operationsForScheme(auth: UpstreamApiAuth, scheme: string): string[]; export {}; //# sourceMappingURL=upstream-auth-scheme.d.ts.map