Guide
How to use Incoming Call Kit in Capacitor
Using @capgo/capacitor-incoming-call-kit
Capacitor API for presenting a native incoming-call surface.
Install
bun add @capgo/capacitor-incoming-call-kit
bunx cap sync
bunx cap sync copies the plugin's native code into your native projects. Run it again after every plugin upgrade.
Import
import { IncomingCallKit } from '@capgo/capacitor-incoming-call-kit';
API at a glance
| Method | Description |
|---|---|
showIncomingCall |
Displays the native incoming call UI. |
endCall |
Ends a specific tracked call. |
endAllCalls |
Ends every tracked call. |
getActiveCalls |
Returns the currently tracked calls. |
checkPermissions |
Returns the current permission state for notifications and full-screen intents. |
requestPermissions |
Requests the notification permission when the platform supports it. |
requestFullScreenIntentPermission |
Opens the Android 14+ full-screen intent settings page when available. |
Examples
showIncomingCall()
Displays the native incoming call UI.
import { IncomingCallKit } from '@capgo/capacitor-incoming-call-kit';
const result = await IncomingCallKit.showIncomingCall({
callId: 'call-id-123',
callerName: 'caller',
});
console.log(result);
endCall()
Ends a specific tracked call.
import { IncomingCallKit } from '@capgo/capacitor-incoming-call-kit';
const result = await IncomingCallKit.endCall({ callId: 'call-id-123' });
console.log(result);
endAllCalls()
Ends every tracked call.
import { IncomingCallKit } from '@capgo/capacitor-incoming-call-kit';
const result = await IncomingCallKit.endAllCalls();
console.log(result);
getActiveCalls()
Returns the currently tracked calls.
import { IncomingCallKit } from '@capgo/capacitor-incoming-call-kit';
const result = await IncomingCallKit.getActiveCalls();
console.log(result);
checkPermissions()
Returns the current permission state for notifications and full-screen intents.
import { IncomingCallKit } from '@capgo/capacitor-incoming-call-kit';
const result = await IncomingCallKit.checkPermissions();
console.log(result);
requestPermissions()
Requests the notification permission when the platform supports it.
import { IncomingCallKit } from '@capgo/capacitor-incoming-call-kit';
const result = await IncomingCallKit.requestPermissions();
console.log(result);
The table above lists the 7 core methods. Listener and version helpers, and the full contract of each method, are documented in the GitHub repository.
Listen to events
addListener returns a handle. Call handle.remove() when the screen unmounts, or IncomingCallKit.removeAllListeners() to clear every listener.
Full reference
Keep going from Using @capgo/capacitor-incoming-call-kit
If you are using Using @capgo/capacitor-incoming-call-kit to plan dashboard and API operations, connect it with @capgo/capacitor-incoming-call-kit for the implementation detail in @capgo/capacitor-incoming-call-kit, Getting Started for the implementation detail in Getting Started, API Overview for the implementation detail in API Overview, Introduction for the implementation detail in Introduction, and API Keys for the implementation detail in API Keys.