Try Free for 14 DaysRequest A Demo

API Documentation - Leads

The leads resource allows you to retrieve, edit, and add leads.

Leads Instance Resources

MethodEndpointDescription
GET/api/v1/leadsGet a paginated list of details for all leads.
GET/api/v1/leads/{lead_id}Get details about a single lead.
POST/api/v1/leadsCreate a new lead.
POST/api/v1/leads/{lead_id}Edit details for a single lead.

Get All Leads

Get a paginated list of details for all leads.

Resource Details

MethodEndpoint
GEThttps://app.whatconverts.com/api/v1/leads

Supported Parameters

ParameterTypeDescriptionRequired
leads_per_pagenumberNumber of leads to return for this request (default 25, maximum 250).No
page_numbernumberPage number to return for this request.No
account_idnumberUnique identifier for the account in which to return leads from. Supported when using an Agency Key.No
profile_idnumberUnique identifier for the profile in which to return leads from. Supported when using an Agency Key.No
lead_typestringLead type to return for this request; chat, email, event, other, phone_call, text_message, transaction or web_form.No
lead_statusstringLead status to return for this request; repeat or unique leads.No
start_datestringStart date for this request in date or date/time ISO 8601 format (UTC); 2015-11-10 or 2015-11-10T00:00:00Z.No
end_datestringEnd date for this request in date or date/time ISO 8601 format (UTC); 2015-11-10 or 2015-11-10T00:00:00Z.No
orderstringOrder in which to return the leads by date created; asc or (default) desc.No
quotablestringQuotable type to return for this request; yes, no, pending or not_set.No
quote_valuestringReturn leads that have a quote value; has_value or no_value.No
sales_valuestringReturn leads that have a sales value; has_value or no_value.No
caller_numberstringReturn leads that have this E.164 formatted caller’s number.No
spambooleanIf true will return only spam leads.No
duplicatebooleanIf true will return only duplicate leads.No

Response Details

ParameterTypeDescription
leads_per_pagenumberThe number of leads returned in the request.
page_numbernumberThe current page number in the request.
total_pagesnumberThe total amount of pages available in the request.
total_leadsnumberThe total amount of leads available in the request.
leadsarrayContains all the requested leads.
account_idnumberUnique identifier for the account.
profile_idnumberUnique identifier for the profile.
profilestringThe name of the profile.
lead_idnumberUnique identifier for the lead.
user_idstringUnique identifier for the user.
lead_typestringThe type of lead; chat, email, event, other, phone_call, text_message, transaction or web_form.
lead_statusstringThe status of the lead; unique or repeat.
date_createdstringDate and time when the lead was created in ISO 8601 format (UTC).
quotablestringThe quotable type for the lead.
quote_valuenumberThe quote value for the lead.
sales_valuenumberThe sales value for the lead.
spambooleanIf the lead is marked as spam.
duplicatebooleanIf the lead is marked as duplicate.
lead_sourcestringThe traffic source for the lead.
lead_mediumstringThe traffic medium for the lead.
lead_campaignstringThe campaign value for the lead.
lead_contentstringThe content value for the lead.
lead_keywordstringThe keyword value for the lead.
ip_addressstringThe user IP address for the lead.
gclidstringThe Google click identifier for the lead.
msclkidstringThe Microsoft click identifier for the lead.
salesforce_user_idstringThe Salesforce user ID for the lead.
lead_urlstringThe URL where the lead took place.
landing_urlstringThe URL where the user arrived on the website.
operating_systemstringThe operating system used by the user.
browserstringThe browser used by the user.
device_typestringThe device type used by the user.
device_makestringThe device make used by the user.
phone_namestringThe name of the tracking number for the lead. Applicable to phone_call and text_message lead type.
tracking_numberstringThe E.164 formatted tracking number for the lead. Applicable to phone_call and text_message lead type.
destination_numberstringThe E.164 formatted destination number for the lead. Applicable to phone_call lead type.
caller_numberstringThe E.164 formatted caller’s number for the lead. Applicable to phone_call and text_message lead type.
call_durationstringThe formatted duration of the call for the lead. Applicable to phone_call lead type.
call_duration_secondsnumberThe duration of the call in seconds for the lead. Applicable to phone_call lead type.
caller_citystringThe caller’s city for the lead based on the caller_number. Applicable to phone_call and text_message lead type.
caller_zipstringThe caller’s zip for the lead based on the caller_number. Applicable to phone_call and text_message lead type.
caller_statestringThe caller’s state for the lead based on the caller_number. Applicable to phone_call and text_message lead type.
caller_countrystringThe two-letter ISO country code of the caller for the lead based on the caller_number. Applicable to phone_call lead type.
answer_statusstringThe answer status for the lead; Answered, No Answer, or Busy. Applicable to phone_call lead type.
call_statusstringThe call status for the lead; In Progress, or Completed. Applicable to phone_call lead type.
line_typestringThe line type of the caller for the lead. Applicable to phone_call and text_message lead type.
recordingstringThe URL to download the call recording. Applicable to phone_call lead type.
play_recordingstringThe URL to play the call recording. Applicable to phone_call lead type.
voicemailstringThe URL to download the voicemail. Applicable to phone_call lead type.
play_recordingstringThe URL to play the voicemail. Applicable to phone_call lead type.
messagestringThe message sent by the caller for the lead. Applicable to text_message lead type.
event_categorystringThe event category value for the lead. Applicable to event lead type.
event_actionstringThe event action value for the lead. Applicable to event lead type.
event_labelstringThe event label value for the lead. Applicable to event lead type.
transaction_idstringThe transaction id value for the lead. Applicable to transaction lead type.
transaction_taxnumberThe transaction tax value for the lead. Applicable to transaction lead type.
transaction_shippingnumberThe transaction shipping value for the lead. Applicable to transaction lead type.
additional_fieldsobjectAdditional fields for the lead.

