import type { MediaCallActor, MediaCallContact, MediaCallContactInformation } from '@rocket.chat/core-typings'; import type { CallRole } from '@rocket.chat/media-signaling'; import type { IMediaCallAgent } from './IMediaCallAgent'; import type { GetActorContactOptions, MediaCallHeader, MinimalUserData } from './common'; export interface IMediaCallCastDirector { getAgentsFromCall(call: MediaCallHeader): Promise<{ caller: IMediaCallAgent; callee: IMediaCallAgent }>; getAgentFromCall(call: MediaCallHeader, role: CallRole): Promise; getContactForActor( actor: MediaCallActor, options: GetActorContactOptions, defaultContactInfo?: MediaCallContactInformation, ): Promise; getContactForUser( user: MinimalUserData, options: GetActorContactOptions, defaultContactInfo?: MediaCallContactInformation, ): MediaCallContact | null; getContactForUserId( userId: string, options: GetActorContactOptions, defaultContactInfo?: MediaCallContactInformation, ): Promise; getContactForExtensionNumber( sipExtension: string, options: GetActorContactOptions, defaultContactInfo?: MediaCallContactInformation, ): Promise; getAgentForActorAndRole(actor: MediaCallContact, role: CallRole): Promise; }