import { TransactionStatusResponse } from "../lib/status/types/index.js"; export declare class WebsocketHandler { #private; constructor(url: string); onUpdate(handler: (taskStatus: TransactionStatusResponse) => void): void; offUpdate(handler: (taskStatus: TransactionStatusResponse) => void): void; onError(handler: (error: Error) => void): void; offError(handler: (error: Error) => void): void; subscribe(taskId: string): Promise; unsubscribe(taskId: string): Promise; hasHandlers(): boolean; private _connect; private _sendWebsocketMessage; private _disconnectIfUnused; private _disconnect; private _reconnect; private _ensureIsConnected; private _awaitConnection; private _handleError; }