import type { ProviderSecret } from '../credentials/CredentialVault'; import type { GatewayDeployment } from '../auth/InvocationTokenCodec'; import type { SessionImportProfile } from './SessionImportProfiles'; export interface LocalSessionImportResult { secret: ProviderSecret; /** * How the imported credential authenticates upstream. The import itself is * local, but an imported subscription session is still an OAuth credential. */ credentialAuthMode?: 'deviceCodeOAuth' | 'local'; accountLabel?: string; metadata?: Record; } export interface LocalSessionImportInput { deployment: GatewayDeployment; } export interface LocalSessionImportAdapter { provider: string; offeringId: string; importSession(input: LocalSessionImportInput): Promise; } export interface FileSessionImportAdapterOptions { profile: SessionImportProfile; homeDir?: string; readFile?: (filePath: string, encoding: BufferEncoding) => Promise; maxBytes?: number; } export declare class FileSessionImportAdapter implements LocalSessionImportAdapter { readonly provider: string; readonly offeringId: string; private readonly profile; private readonly homeDir; private readonly readFile; private readonly maxBytes; constructor(options: FileSessionImportAdapterOptions); importSession(input: LocalSessionImportInput): Promise; private readSessionFile; }