import { ApiEndpoints, DeepPartial, SessionDefinition, SessionRequestParams, DesktopSessionParams, HttpResponse, socketCreator, StreamLoginParams } from '@refinitiv-data/types'; import { AbstractSession } from '../abstract/abstract-session'; /** * Desktop sessions are used to connect applications to the data platform through the Workspace desktop application. */ export declare class DesktopSession extends AbstractSession { private sessionParams; /** * Creates a definition object for a desktop session. * @param appKey workspace application key, necessary to authenticate the specific application with the session * @return new instance of session definition */ static Definition(appKey: string): SessionDefinition; /** * Creates a definition object for a desktop session. * @param params An object literal with properties necessary to create a definition of the desktop session * @return new instance of session definition */ static Definition(params: DesktopSessionParams): SessionDefinition; get rdpUrlRoot(): string; private get baseUrl(); private get udfUrlRoot(); get tsiUrlRoot(): string; private get handshakeEndpoint(); private get uuid(); private port; private accessToken?; private tokenType?; private socketCreatorsMap; constructor(sessionParams: DesktopSessionParams); /** * This method is related to the endpoints overriding in the configuration file. * 'sessions' section in the config file contains different types of sessions, * and each session might have a specific block to override common endpoint(s) * api/url/path for this particular session. * Overridden endpoint has a higher priority then common one. * * An empty object is returned if there are no overridden endpoints */ getOverriddenEndpoints(): DeepPartial; /** * Enable cookies support */ protected get cookieJarSupport(): boolean; /** * Checks if the library is being used in a node environment * */ private isNodeEnvironment; /** * Send a request in order to validate if proxy is running and appKey is valid */ protected initialize(): Promise; protected request(sessionRequestParams: SessionRequestParams): Promise>; protected getSocketCreators(api: string, protocolName: string): Promise; protected getStreamLoginParams(): StreamLoginParams; private prepareWebSocketCreators; private getStreamingDiscoveryEndpoint; /** * * @param api Name of streaming connection in the configuration file. ('streaming/pricing/main') * @param protocol websocket protocol */ private requestWebSocketList; /** * The method attempts to set up the session port by first checking and verifying the user-specified port, * or (if none is specified) the port outputted API proxy's ".portInUse" file. If neither is valid, the method throws an exception. */ private setPort; /** * The method searches for .portInUse file created by Eikon proxy API, extracts the port number, * checks if it is valid, and returns that port number. If the port number is not valid, the method throws an exception. */ private detectPortInUse; /** * The method sends a ping request to the proxy URL formed with the specified port to verify if the port is available or not. * Throws an exception if the port is not available. The checking request timeout is 20000 ms. */ private verifyProxyUrlPort; /** * The method returns a ping url formed by the specified port number. */ private getPingUrl; private checkDefaultPorts; private emitAuthenticationSuccess; private emitAuthenticationFailed; }