import CallInfoParams from '../models/Call/CallInfoParams'; import VertoParams from "../models/VertoParams"; import { defaultVertoCallbacks } from "../store"; import Call from "../verto/Call"; import VertinhoClient from "../verto/VertoClient"; import CallKeepParams from '../models/Call/CallKeepParams'; declare class VertoInstance { private vertoClient; private instanceCallbackListeners; private instanceCallbackListener; private instanceCallbackListenerKey; private instanceCallbacks; private activeCallUUID; private callKeepParams; private showLogs; private activeCalls; createInstance(params: VertoParams, callbacks: defaultVertoCallbacks, showLogs?: boolean, callKeepParams?: CallKeepParams): VertinhoClient; connect(): void; destroy(): void; getInstance(key?: string, callbackListeners?: any): VertinhoClient; removeInstanceCallbacks(key: string): void; /** * Make a call with given parameters. * * @param callParams Call parameters to create a call * @returns Newly created call */ makeCall(callParams: CallInfoParams): Call; /** * Start a new Call Keep call * * @param handle Number to make a call * @param displayName Visible name on system call screen */ startCallKeepCall(handle: string, displayName: string): void; /** * Answer a call if call is exist * * @param call Incoming call * @param callParams Contains information like numbers of caller and callee, display name and video state */ answerCall(call: Call, callParams?: CallInfoParams): void; /** * Insert a new call into active calls * * @param call Currenly active call for client */ insertCall(call: Call): void; /** * Remove call from active calls * * @param callId Id of call to remove from active calls */ removeCall(callId: string): void; /** * Start local stream of a call with given callId * * @param callId Id of call to start local stream */ startLocalStream(callId: string, kind?: string): void; /** * Stop local stream of a call with given callId * * @param callId Id of call to stop local stream */ stopLocalStream(callId: string, kind?: string): void; /** * Mute/Unmute local audio of a call with given callId * * @param callId Id of call to mute/unmute local audio * @param mute Auido is muted if mute value is true * @param onMuteResult Result of the operation. True if call audio track is found, otherwise false */ muteLocalAudio(callId: string, mute: boolean, onMuteResult?: Function): void; /** * Mute/Unmute local video of a call with given callId * * @param callId Id of call to mute/unmute local video * @param mute Video is muted if mute value is true * @param onMuteResult Result of the operation. True if call video track is found, otherwise false */ muteLocalVideo(callId: string, mute: boolean, onMuteResult?: Function): void; /** * Display system incoming call * * @param callInfoParams Caller information * @param call Active call to show on Call Keep UI */ displayCallKeepCall(callInfoParams: CallInfoParams, call: Call): void; /** * Hangup a call with cause code * * @param call Call to send hangup request * @param causeCode Reason to end call. If not set, send 'NORMAL_CLEARING' as a default code */ hangUpCall(call: Call, causeCode?: number): void; /** * End CallKeep call to seperate sip call from operating system call */ endCallKeepCall(): void; private onClientClose; private onCallStateChange; private onCallDestroyed; private onNewCall; private onNewCallAnswered; private onCallEnded; private onPlayLocalVideo; private onPlayRemoteVideo; } declare const VertoInstanceManager: VertoInstance; export default VertoInstanceManager;