type RivetConfig = {
    authToken?: string;
    refreshToken?: string;
    email?: string;
    userId?: string;
    proxyUrl?: string;
    anonymousId?: string;
    telemetryIdentifiedEmail?: string;
    telemetryIdentifiedUserId?: string;
};
/**
 * ConfigManager handles local storage of Rivet configuration
 * Stores JWT tokens and user preferences in ~/.rivet/config.json
 */
declare class ConfigManager {
    private configPath;
    private config;
    constructor();
    /**
     * Load configuration from disk
     */
    private loadConfig;
    /**
     * Save configuration to disk
     */
    private saveConfig;
    /**
     * Set authentication tokens, email, and (optionally) the Supabase user id.
     * `userId` is the canonical cross-surface identity — when omitted, an
     * existing stored value is preserved (callers that don't have it shouldn't
     * clobber it).
     */
    setAuth(token: string, email: string, refreshToken?: string, userId?: string): void;
    /**
     * Get authentication token
     */
    getAuthToken(): string | undefined;
    /**
     * Get refresh token
     */
    getRefreshToken(): string | undefined;
    /**
     * Get user email
     */
    getEmail(): string | undefined;
    /**
     * Get the canonical Supabase user id. Falls back to the request-scoped
     * context, then to the stored value, and finally backfills it by decoding
     * the `sub` claim of the stored access token (no verification — we already
     * trust the token locally). Backfill persists so we only decode once.
     */
    getUserId(): string | undefined;
    /**
     * Get the user's display name (e.g. "Sam Gorman"), decoded from the access
     * token's `user_metadata`. Not all tokens carry it (e.g. email-only logins),
     * so callers should fall back to the email for initials. Decoded on demand —
     * the token is the source of truth, so nothing is persisted here.
     */
    getDisplayName(): string | undefined;
    /**
     * Check if user is authenticated
     */
    isAuthenticated(): boolean;
    /**
     * Clear authentication (logout)
     */
    clearAuth(): void;
    /**
     * Set proxy URL
     */
    setProxyUrl(url: string): void;
    /**
     * Get or create a persistent anonymous ID for telemetry.
     * Generated once on first call and stored in config.json.
     */
    getAnonymousId(): string;
    /**
     * Email last identified to PostHog. Used to suppress redundant alias/identify
     * calls on subsequent process starts — posthog-node has no built-in dedup,
     * so each call would emit a fresh $create_alias event.
     */
    getTelemetryIdentifiedEmail(): string | undefined;
    setTelemetryIdentifiedEmail(email: string): void;
    /**
     * Supabase user id last identified to PostHog. Used to suppress redundant
     * alias/identify calls once analytics identity is keyed on user id.
     */
    getTelemetryIdentifiedUserId(): string | undefined;
    setTelemetryIdentifiedUserId(userId: string): void;
    /**
     * Get proxy URL
     */
    getProxyUrl(): string;
    /**
     * Get full config
     */
    getConfig(): RivetConfig;
    /**
     * Get config file path for debugging
     */
    getConfigPath(): string;
}
export declare const getConfigManager: () => ConfigManager;
export {};
//# sourceMappingURL=ConfigManager.d.ts.map