In Context

The next-generation communications blog from Nexmo

< Back

Announcing Early Media Support in the Nexmo Voice API

July 28, 2017 Published by

Nexmo is pleased to announce immediate support of early media in our programmable Voice API. This has been one of our most requested features, and it is now fully supported for all use cases that use our Voice API.

What Is Early Media?

Simply put, early media is any sound played to a calling party before the actual call is answered. At Nexmo, we have used the term generically to mean the ringing tone that you would hear when you call another party, but it is more than just that. Consider the following diagram:

Early Media diagram

Normally, when party A calls party B, party A hears a ringing tone from party B after a certain period of time (called the Post Dial Delay). In this voice proxy use case, a passenger is calling his driver from Network A, through a Nexmo long virtual phone number. All early media received from party B’s network is forwarded through Nexmo to party A. Now when a passenger calls his driver, he will hear the familiar ringing tone, as if he were calling the driver directly.

Early Media Use Cases

There are two main use cases where early media can be supported. The first is a simple voice proxy. This immediately connects party A to party B. The only thing party A hears is the ringing tone of party B before he picks up. Billing only begins once party B answers the call. The Nexmo Call Control Object (NCCO) to do this looks like this:

The second use case that is also supported is an announced voice proxy. This is similar to a simple voice proxy but with the addition of an announcement before the call is forwarded. So, before party A hears the ringing tone of party B, he first hears an announcement (in this example, a TTS Talk action) such as, “We’re connecting you to your driver. Please hold a moment.”

After the announcement, the Connect action is executed and party A once again hears the party B ringing tone. The NCCO to do this looks like this:

Note: The main difference in this implementation is that billing begins as soon as the Talk action is executed because the call is in an answered state.

Overall, the announced voice proxy early media use case is a big improvement over the use case where the caller would hear only the ringing tone and not actually know if the call was going to the right destination. Or even worse, the caller would hear only silence and not even know if his call was going through.

To find out more about the capabilities of the Nexmo Voice API, see the overview on the new Nexmo Developer.

Tags: , ,

Categorised in: ,

This post was written by