Skip to main content

Campaign launch

This article is part of a tutorial about creating an outbound call campaign using NLU.

  1. Telephony setup
  2. Script setup
  3. Campaign launch (you are here)
  4. Analytics
  5. Additional features
  6. Testing

In order to verify everything is working fine, follow along the following steps:

  1. Upload a list of clients to be called.
  2. Create a new telephony channel.
  3. Launch a call campaign to the numbers from the list.

Uploading a list of clients

From the account homepage, select the Phone numbers tab and create a new list of clients. Upload a table containing phone numbers in the first column and the corresponding client names in the second (if present):

phonename
14155552671John
12015550123
caution
The headers of columns with additional payload, like name, should match the field names of the object expected to be returned by the $dialer.getPayload method in the script.

Creating a telephony channel

  1. Go back to your project, select the Channels tab and create a new channel under the Telephony section.
  2. Choose the previously created connection to Zadarma as your SIP trunk connection.
  3. Enable the Record calls toggle if you want the recordings of your calls to be saved in JAICP.
  4. Confirm the channel settings and deploy the bot into the channel.

Telephony channel setup

Call campaign launch

  1. Go to the Outbound call campaigns tab and create a new call campaign.
  2. Make sure you have enough minutes available for calls.
  3. In the campaign settings, specify the phone number list and the channel you have just created.
  4. Start the campaign.

The campaign will start at the time permitted by the call policy. On the same screen, you can press the Show report button to access the campaign report: how many calls are still in progress, how many have been finished and with what results. The report is updated in real time.

Campaign report

Adding new phone numbers

If you forgot to add all the required phone numbers to the initial phone number list, you do not have to create a new list and launch a separate campaign. JAICP offers the Calls API for performing various operations with telephony, including the creation of new call jobs.

Access to the Calls API is protected with a token unique for every call campaign. You can get the token on the Outbound call campaigns tab by clicking either the  icon next to the campaign name or  > Copy API token. The host name is visible in the search bar.

This is an example request for adding a new number to the campaign:

curl --request POST 'https://app.jaicp.com/api/calls/campaign/123456.789.mBoMyfZLZqKHIPKjFjWYfRw9hgfIV9InFC4bHGVw5ND/addPhones' \
--header 'Content-Type: application/json' \
--data-raw '[
{
"phone": 15417543010,
"payload": {
"name": "Mary"
}
}
]'

Here:

  • app.jaicp.com is the host from where the campaign was launched;
  • 123456.789.mBoMyfZLZqKHIPKjFjWYfRw9hgfIV9InFC4bHGVw5ND is the campaign token.

The HTTP request body is an array containing an arbitrary number of objects with the phone and payload keys. phone corresponds to the first column in the phone number list, and payload is analogous to the columns with additional data.

tip
The object passed as payload will be identical to the return value of the $dialer.getPayload method.

The HTTP response is an array of all call jobs successfully created:

[
"123456789"
]

Now let’s see how to analyze the campaign results.