import { ClientOption } from '../../model/client_option'; export type UtaWsPrimitive = string | number | boolean | null; export type UtaWsValue = UtaWsPrimitive | UtaWsValue[] | { [key: string]: UtaWsValue; }; export interface UtaPushEvent> { T: string; P?: string | number; t?: string; d: T; } export type UtaPushCallback> = (event: UtaPushEvent) => void | Promise; export type UtaPushTradeType = 'SPOT' | 'FUTURES'; export interface UtaPushSubscription { channel: string; callback: UtaPushCallback; symbols?: string[]; symbol?: string; tradeType?: string; accountType?: string; parameters?: Record; } /** * WebSocket transport for the direct UTA public and private push protocols. * * The UTA endpoints do not use the legacy token handshake, so this intentionally has a separate * implementation from DefaultWsService. */ export declare class UtaPushWsService { private readonly option; private readonly privateChannel; private readonly endpoint; private readonly tradeType?; private readonly signer?; private socket?; private started; private connected; private reconnectAttempts; private reconnectTimer?; private pingTimer?; private pongTimer?; private pendingPingId?; private pingInterval; private pingTimeout; private pendingAcks; private subscriptions; static public(option: ClientOption, tradeType: UtaPushTradeType): UtaPushWsService; static private(option: ClientOption): UtaPushWsService; private constructor(); start(): Promise; stop(): Promise; subscribe(subscription: UtaPushSubscription): Promise; unsubscribe(id: string): Promise; private dial; private afterWelcome; private authenticate; private sendSubscription; private sendAndAwaitAck; private handleMessage; private dispatch; private matches; private schedulePing; private handleDisconnect; private validateSubscription; private parseMessage; private isWelcome; private isPong; private clearTimers; private rejectPending; private positiveNumber; private notify; private toError; }