Webhook

Webhooks allow our system to provide other applications with real-time information

SETUP

Under ‘Edit’ in Manage Location, Click on the Webhook Management tab.

A list of all current webhooks for that location will appear. You can edit or add new webhooks.

Add a Webhook

Click on the blue ‘Add Webhook’ button in the top right corner

A user can choose:

  • Existing Templates: Create a new webhook with a template that’s already made

  • Create Template: Create a new template along with the webhook

Select From Existing Template

STEP 1: Basic Settings

  • Webhook Name: What you would like the webhook to be called

  • URL: The endpoint the events will be sent to

  • Template: What template you want to use. A list of templates available to your group will be listed here.

Click Next to go to the next step.

STEP 2: Advanced Settings

If you have a more advanced setup, you can add those details here

  • HTTP Header: Select what HTTP Header is needed (you can add more than 1 by clicking the “+” icon

  • Value: enter in your header value, for example: application/xml, or application/json

  • Success response code: Select your success return response (examples 200, 201, 202, 203, 204)

  • HTTP Method: Choose either POST or PUT

STEP 3: Summary

A summary will show your selections. If everything is correct, select ‘Finish’ to save your webhook.

The webhook will now appear in the available drop-down list where applicable

Create Template

The second option is to click on “Create Template” on the main screen.

Once you click on “Create Template”, a list of new options will appear. This option is used if the template you want to use doesn’t already exist and needs to be created from scratch.

STEP 1: Basic Settings

  • Webhook Name: What you would like the webhook to be called

  • URL: The endpoint the events will be sent to

  • Template: What template you want to use

  • Template Name: The name of your custom template

  • Template Group: What Group you would like to assign the template to (who else can use it)

  • Template Type: What type of template are you making (JSON or XML are current options)

  • Template Format: Enter in the format of your template. This must be in the correct format, or you will receive an error and cannot move to the next screen.

The example below shows JSON Format with the fields: Firstname, Lastname, email

Once all the fields have been added, click Next to go to the next step.

STEP 2: Custom Data

Once you provide your template example, the fields will be extracted so you can correlate the AutoID data point to the correct field. The field in the drop-down is the data point that will be entered into the template when data is sent.

Clicking on the drop-down fields will bring up the full list of possible tokens that can be used for each extracted data point. Select the data point that best fits what data you want to go into that field when a webhook is sent.

The data points are organized into different categories to make it easier to find what you are looking for.

In the example below, I selected First Name for “first”, Last Name for “last”, and ANI for “phone”. When the webhook is sent, the first field will show the caller’s first name, the last field will show the caller’s last name, and the phone field will show the number of the person who called the location.

Click Next to Get to Advanced Settings.

STEP 3: Advanced Settings

If you have a more advanced setup, you can add those details here

  • HTTP Header: Select what HTTP Header is needed (you can add more than 1 by clicking the “+” icon)

  • Value: enter in your header value, for example application/xml, or application/json

  • Success response code: Select your success return response (examples 200, 201, 202, 203, 204)

  • HTTP Method: Choose either POST or PUT

Click Next to go to the Summary.

STEP 4: Summary

A summary will show your selections. If everything is correct, select ‘Finish’ to save your webhook.

The webhook will now appear in the available drop-down list where applicable

WEBHOOK ENABLING

Once a webhook template has been created, you can enable webhooks at different areas of the system. The main places you can enable webhooks are:

Call Treatments:

For each treatment you create, you can enable a webhook to be sent. This allows for customization in what calls get sent into the third-party system or CRM. See Call Treatments for more info.

  • Example: An IVR call treatment is set up to have Sales, Service, Parts. Webhooks are set up on the ‘Sales’ extension so only callers who push ‘Sales’ will have calls sent to the CRM.

Static Campaigns:

For each campaign you create, you can enable a webhook to be sent. This can be done either by adding a new campaign or editing an existing campaign. See Offline Marketing Campaigns for more info.

  • Click the Webhook Dropdown to select the webhook that was created.

  • Designate if the webhook will be sent at the beginning of the call or end of the call.

DNI Campaigns:

For each DNI campaign, you create, you can enable a webhook to be sent. This can be done either by adding a new campaign or editing an existing one. See Digital Campaigns for more info.

  • Click the Webhook Dropdown to select the webhook that was created.

  • Designate if the webhook will be sent at the beginning of the call or end of the call.

WEBHOOK OUTPUT

Once a webhook template has been set up and added to a campaign(s), webhooks will be sent to the endpoint specified:

Endpoint: http(s)://<Your URL>/<Your Defined Path>)

Header Type: application/json or application/xml

Body Definitions:

Token Name

Category

Description

Example

%callid%

call_begin

CallID - Unique Identifier of call

093cc03c.e6a4.6ac6.978f.740b10afeaca

%session_id%

call_begin

Session ID - ID for the users session

5da13c4f-753f-448a-81a1-12456785be20

%dialed_time%

call_end

Dialed Time - Full Duration including dial time

36

%answered_time%

call_end

Answered Time - Duration of connection time

29

%dialstatus%

call_end

DialStatus - Did remote party answer or not

ANSWER

%tracking%

call_begin

Tracking - The Tracking number dialed

7774839229

%ani%

call_begin

ANI - Telephone number of person calling

7776734736

%call_start_time%

call_begin

Call Start Time - The start time of call (Default: 24 hour GMT)

2019-03-28T00:05:00.000Z

%call_end_time%

call_end

Call End Time - The end time of call (Default: 24 hour GMT)

2019-03-28T00:05:30.000Z

%target%

dni

Target - The target destination

7776734700

%global_id%

dni

Global ID - Unique user identification

0f9cec2d1236e1234d8e123a7adff123

%landing_domain%

dni

Landing Domain - Domain Name of website consumer landed on

example.com

%repeat_caller%

call_begin

Repeat Caller - 1 or 0

1 (repeat caller)

%prompt_responses%

call_end

Treatment Response - Call Treatment Flow of consumer (Nested object)

%question%

call_end

Question Name

one

%question_link%

call_end

Link to audio file

http://app.example.com/prompts-qa/audio/-1/94f17d142e0e861bfa34.wav

%response%

call_end

What the caller pressed

1

%domain_name%

dni

Domain Name - Domain Name where DNI is installed

example.com

%campaign_name%

call_begin

Campaign Name - Campaign Name

Sales Campaign

%rec_audiourl%

call_end

Audio URL - Audio Recording in MONO MP3 Format

https://audio.example.com/MP3/202110/demo.e123.4d3c.41de.123468.mp3

%rec_audiowavurl%

call_end

Audio URL - Audio Recording in Stereo WAV Format

https://audio.example.com/MP3/202110/demo.e123.4d3c.41de.123468.wav

%ani_is_valid%

call_begin

Is Valid - 1 or 0

1 meaning it is a valid ANI

%ani_line_type%

call_begin

Line Type - Caller\s line type

Mobile/NonFixedVOIP/Landline/TollFree/FixedVOIP

%ani_carrier%

call_begin

Carrier - Caller\s Carrier

ATT/Verizon Wireless/T-Mobile USA

%ani_full_name%

call_begin

Full Name - Caller\s Full Name

Freddy Krueger

%ani_first_name%

call_begin

First Name - Caller\s First Name

Freddy

%ani_middle_name%

call_begin

Middle Name - Caller\s Middle Name

Charles

%ani_last_name%

call_begin

Last Name - Caller\s Last Name

Krueger

%ani_type%

call_begin

Type - Caller\s Home Type - (Single Family or Multi Family)

Charles

%ani_street_line_1%

call_begin

Street Line 1 - Caller\s Address Line 1

1428 Elm Street

%ani_street_line_2%

call_begin

Street Line 2 - Caller\s Address Line 2

Apt 2

%ani_city%

call_begin

City - Callers City Name

Springwood

%ani_zip%

call_begin

ZIP - Callers Zip Code

50035

%ani_zip4%

call_begin

ZIP4 - Callers Zip plus 4"

1001

%ani_state%

call_begin

State - Callers State Name

Ohio

%ani_country_code%

call_begin

Country Code - Caller Country Code

US

%ani_street_number%

call_begin

Street Number - Caller Street Number

1428

%ani_street_name%

call_begin

Street Name - Caller Street Name

Elm

%ani_street_type%

call_begin

Street Type - Caller Street Type

St

%ani_updated_at%

call_begin

Updated At - Caller Information last lookup data

13 Oct 2020 3:15:12 PM

%tags%

call_begin

Tags - Data used to identify and group campaigns (Nested object)

Region: south

%location_name%

location_info

Location - Name

Auto ID

%location_address_line_1%

location_info

Location - Address Line 1

157 Main Street

%location_address_line_2%

location_info

Location - Address Line 2

Apt 4

%location_address_city%

location_info

Location - City

Los Angeles

%location_address_zip%

location_info

Location - Zip

91741

%location_address_state%

location_info

Location - State

CA

%account_id%

location_info

Account ID - Client\s provided account number

26627332

%location_id%

location_info

Location ID - Client\s provided location ID

3242243

%page_id%

dni

Unique ID of the Web Page

e14eb2bb-b829-4d19-bf5a-da76ccffbf4e

%page_converted_on%

dni

Page Converted On - The page that your customer made the call

https://www.example.com/about_us.htm

%first_page_landed_on%

dni

First Page Landed On - The page that your customer first landed on your site

https://www.example.com

%vehicle_vin%

dni

Vehicle Identifier

1C6RRFFG9KN909808

%vehicle_year%

dni

Vehicle Year

2019

%vehicle_make%

dni

Vehicle Make

Ram

%vehicle_model%

dni

Vehicle Model

1500

%referral_domain%

dni

Referral Domain - Domain user was referred from

facebook.com

%medium%

dni

Medium Type - Paid|Organic|Direct|Referral|Other

Paid

%utm_source%

dni

UTM Source - Identifies source of traffic

facebook

%utm_medium%

dni

UTM Medium - Specifies the medium

like social or newsletter

%utm_campaign%

dni

UTM Campaign - Identifies the campaign the URL is part of

sales

%utm_content%

dni

UTM Content - Content user is directed to

123

%keyword%

dni

Keyword - Tracking

air conditioning

%gclid%

dni

GCLID - Google Click ID

xyz123

%ring_count%

call_end

Ring Count - Count of Rings before Answer

4

%site_id%

location_info

AutoIDs Site Identifier

4567

%domain_id%

location_info

AutoIDs Location Identifier

1234

%visitor_browser_family%

dni

Visitors - Browser Family

Firefox

%visitor_browser_version%

dni

Visitors - Browser Version

79

%visitor_device%

dni

Visitors - Device

Other

%visitor_country_code%

dni

Visitors - Country Code

US

%visitor_region%

dni

Visitors - Region

CA

%visitor_city%

dni

Visitors - City

Los Angeles

%visitor_ip_address%

dni

Visitors - IP Address

47.156.108.175

%visitor_operating_system%

dni

Visitors - Operating System

Mac OS X

%visitor_lat%

dni

Visitors - Latitude

34.153500

%visitor_long%

dni

Visitors - Longitude

-117.845700

Example JSON Output:

{
"callid": "093cc03c.e6a4.6ac6.978f.740b10afeaca",
"session_id": "5da13c4f-753f-448a-81a1-290bb7e5be20",
"dialed_time": "36",
"answered_time": "29",
"dialstatus": "ANSWER",
"tracking": "7774839229",
"ani": "7776734736",
"call_start_time": "2019-03-28T00:05:00.000Z",
"call_end_time": "2019-03-28T00:05:30.000Z",
"target": "7776734700",
"global_id": "0f9cec2d7556e9011d8e102a7adff138",
"landing_domain": "example.com",
"repeat_caller": "1 meaning it is a repeat caller",
"prompt_responses": [
	{
		"question": "one",
		"question_link": "http://app.example.com/prompts-qa/audio/-1/94f17d142e0e861bfa34.wav",
		"response": "1" 
	}
	],
"domain_name": "example.com",
"campaign_name": "Sales Campaign",
"rec_audiourl": "https://audio.example.com/MP3/202110/demo.e354.4d3c.41de.00f56e4c7078.mp3",
"rec_audiowavurl": "https://audio.example.com/MP3/202110/demo.e354.4d3c.41de.00f56e4c7078.wav",
"ani_is_valid": "1 meaning it is a valid ANI",
"ani_line_type": "Mobile/NonFixedVOIP/Landline/TollFree/FixedVOIP",
"ani_carrier": "ATT/Verizon Wireless/T-Mobile USA",
"ani_full_name": "Freddy Krueger",
"ani_first_name": "Freddy",
"ani_middle_name": "Charles",
"ani_last_name": "Krueger",
"ani_type": "Charles",
"ani_street_line_1": "1428 Elm Street",
"ani_street_line_2": "Apt 2",
"ani_city": "Springwood",
"ani_zip": "50035",
"ani_zip4": "1001",
"ani_state": "Ohio",
"ani_country_code": "US",
"ani_street_number": "1428",
"ani_street_name": "Elm",
"ani_street_type": "St",
"ani_updated_at": "13 Oct 2020 3:15:12 PM",
"tags":
	{
		"Region": "south",
		"Product": "12345"
	},
"location_name": "Auto ID",
"location_address_line_1": "157 Main Street",
"location_address_line_2": "Apt 4",
"location_address_city": "Los Angeles",
"location_address_zip": "91741",
"location_address_state": "CA",
"account_id": "26627332",
"location_id": "3242243",
"page_id": "e14eb2bb-b829-4d19-bf5a-da76ccffbf4e",
"page_converted_on": "https://www.example.com/about_us.htm",
"first_page_landed_on": "https://www.example.com",
"vehicle_vin": "1C6RRFFG9KN909808",
"vehicle_year": "2019",
"vehicle_make": "Ram",
"vehicle_model": "1500",
"referral_domain": "facebook.com",
"medium": "Paid",
"utm_source": "facebook",
"utm_medium": "like social or newsletter",
"utm_campaign": "sales",
"utm_content": "123",
"keyword": "air conditioning",
"gclid": "xyz123",
"ring_count": "4",
"site_id": "4567",
"domain_id": "1234",
"visitor_browser_family": "Firefox",
"visitor_browser_version": "79",
"visitor_device": "Other",
"visitor_country_code": "US",
"visitor_region": "CA",
"visitor_city": "Los Angeles",
"visitor_ip_address": "47.156.108.175",
"visitor_operating_system": "Mac OS X",
"visitor_lat": "34.153500",
"visitor_long": "-117.845700"
}

Supported Error Messages:

200 OK

Successful (Also can support 201, 202, 203, 204)

Ring to Number

Error for retransmission once you’re back online

Last updated