import type { GrawkusConfig } from './types.js';
export declare const CHATGPT_CODEX_BASE_URL = "https://chatgpt.com/backend-api/codex";
export interface OpenAICodexAuthSnapshot {
    accessToken: string;
    accountId?: string;
    email?: string;
    codexHome: string;
    authPath?: string;
    source: 'env' | 'codex-auth-file';
    accessTokenExpiresAt?: string;
}
export interface OpenAICodexAuthStatus {
    configured: boolean;
    available: boolean;
    source?: OpenAICodexAuthSnapshot['source'];
    codexHome: string;
    authPath: string;
    authMode?: string;
    hasTokens: boolean;
    hasAccessToken: boolean;
    accessTokenExpiresAt?: string;
    accessTokenExpired: boolean;
    hasAccountId: boolean;
    accountId?: string;
    email?: string;
    error?: string;
}
export declare function isOpenAICodexOAuth(config: GrawkusConfig): boolean;
export declare function resolveCodexHome(config?: Pick<GrawkusConfig, 'openaiAuth'>): string;
export declare function getCodexAuthPath(config?: Pick<GrawkusConfig, 'openaiAuth'>): string;
export declare function getOpenAICodexBaseURL(config: GrawkusConfig): string;
export declare function resolveOpenAICodexAuth(config: GrawkusConfig): OpenAICodexAuthSnapshot | null;
export declare function getOpenAICodexAuthStatus(config: GrawkusConfig): OpenAICodexAuthStatus;
export declare function openAICodexAuthInstructions(config: GrawkusConfig): string;
export declare function runCodexLogin(config: GrawkusConfig): {
    ok: boolean;
    status: number | null;
    error?: string;
};
