Post

Replies

Boosts

Views

Activity

Twilio Voice iOS SDK: callInvite is missing when accepting incoming call from CallKit or React Native
I'm integrating Twilio Voice (v6.12.1) into my React Native app (using Swift bridging for iOS) and have implemented full VoIP, PushKit, and CallKit support for incoming calls. ✅ What works: Incoming calls trigger the VoIP push and display the full-screen CallKit interface (or fallback UI). Decline Call works as expected. Call logs and events print correctly. ❌ Problem: When I try to accept the call using the CallKit Accept button or React Native fallback UI, I consistently get: ❌ [TwilioVoiceModule] answerCall() callInvite is missing. I also noticed that the console logs for answerCall() are being printed three times in a row, even though the accept button is only pressed once. Additionally in the first time console, answerCall() CallInvite found, accepting... 🔍 Observations: The callInvite is properly received when the VoIP push arrives. But when answerCall() is triggered, callInvite becomes nil. This happens in CallKit accept, RN UI accept, and even notification banner accept. 📦 How it's set up (summarized): PushKit Registration – via PKPushRegistry in AppDelegate.swift VoIP push handling – forwards payload to TwilioVoiceModule.handleIncomingPush() CallKit integration – uses CXProviderDelegate to report and handle accept actions JS Bridge – emits acceptCallAction to JS React Native calls TwilioVoiceModule.answerCall(uuid, callSid) In answerCall() method: self.callInvite is nil – so call cannot be accepted. Attaching the link to view the relevant code: https://docs.google.com/document/d/15pNjKrfk954OaotpMIEh3xQUtst---1K45DBXoYctGM/edit?usp=sharing 💡 Call Accept Flow (iOS): VoIP Push → TwilioVoiceModule.handleIncomingPush() Twilio SDK creates callInvite reportNewIncomingCall() triggers CallKit UI On accept: CXAnswerCallAction → emits event to JS RN calls TwilioVoiceModule.answerCall(uuid, callSid) Problem: callInvite is already nil ❓ What I'm trying to understand: Why is callInvite becoming nil before answerCall() is called? Why are the logs showing the answerCall() call 3 times? Is there a race condition or multiple accept triggers? Should I ensure callInvite is accepted only once across all 3 accept paths? ** 💬 Any help would be appreciated.** 📱 Environment: React Native 0.78.x iOS 17+ Swift bridging with TwilioVoiceModule.swift Twilio Voice SDK 6.12.1 PushKit + CallKit + react-native-callkeep
1
0
45
2w
Missing com.apple.developer.voip-push-notification Entitlement in Provisioning Profile
Hello Everyone, I am currently building an app using React Native with Swift bridging, integrating VoIP functionality using Twilio, PushKit, and CallKit. I am encountering the following issue during development: "The current provisioning profile doesn't include the com.apple.developer.voip-push-notification entitlement." What I’ve Done So Far: VoIP Certificate: I have created a valid VoIP Services certificate in the Apple Developer portal. Bundle Identifier and Provisioning Profile: A new Bundle ID was created specifically for this app. I created a provisioning profile for this Bundle ID and downloaded it for use in Xcode. Xcode Capabilities Push Notifications: Enabled Background Modes: Voice over IP: Enabled, Remote notifications: Enabled Entitlements File I have an entitlements file named VoiceCallDemoProjectRelease.entitlements with the following content: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>aps-environment</key> <string>development</string> <key>com.apple.developer.voip-push-notification</key> <true/> </dict> </plist> This entitlements file is properly linked in the project’s build settings. Project Setup I have integrated PushKit for VoIP push handling and CallKit for incoming call UI and control. Problem: In the Apple Developer portal under my App ID settings, I only see an option to enable Push Notifications. There is no option available to enable Voice over IP, and therefore the provisioning profile generated does not include the com.apple.developer.voip-push-notification entitlement. Despite enabling VoIP background mode in Xcode, adding the entitlement in my project, and using a valid VoIP certificate, the profile does not include the required entitlement. Additional Information: I am using an Individual Apple Developer Account, not an Organization account. I have already attempted re-downloading the provisioning profile, restarting Xcode, and cleaning the build folder. Question: What steps should I take to resolve this and ensure that the com.apple.developer.voip-push-notification entitlement is included in my provisioning profile? Is this limitation due to the type of developer account (individual vs. organization), and do I need to upgrade to an Organization account to access this entitlement? Is there any way to request for 'com.appple.developer.voip-push-notification' entitlement to Apple Team ? Any clarification would be appreciated. Thank you.
1
0
218
Jul ’25