Your application must use Plivo XML to control a call or message synchronously. The XML elements can be combined in different ways to perform complex actions. Some of the possible control actions are:

Use Cases

  • Playing music while the caller is on hold
  • Reading out specified text to the caller
  • Requesting numeric inputs
  • Dialing and connecting to another number

How Plivo Communicates With Your Web Application

In this example, Plivo works like an HTTP Client which receives the call and requests your web application for instructions to control the call. By default, XML requests to your application are made via POST. However, you can configure Plivo to make its XML requests to your application via HTTP GET or POST by changing the related configparameter.

The diagram below outlines a typical case where XML is used:

Plivo XML Overview


  • An incoming call is received on a Plivo endpoint and is connected through the Plivo Cloud.
  • Plivo then looks up your answer_urland responds to that URL.
  • Your web application at that URL should return an XML document that provides instructions to the Plivo API on how the call should proceed.

Outbound Calls

Using XML, outgoing calls can also be controlled in the same manner as incoming calls. The initial outbound call is made through a API request; when the call gets answered, the Plivo API calls the web application on the answer_url which carries instructions to process the outbound call.