@cometchat/push-notifications-voip-react-native
v2.0.0
Published
CometChat VoIP call notifications for React Native: the full-screen ring, CallKit and PushKit. Companion to @cometchat/push-notifications-react-native.
Readme
CometChat Push Notifications VoIP SDK for React Native
The CometChat Push Notifications VoIP SDK rings incoming CometChat calls on your React Native app — in the foreground, in the background, and when the app is not running at all. It presents the call through CallKit on iOS and a full-screen incoming-call screen on Android, including over the lock screen, plays the ringtone, handles Answer and Decline, and hands the answered call to your JavaScript.
This is a companion to @cometchat/push-notifications-react-native, which registers the push token. Installing this package is the switch: the core package detects it and installs the ringer.
Prerequisites
Visual Studio Codeor any other code editornpm- React Native 0.78 or later,
minSdkVersion24 on Android, and an iOS deployment target of 13 or later @cometchat/calls-sdk-react-native5.1 or later, which conducts the call itself- A Firebase project for Android, and a VoIP Services certificate for iOS — a VoIP push needs its own certificate, not the APNs one used for chat
Getting Started
To ring incoming calls in your React Native app, you'll need to follow these steps:
- Register at the CometChat Dashboard to create an account.
- After registering, log into your CometChat account and create a new app. Once created, CometChat will generate an Auth Key and App ID for you. Keep these credentials secure as you'll need them later.
- Add an FCM provider (Android) and an APNs provider (iOS) under Notifications in the dashboard, and upload your VoIP Services certificate.
- Install both packages and the native dependencies. React Native autolinking reads only your app's own
package.json, so the core package has to be listed there too — a copy that arrives as a transitive dependency is never linked:
npm install @cometchat/push-notifications-react-native @cometchat/push-notifications-voip-react-native
cd ios && pod install- Refer to the Push Ringing guide in our documentation to integrate the SDK into your app, and enable the Voice over IP background mode in Xcode.
Help and Support
For issues running the project or integrating with our SDK, consult our documentation or create a support ticket or seek real-time support via the CometChat Dashboard.
