/**
 * @license
 * Copyright 2025 Vybestack LLC
 * SPDX-License-Identifier: Apache-2.0
 */
/**
 * @plan PLAN-20250214-CREDPROXY.P26
 * @plan:PLAN-20250214-CREDPROXY.P26
 * @plan:PLAN-20250214-CREDPROXY.P24
 * @requirement R17.1-R17.3, R18.1, R19.1, R20.1-R20.9
 * @pseudocode analysis/pseudocode/008-oauth-session-manager.md
 */
export interface OAuthSession {
    sessionId: string;
    provider: string;
    bucket: string;
    flowType: 'pkce_redirect' | 'device_code' | 'browser_redirect';
    flowInstance: unknown;
    codeVerifier?: {
        codeVerifier: string;
    };
    deviceCode?: string;
    pollIntervalMs?: number;
    abortController?: AbortController;
    result?: {
        token: unknown;
    } | {
        error: string;
        code: string;
    };
    createdAt: number;
    peerIdentity: unknown;
    used: boolean;
}
export declare class PKCESessionStore {
    private readonly sessions;
    private readonly sessionTimeoutMs;
    private gcInterval;
    constructor(sessionTimeoutMs?: number);
    startGC(): void;
    sweepExpired(): void;
    createSession(provider: string, bucket: string, flowType: OAuthSession['flowType'], flowInstance: unknown, peerIdentity: unknown): string;
    getSession(sessionId: string, peerIdentity: unknown): OAuthSession;
    markUsed(sessionId: string): void;
    removeSession(sessionId: string): void;
    clearAll(): void;
    private isUidPeerIdentity;
}
