/** * postgres-mcp - OAuth Resource Server * * RFC 9728 Protected Resource Metadata implementation. */ import type { ResourceServerConfig, ProtectedResourceMetadata } from "./types.js"; /** * OAuth 2.1 Resource Server (RFC 9728) */ export declare class OAuthResourceServer { private readonly config; constructor(config: ResourceServerConfig); /** * Get protected resource metadata (RFC 9728) */ getMetadata(): ProtectedResourceMetadata; /** * Get the well-known endpoint path for protected resource metadata */ getWellKnownPath(): string; /** * Verify that a scope is supported by this resource */ isScopeSupported(scope: string): boolean; /** * Get the resource identifier */ getResourceId(): string; /** * Get all supported scopes */ getSupportedScopes(): string[]; /** * Get authorization servers */ getAuthorizationServers(): string[]; /** * Generate WWW-Authenticate header for 401 responses * * @param error - Error type for the header * @param errorDescription - Human-readable error description * @returns WWW-Authenticate header value */ getWWWAuthenticateHeader(error?: string, errorDescription?: string): string; } /** * Create an OAuth resource server instance */ export declare function createOAuthResourceServer(config: ResourceServerConfig): OAuthResourceServer; //# sourceMappingURL=oauth-resource-server.d.ts.map