Voice Callback via API
Back to Articles
Tutorial SIP API Callback Howto Call Centers

Voice Callback via API

May 28, 2018 2 min
Aivis Olsteins

Aivis Olsteins

So far we have discussed simple Voice call API use case: sending a call to remote party and playing either prerecorded or text to speech message or a combination of both. Now we will discuss a more advanced option: setting up a two-leg call between two parties. This setup can be used for a range of applications, like:

  1. call back systems,
  2. outbound call centers

The idea behind this API is following:

  1. an external application sends API request containing addresses (or numbers) of two remote users;
  2. Depending on the request, the parties are called in sequence or simultaneously
  3. When the calls are established, the calls are interconnected together, and the speech is passed both ways between sides.

 

As mentioned above, it can be used in call back applications and call centers.

In case of callback, the trigger can be any kind, either inbound call, or data packet, or SMS, as described in this post. It is not part of this API, and therefore not discussed here. What is important that it should be able to do proper authentication and produce RESTful API request to initiate a call back.

In case of outbound call center (contact center), the application which runs call center process (a dialer) produces API request to initiate many callback calls. The A-leg in this case is client (remote side), and B-side – an agent. It can be set up in a way that agent is called only when A-leg is connected or vice versa according to requirement.

Here is the example callback API call which connects caller with number 1000123 as A-leg and caller with number 1000125 as B-leg:

 

POST /voice/call/callback
{
"leg_A":
{
"to": "1000123",
  "from": "1000125"
},
"leg_B": {
"to": "1000125",
  "from": "1000123"
}
}

As you can see above, it is very simple example. You can use more attributes, as discussed here and here for each call leg to have them routed as required. Also you can set arbitrary caller ID. In the example above each leg receives other legs destination as caller ID, as it is used most frequently.

Share this article

Aivis Olsteins

Aivis Olsteins

An experienced telecommunications professional with expertise in network architecture, cloud communications, and emerging technologies. Passionate about helping businesses leverage modern telecom solutions to drive growth and innovation.

Related Articles

The Commitment Economy: Why Voice AI Bookings Must Be Integrated, Not Just Conversational

The Commitment Economy: Why Voice AI Bookings Must Be Integrated, Not Just Conversational

AI can promise a booking, but what about the broken promise? Learn why systemic integration, Accuracy Rate, and System Sync define the real test of Voice AI reliability

Read Article
Beyond the Dial Tone: 3 Metrics That Define Outbound AI Success

Beyond the Dial Tone: 3 Metrics That Define Outbound AI Success

Outbound AI requires a new scorecard. Learn the 3 metrics (Connection Rate, Engagement Quality, and Conversion Impact) that measure pipeline movement, not just call volume

Read Article
The New AI Scorecard: How to Measure Campaign Effectiveness Beyond "Call Volume"

The New AI Scorecard: How to Measure Campaign Effectiveness Beyond "Call Volume"

Stop guessing with 'Call Volume'. Discover the 3-Layer Framework for measuring Voice AI success: Goal Completion Rate (GCR), Sentiment Drift, and Knowledge Retrieval. Turn phone calls into structured marketing data

Read Article
What Happens to Metrics When "Hold Time" Hits Zero?

What Happens to Metrics When "Hold Time" Hits Zero?

Does Voice AI just save money? No. Discover the "CSAT Paradox" and how zero hold time improves revenue, lead capture, and team morale simultaneously.

Read Article

SUBSCRIBE TO OUR NEWSLETTER

Stay up to date with the latest news and updates from our telecom experts