import type { ShortcutXLModelStreamErrorDetails } from '../contracts/model-stream.js';
export declare const SHORTCUT_STREAM_IDLE_TIMEOUT_MS = 180000;
export type ShortcutStreamEvent = {
    event: 'text_start';
    payload: {
        content_index: number;
    };
} | {
    event: 'text_delta';
    payload: {
        content_index: number;
        delta: string;
    };
} | {
    event: 'thinking_start';
    payload: {
        content_index: number;
    };
} | {
    event: 'thinking_delta';
    payload: {
        content_index: number;
        delta: string;
    };
} | {
    event: 'thinking_end';
    payload: {
        content_index: number;
        signature: string;
    };
} | {
    event: 'thinking_redacted';
    payload: {
        content_index: number;
        signature: string;
    };
} | {
    event: 'toolcall_start';
    payload: {
        content_index: number;
        id: string;
        name: string;
    };
} | {
    event: 'toolcall_delta';
    payload: {
        content_index: number;
        delta: string;
    };
} | {
    event: 'toolcall_end';
    payload: {
        content_index: number;
        id: string;
        name: string;
        arguments: string;
    };
} | {
    event: 'done';
    payload: {
        stop_reason: string;
        usage: Record<string, number>;
    };
} | {
    event: 'error';
    payload: {
        message: string;
        provider_error_type?: ShortcutXLModelStreamErrorDetails['providerErrorType'];
        retry_after_ms?: number;
        retryable?: boolean;
        status?: number;
    };
};
export declare function readShortcutStream(response: Response, onEvent: (event: ShortcutStreamEvent) => void, idleTimeoutMs?: number, observers?: {
    onBytes?: (length: number) => void;
    onEvent?: () => void;
}): Promise<void>;
//# sourceMappingURL=stream-sse.d.ts.map