import type { MonitorEvent } from './wire';
export interface TransportOptions {
    url: string;
    sessionId: string;
    /** Called when a flush failed (network error or non-2xx). For UI badge / console warn. */
    onError?: (err: Error) => void;
}
export declare class MonitorTransport {
    private url;
    private sessionId;
    private onError?;
    private buffer;
    private inflight;
    private timer;
    private pagehideHandler?;
    private destroyed;
    constructor(opts: TransportOptions);
    private handleVisibilityChange;
    enqueue(event: MonitorEvent): void;
    /** Async flush via fetch. No-op when in-flight or empty. */
    flush(): Promise<void>;
    /** Synchronous flush via sendBeacon, used on pagehide / visibility:hidden. */
    private flushSync;
    destroy(): void;
    private makeBatch;
}
//# sourceMappingURL=transport.d.ts.map