API Service Documentation

Command: create_lead

Creates a new lead in the CRM.


Example Request:
https://jason.apogeegate.com/aicore/backbone/service?ai_login_id=apiuser&ai_login_password=APIuser123&ai_command=create_lead&first_name=John&last_name=Doe&address=123 Test Street&city=Test City&state=Test State&zip=97303&country=Test Country&phone=132-123-1234&followup_date=2010-01-01 12:00:00&besttime=Morning&status=1
&priority=Warm&email=example@example.com&govt_id=100-10-1000&source=example.com&tag_append=prospect,new&notes=[{"status":"Message","Notes":"test"},{"status":"Email","Notes":"example@example.com"}]


Example Response:
https://yourwebsitedomain.com?status=0&status_message=Lead Creation Successful&lead_id=1001

Request

NameTypeRequiredExample
first_nameStringNJohn

First name of lead

last_nameStringNDoe

Last name of lead

companyStringNExample Company

Company of lead

addressStringN123 Test Street

Lead address

address_2StringN123rd Ave

Lead address second line

cityStringNTest City

Lead city

stateStringNTest State

Lead state

zipIntegerN97303

Lead Postal Code

countryStringNTest Country

Lead Country

phoneStringN132-123-1234

Lead Phone Number

cellStringN321-321-4321

Lead Mobile Number

faxStringN213-213-4231

Lead Fax Number

skypeStringNjohnsmith100

Lead Skype Username

ipStringN123.123.123.123

Lead IP Address

followup_dateDateTimeN2010-01-01 12:00:00

Next follow up date for lead

besttimeStringNMorning

Best time to follow up with lead

statusIntegerN1

Comment this to direct them to the status TE page TODO

priorityStringNWarm

How important the lead is

custom_statusIntegerN0

Comment this to direct them to the custom status TE page http://jason.apogeegate.com/aicore/backbone/lead_management_custom_statuses

gmt_offsetIntegerN-1000

Lead's time zone

emailStringNexample@example.com

Lead Email address

admin_notesStringNNote text for admins

Notes viewable by admins

govt_idIntegerN100-10-1000

Lead government id

sourceStringNexample.com

Lead source

sub_idStringN10

Affiliate sub id

sub_id2StringN11

Second Affiliate sub id

external_idStringN100

Lead external id

birth_dateDateN1980-01-31

Lead's date of birth (YYYY-MM-DD or MM-DD)

insert_conflictStringNError

There are 4 types of conflict resolution Error(default) will just have any conflicts return an error message, overwrite will just overwrite any conflicts with the new data, update will update the data that is conflicting with the insert, and duplicate which will just make a new row

notesJSON Encoded StringN[{"Status":"Message","Notes":"test"},{"Status":"Email","Notes":"example@example.com"}]

Each note needs a status and the content of the notes

tagsStringNtag1,tag2,tag3

This will add a set of tags to the lead

ownerIDStringN12

The userID of the user by which this lead will be owned

poolStringNbillmore

A Pool Name to which this lead belongs

Response

NameTypeExample
statusInteger0
status_messageStringLead Creation Successful
lead_idInteger1001