/// import WS from 'isomorphic-ws'; import RingCentral from '../..'; import { RestRequestConfig, RestResponse, RestMethod } from '../../Rest'; import SdkExtension from '..'; export declare type WebSocketOptions = { server: string; restOverWebSocket?: boolean; }; export declare type WsgEvent = { data: string; }; export declare type WsgMeta = { type: 'ClientRequest' | 'ServerNotification' | 'Error'; messageId: string; status: number; headers: { [key: string]: string; }; }; declare class WebSocketExtension extends SdkExtension { restOverWebsocket: boolean; constructor(options: WebSocketOptions); install(rc: RingCentral): void; static sandboxServer: string; static productionServer: string; rc: RingCentral; server: string; ws: WS; opened: boolean; static splitWsgData(wsgData: string): [WsgMeta, any]; waitForOpen(): Promise; revoke(): Promise; subscribe(eventFilters: string[], callback: (body: {}) => void): Promise; request(method: RestMethod, endpoint: string, content?: {}, queryParams?: {}, config?: RestRequestConfig): Promise>; } export default WebSocketExtension;