/**
 * Auth exchange via Gateway.
 *
 * The daemon sends OAuth codes and refresh tokens to the Gateway (never directly
 * to Supabase). The Gateway handles the Supabase interaction and returns tokens.
 *
 * See PRD.md: "auth_exchange Message" and "token_refresh Message" sections.
 */
export interface ExchangeResult {
    access_token: string;
    refresh_token: string;
    expires_at: number;
    user: {
        id: string;
        email: string;
        github_username: string;
    };
}
export interface RefreshResult {
    access_token: string;
    refresh_token: string;
    expires_at: number;
}
/**
 * Exchange an OAuth authorization code for session tokens via the Gateway.
 *
 * Opens a temporary WebSocket to the Gateway, sends an auth_exchange request,
 * and waits for the response with tokens.
 */
export declare function exchangeCodeViaGateway(code: string): Promise<ExchangeResult>;
/**
 * Refresh tokens via the Gateway.
 *
 * Opens a temporary WebSocket to the Gateway, sends a token_refresh request,
 * and waits for the response with new tokens.
 */
export declare function refreshTokenViaGateway(refreshToken: string): Promise<RefreshResult>;
//# sourceMappingURL=gateway-auth.d.ts.map