Example Response

	{
	  "page_number": 1,
	  "leads_per_page": 25,
	  "total_pages": 37,
	  "total_leads": 910,
	  "leads": [
	    {
	      "account_id": 13744,
	      "profile_id": 42167,
	      "profile": "WhatConverts",
	      "lead_id": 148099,
	      "user_id": "51497-af17340d-62b8-3044-423f-3dc754e621c2",
	      "lead_type": "Phone Call",
	      "lead_status": "Repeat",
	      "date_created": "2016-01-25T16:21:22Z",
	      "quotable": "Yes",
	      "quote_value": 251,
	      "sales_value": 750,
	      "lead_source": "google",
	      "lead_medium": "cpc",
	      "lead_campaign": "call tracking general",
	      "lead_content": "easy call tracking",
	      "lead_keyword": "call tracking",
	      "lead_url": "https://www.whatconverts.com/contact",
	      "landing_url": "https://www.whatconverts.com/",
	      "operating_system": "iOS 12",
	      "browser": "Chrome Mobile 71",
	      "device_type": "Smartphone",
	      "device_make": "Apple iPhone",
	      "spam": false,
	      "duplicate": false,
	      "tracking_number": "+17047349155",
	      "destination_number": "+17045436123",
	      "caller_country": "US",
	      "caller_state": "NC",
	      "caller_zip": "28226",
	      "caller_name": "Jeremy Helms",
	      "call_duration": "2 minutes and 55 seconds",
	      "call_duration_seconds": 175,
	      "caller_city": "Charlotte",
	      "answer_status": "Answered",
	      "call_status": "Completed",
	      "line_type": "Landline",
	      "caller_number": "+15432245114",
	      "phone_name": "Tracking Number",
	      "message": "Hello, I am interested in buying your products.",
	      "ip_address": "157.212.71.198",
	      "gclid": "CLibmtmqpNICFcSfGwodQbUAvg",
	      "msclkid": "25d83debf85f146b8f1d66a754c6a56c",
	      "salesforce_user_id": 15228103840,
	      "additional_fields": {
			"Company Name": "Call Tracking Company",
			"Contact Person": "Jeremy Helms"
	      },
	      "recording": "https://app.whatconverts.com/recording/13451345/download",
	      "play_recording": "https://app.whatconverts.com/recording/13451345/play",
	      "voicemail": "https://app.whatconverts.com/recording/13451345/download",
	      "play_voicemail": "https://app.whatconverts.com/recording/13451345/play"
	    },
	    ...
	  ]
	}
	

Get Single Lead

Get details about a single lead.

Resource Details

MethodEndpoint
GEThttps://app.whatconverts.com/api/v1/leads/{lead_id}

Supported Parameters

No supported parameters.

Response Details

Includes all response details from get all leads resource.

Create New Lead

Create a new lead.

Resource Details

MethodEndpoint
POSThttps://app.whatconverts.com/api/v1/leads

Supported Parameters

