import { type TurboModule } from 'react-native'; import type { EventEmitter } from 'react-native/Libraries/Types/CodegenTypes'; export interface Spec extends TurboModule { setupiOS(options: { supportsVideo: boolean; maximumCallsPerCallGroup: number; maximumCallGroups: number; handleType: string; sound: string | null; imageName: string | null; callsHistory: boolean; displayCallTimeout: number; skipIncomingPushInForeground: boolean; }): void; setupAndroid(options: { incomingChannel: { id: string; name: string; sound: string; vibration: boolean; }; ongoingChannel: { id: string; name: string; }; notificationTexts?: { accepting?: string; rejecting?: string; }; skipIncomingPushInForeground: boolean; }): void; wireAudioEngineSubscription(): void; unwireAudioEngineSubscription(): void; setShouldRejectCallWhenBusy(shouldReject: boolean): void; setDefaultAudioDeviceEndpointType(endpointType: string): void; canPostNotifications(): boolean; /** * Whether audio routing is backed by the Jetpack Telecom stack on this device. * Android: true on API 26+. iOS: always false (CallKit path uses its own bypass). */ isTelecomBacked(): boolean; /** Call ids currently registered with Telecom (Android). Empty on iOS. */ getRegisteredCallIds(): Array; /** * Resolves a JSON string snapshot `{ endpoints: [{id,name,type}], currentEndpoint }` * of the Telecom audio endpoints for the given call (Android). Resolves an empty * snapshot on iOS / when the call is unknown. */ getAvailableAudioEndpoints(callId: string): Promise; /** Requests a Telecom audio-endpoint change by endpoint id (Android). */ requestAudioEndpointChange(callId: string, endpointId: string): Promise; getInitialEvents(): Array<{ eventName: string; params: { callId?: string; cause?: string; muted?: boolean; hold?: boolean; source?: string; phase?: string; reason?: string; shouldResume?: boolean; call_cid?: string; sender?: string; type?: string; created_by_id?: string; created_by_display_name?: string; call_display_name?: string; receiver_id?: string; video?: string; version?: string; }; }>; getInitialVoipEvents(): Array<{ eventName: string; params: { token?: string; aps?: { 'thread-id': string; 'mutable-content': number; alert: { title: string; }; category: string; sound: string; }; stream?: { sender: string; created_by_id: string; body: string; title: string; call_display_name: string; created_by_display_name: string; version: string; type: string; receiver_id: string; call_cid: string; video: string; }; }; }>; setCurrentCallActive(callId: string): Promise; displayIncomingCall(callId: string, phoneNumber: string, callerName: string, hasVideo: boolean, displayOptions?: { displayTitle?: string; }): Promise; answerIncomingCall(callId: string): Promise; startCall(callId: string, phoneNumber: string, callerName: string, hasVideo: boolean, displayOptions?: { displayTitle?: string; }): Promise; updateDisplay(callId: string, phoneNumber: string, callerName: string, displayOptions?: { displayTitle?: string; }): Promise; isCallTracked(callId: string): boolean; hasRegisteredCall(): boolean; endCallWithReason(callId: string, reason: number): Promise; endCall(callId: string): Promise; setMutedCall(callId: string, isMuted: boolean): Promise; setOnHoldCall(callId: string, isOnHold: boolean): Promise; startBackgroundTask(taskName: string, timeout: number): Promise; stopBackgroundTask(taskName: string): Promise; fulfillAnswerCallAction(callId: string, didFail: boolean): void; fulfillEndCallAction(callId: string, didFail: boolean): void; registerVoipToken(): void; stopService(): Promise; readonly onNewEvent: EventEmitter<{ eventName: string; params: { callId?: string; cause?: string; muted?: boolean; hold?: boolean; source?: string; phase?: string; reason?: string; shouldResume?: boolean; call_cid?: string; sender?: string; type?: string; created_by_id?: string; created_by_display_name?: string; call_display_name?: string; receiver_id?: string; video?: string; version?: string; }; }>; readonly onNewVoipEvent: EventEmitter<{ eventName: string; params: { token: string; aps: { 'thread-id': string; 'mutable-content': number; alert: { title: string; }; category: string; sound: string; }; stream: { sender: string; created_by_id: string; body: string; title: string; call_display_name: string; created_by_display_name: string; version: string; type: string; receiver_id: string; call_cid: string; video: string; }; }; }>; log(message: string, level: 'debug' | 'info' | 'warn' | 'error'): void; } declare const CallingxModule: Spec; export default CallingxModule; //# sourceMappingURL=NativeCallingx.d.ts.map