Using the Passthru applet in the call flow you can get Exotel to talk to your Application URL and pass on details about the call as and when it happens. Your application can now process this information and decide which path (success/failure) the flow should take next. This applet helps to dynamically control the flow as well as store the call details in your CRM system or other applications.
The Passthru applet passes the call details to the URL configured. It makes a GET request to the URL with the call details as URL-encoded HTTP query parameters.
Passthru can be used in 2 modes (by toggling the checkbox to 'Make Passthru Async'):
Sync: Exotel will immediately pass the call details synchronously during the call flow execution. In this case, it is possible only to make a binary decision with Passthru. For example, You can return back a "200 OK" for choice A and "302 Found" for Choice B. Read more about HTTP response codes here. Please note, that the person on call will have to wait for the next action to be executed until your URL responds back.
Async: Exotel will asynchronously pass the call details without interrupting the call flow execution. Use this option if you don’t want to dynamically change flow execution i.e. select the next applet based on Passthru response. This will ensure the person on call doesn’t wait for the time period it takes for Passthru to be executed i.e. your URL to respond back.
The following are the query parameters of the GET request. Note that only some of this list may be passed to your application - depending on what stage of the flow you have placed the pass-through applet.
Unique identifier of the call
In case of an outgoing call, it’ll be set to the number from which the call is made. In case of an incoming call, it’ll be set to the number from which the call is received
In case of an outgoing call, it’ll be set to the number being dialed out. In case of an incoming call, it’ll be set to the number where the call landed.
The direction of the call. Possible values: ‘incoming’ or ‘outbound dial
Timestamp when the call is created
Value in seconds from the time the call is triggered to the second leg of the call till it is over (including conversation time). This value can be set to zero depending on the previous applet and if there’s no second leg in the call flow.
Timestamp when the call is started
1970-01-01 05:30:00 // Unix time (also known as POSIX time or epoch time)
Note that this would be a constant value and you may instead trigger our Call details API a few minutes after the call has been completed to get accurate information
Displays the number of the agent who was dialed to last
In case of an incoming call, it is the number of the caller. In the case of an outgoing call, it is the number of the first leg of the call.
In case of an incoming call, it is the ExoPhone on which the call landed. In case of an outgoing call, it is the number to which the call was made.
Current server time (format : yyyy-mm-dd hh:mm:ss)
*These parameters will be passed if certain conditions are met as described below:
This will denote what happened with the second leg of the call if the previous applet was “connect”.
Possible values: 'completed', 'busy', 'no-answer', 'failed', 'canceled'
An array that will denote detailed information about each leg attempt if the previous applet was “connect”.
‘digits’ will be passed if there was a 'Gather' or ‘IVR’ applet before this applet and will be equal to the input digits that were entered. NOTE: This parameter comes with a double quote (") before and after the number. You'll have to trim() this parameter for double quotes (") to get the actual digits.
If the call was initiated via API, the value that was passed in CustomField in the API call will be set here.
This will be populated if the previous applet was "Connect" or "Voicemail". It will contain the URL of the conversation in the Connect Applet (if enabled) or voicemail recording. There could be a delay before the recording can be accessed depending on the length of the recording file.
This will be populated if the previous applet was “connect”. It indicates which ExoPhone (Virtual Number) was used to dial out in the Connect Applet.
The following parameters have been deprecated and are no longer supported. Some of these values might be passed inadvertently and applications should not rely on them anymore.
To know the response time or time taken by the pass-thru applet please refer here
Sample Response for a Completed call:
You can also check this article and see if Passthru is slowing your call flow Is Passthru slowing my call flow?
Note: The response you get from Passthru cannot be customised. However, you can add a Custom field only via the
If you have any questions or concerns, please connect with us using the chat widget on your Exotel Dashboard or Whatsapp us on 08088919888