ParameterTypeDescriptionRequired
profile_idnumberUnique identifier for the profile in which to add this lead to. Profile ID is not required when using a Profile Key.Yes
send_notificationbooleanSend an email notification for this lead; true or (default) false.Yes
lead_typestringLead type for this lead; chat, email, event, other, phone_call, text_message, transaction or web_form.Yes
date_createdstringDate and time when the lead was created in ISO 8601 format (UTC); 2015-11-10T00:00:00Z.No
quotablestringThe quotable type for this lead; yes, no, pending or not_set.No
quote_valuenumberThe quote value for this lead.No
sales_valuenumberThe sales value for this lead.No
lead_sourcestringThe lead source for this lead.No
lead_mediumstringThe lead medium for this lead.No
lead_campaignstringThe lead campaign for this lead.No
lead_contentstringThe lead content for this lead.No
lead_keywordstringThe lead keyword for this lead.No
ip_addressstringThe user IP address for this lead.No
gclidstringThe Google click identifier for the lead.No
msclkidstringThe Microsoft click identifier for the lead.No
lead_urlstringThe URL where the lead took place.No
landing_urlstringThe URL where the user arrived on the website.No
operating_systemstringThe operating system used by the user.No
browserstringThe browser used by the user.No
device_typestringThe device type used by the user.No
device_makestringThe device make used by the user.No
form_namestringThe name of the form for this lead. Applicable to web_form lead type.No
phone_namestringThe name of the tracking number for this lead. Applicable to phone_call and text_message lead type.No
tracking_numberstringThe E.164 formatted tracking number for this lead. Applicable to phone_call and text_message lead type.No
destination_numberstringThe E.164 formatted destination number for this lead. Applicable to phone_call lead type.No
caller_numberstringThe E.164 formatted caller’s number for this lead. Applicable to phone_call lead type.No
call_duration_secondsnumberThe duration of the call in seconds for this lead. Applicable to phone_call lead type.No
caller_citystringThe caller’s city for this lead. Applicable to phone_call and text_message lead type.No
caller_zipstringThe caller’s zip for this lead. Applicable to phone_call and text_message lead type.No
caller_statestringThe caller’s state for this lead. Applicable to phone_call and text_message lead type.No
caller_countrystringThe two-letter ISO country code of the caller for this lead. Applicable to phone_call and text_message lead type.No
answer_statusstringThe answer status for this lead; Answered, No Answer, or Busy. Applicable to phone_call lead type.No
line_typestringThe line type of the caller for this lead. Applicable to phone_call and text_message lead type.No
messagestringThe message sent by the caller for the lead. Applicable to text_message lead type.
event_categorystringThe event category value for this lead. Applicable to event lead type.No
event_actionstringThe event action value for this lead. Applicable to event lead type.No
event_labelstringThe event label value for this lead. Applicable to event lead type.No
transaction_idstringThe transaction id value for this lead. Applicable to transaction lead type.No
transaction_taxnumberThe transaction tax value for this lead. Applicable to transaction lead type.No
transaction_shippingnumberThe transaction shipping value for this lead. Applicable to transaction lead type.No
additional_fieldsarrayAdditional fields for this lead; additional_fields[{field_name}].No

Response Details

ParameterTypeDescription
lead_idnumberUnique identifier for the lead created.

