What protocols are supported for VoIP?

Hi,


My colleagues have developed a web-based (RTC) VoIP app and I am now going to develop the iOS counterpart. However, after browsing the forums, I have found several limiting factors with the iOS:


Are there any other limitations that I should be aware of? What are the recommended protocols for developing a VoIP app for iOS?

Thanks!

Replies

There are quite a number of other limitations. You will want to take a look at CallKit and how it will have to replace much of the SIP stack functionality.

There’s three parts to this:

  • ring indication

  • OS integration

  • VoIP transport

Ring indication is how your VoIP app learns about new incoming phone calls while its suspended in the background. We strongly recommend that you use PushKit for this. For more information about PushKit, see:

Older versions of iOS supported a different ring indication strategy that’s been deprecated in favour of PushKit. PushKit has been available since iOS 8.1 (it was present but not functional in 8.0) so there’s no reason for new apps to use the legacy VoIP architecture.

OS integration is all about how to make your VoIP app look like a peer of the built-in Phone app. Starting with iOS 10 there’s an excellent solution for this, CallKit. For details, see:

VoIP transport is all about how your app actually transfers voice data on the wire. iOS does not have specific APIs for this. You’ll have to write (or acquire) the code to do this, building on top of our standard networking APIs (typically BSD Sockets). And, as you noted, this will have to be compatible with IPv4-only, IPv6-only and dual stack networks.

The only specific infrastructure we provide for VoIP relates to network quality of service (QoS). Network traffic that carries voice data (which has low bandwidth but strict latency constraints) should be marked as such. To learn more about how to do this, watch WWDC 2016 Session 714 Networking for the Modern Internet.

Share and Enjoy

Quinn “The Eskimo!”
Apple Developer Relations, Developer Technical Support, Core OS/Hardware

let myEmail = "eskimo" + "1" + "@apple.com"

@eskimo

"VoIP transport is all about how your app actually transfers voice data on the wire. iOS does not have specific APIs for this"

Hello, you wrote this 6 years ago, is that still the situation today?

is that still the situation today?

Pretty much. The only change is that we now have Network framework, so you no longer need to (or should) use BSD Sockets for UDP.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"

There’s three parts to this:

ring indication OS integration VoIP transport

Are there actually 4 parts involved in implementing VoIP functionality - before the app can receive a ring indication/voip push would it would first need to perform some sort of SIP registration, where the user's sip identify and the iPhone IP address are sent to the SIP Registrar, and which also needs binding to the push token, so the user/phone can be located in order for it to be called.

How can the SIP registration be performed, is there any Apple API for such a thing?

How can the SIP registration be performed, is there any Apple API for such a thing?

Apple does not have a SIP API. VoIP setup is usually done by your app. There are PushKit APIs to get the push token, at which point it’s up to you how to communicate that to your VoIP infrastructure. Indeed, many VoIP apps I’ve worked with use an entirely custom protocol for this; SIP is not involved at all.

Share and Enjoy

Quinn “The Eskimo!” @ Developer Technical Support @ Apple
let myEmail = "eskimo" + "1" + "@" + "apple.com"