@twilio/plugin-microvisor
Version:
Interact with your Twilio Microvisor devices
32 lines (31 loc) • 1.06 kB
TypeScript
export = DeviceLogClient;
declare class DeviceLogClient extends EventEmitter {
constructor(opts: any);
twilioClient: any;
tokenRequestOpts: any;
enableLoggingRequestOpts: any;
websocketUrl: any;
reconnectRetryCount: number;
connectionEstablished: boolean;
connect(): Promise<void>;
ws: WebSocket | undefined;
reconnectWithBackoff(): Promise<void>;
getToken(): Promise<any>;
enableDeviceLogging(): Promise<true | undefined>;
onOpen(): Promise<void>;
refreshDeviceLoggingHandle: NodeJS.Timer | undefined;
pingIntervalHandle: NodeJS.Timer | undefined;
onClose(code: any, _reason: any): void;
onRefreshDeviceLoggingInterval(): Promise<void>;
onPingInterval(): void;
pingTimeout: NodeJS.Timeout | null | undefined;
onPong(): void;
onPingTimeout(): void;
onUnexpectedResponse(_req: any, _res: any): void;
onError(err: any): void;
write(data: any): void;
close(): void;
cleanup(): void;
}
import EventEmitter = require("events");
import WebSocket = require("ws");