Example Response

	{
	  "account_id": 13744,
	  "profile_id": 42167,
	  "profile": "WhatConverts",
	  "lead_id": 148099,
	  "user_id": "51497-af17340d-62b8-3044-423f-3dc754e621c2",
	  "lead_type": "Phone Call",
	  "lead_status": "Repeat",
	  "date_created": "2016-01-25T16:21:22Z",
	  "quotable": "Yes",
	  "quote_value": 251,
	  "sales_value": 750,
	  "lead_source": "google",
	  "lead_medium": "cpc",
	  "lead_campaign": "call tracking general",
	  "lead_content": "easy call tracking",
	  "lead_keyword": "call tracking",
	  "lead_url": "https://www.whatconverts.com/contact",
	  "landing_url": "https://www.whatconverts.com/",
	  "operating_system": "iOS 12",
	  "browser": "Chrome Mobile 71",
	  "device_type": "Smartphone",
	  "device_make": "Apple iPhone",
	  "spam": false,
	  "duplicate": false,
	  "tracking_number": "+17047349155",
	  "destination_number": "+17045436123",
	  "caller_country": "US",
	  "caller_state": "NC",
	  "caller_zip": "28226",
	  "caller_name": "Jeremy Helms",
	  "call_duration": "2 minutes and 55 seconds",
	  "call_duration_seconds": 175,
	  "caller_city": "Charlotte",
	  "answer_status": "Answered",
	  "call_status": "Completed",
	  "line_type": "Landline",
	  "caller_number": "+15432245114",
	  "phone_name": "Tracking Number",
	  "message": "Hello, I am interested in buying your products.",
	  "ip_address": "157.212.71.198",
	  "gclid": "CLibmtmqpNICFcSfGwodQbUAvg",
	  "msclkid": "25d83debf85f146b8f1d66a754c6a56c",
	  "salesforce_user_id": 15228103840,
	  "additional_fields": {
	    "Company Name": "Call Tracking Company",
	    "Contact Person": "Jeremy Helms"
	  },
	  "recording": "https://app.whatconverts.com/recording/13451345/download",
	  "play_recording": "https://app.whatconverts.com/recording/13451345/play",
	  "voicemail": "https://app.whatconverts.com/recording/13451345/download",
	  "play_voicemail": "https://app.whatconverts.com/recording/13451345/play"
	}
	

Edit Lead

Edit details for a single lead.

Resource Details

MethodEndpoint
POSThttps://app.whatconverts.com/api/v1/leads/{lead_id}

Supported Parameters

ParameterTypeDescriptionRequired
quotablestringThe quotable type for this lead; yes, no, pending or not_set.No
quote_valuenumberThe quote value for this lead.No
sales_valuenumberThe sales value for this lead.No
lead_sourcestringThe lead source for this lead.No
lead_mediumstringThe lead medium for this lead.No
lead_campaignstringThe lead campaign for this lead.No
lead_contentstringThe lead content for this lead.No
lead_keywordstringThe lead keyword for this lead.No
ip_addressstringThe user IP address for this lead.No
lead_urlstringThe URL where the lead took place.No
landing_urlstringThe URL where the user arrived on the website.No
additional_fieldsarrayAdditional fields for this lead; additional_fields[{field_name}].No

Response Details

ParameterTypeDescription
lead_idnumberUnique identifier for the edited lead.

Example Response

	{
		"account_id": 13744,
		"profile_id": 42167,
		"profile": "WhatConverts",
		"lead_id": 148099,
		"user_id": "51497-af17340d-62b8-3044-423f-3dc754e621c2",
		"lead_type": "Phone Call",
		"lead_status": "Repeat",
		"date_created": "2016-01-25T16:21:22Z",
		"quotable": "Yes",
		"quote_value": 251,
		"sales_value": 750,
		"lead_source": "google",
		"lead_medium": "cpc",
		"lead_campaign": "call tracking general",
		"lead_content": "easy call tracking",
		"lead_keyword": "call tracking",
		"lead_url": "https://www.whatconverts.com/contact",
		"landing_url": "https://www.whatconverts.com/",
		"operating_system": "iOS 12",
		"browser": "Chrome Mobile 71",
		"device_type": "Smartphone",
		"device_make": "Apple iPhone",
		"spam": false,
		"duplicate": false,
		"tracking_number": "+17047349155",
		"destination_number": "+17045436123",
		"caller_country": "US",
		"caller_state": "NC",
		"caller_zip": "28226",
		"caller_name": "Jeremy Helms",
		"call_duration": "2 minutes and 55 seconds",
		"call_duration_seconds": 175,
		"caller_city": "Charlotte",
		"answer_status": "Answered",
		"call_status": "Completed",
		"line_type": "Landline",
		"caller_number": "+15432245114",
		"phone_name": "Tracking Number",
		"message": "Hello, I am interested in buying your products.",
		"ip_address": "157.212.71.198",
		"gclid": "CLibmtmqpNICFcSfGwodQbUAvg",
		"msclkid": "25d83debf85f146b8f1d66a754c6a56c",
		"salesforce_user_id": 15228103840,
		"additional_fields": {
			"Company Name": "Call Tracking Company",
			"Contact Person": "Jeremy Helms"
		},
		"recording": "https://app.whatconverts.com/recording/13451345/download",
		"play_recording": "https://app.whatconverts.com/recording/13451345/play",
		"voicemail": "https://app.whatconverts.com/recording/13451345/download",
		"play_voicemail": "https://app.whatconverts.com/recording/13451345/play"
	}