Create a lead

Create a lead with its source and company.

POST https://cotlet.dev/api/v1/suitecrm/leads

write

Creates the lead with Status New, owned by your user. It reaches no one outside your team and is undone in one call with update_record setting Status to Dead, so it does not wait for your OK.

Parameters

Parameters: create_lead
NameTypeDescription
last_name string required string Last name of the lead.
first_name string string First name.
account_name string string Company name, plain text until the lead is converted.
email string string Email address.
lead_source string string How the lead was acquired, for example Website, Trade Show or Cold Call.
description string string Free text notes.

Request

cURL
curl -X POST https://cotlet.dev/api/v1/suitecrm/leads \
  -H "Authorization: Bearer $COTLET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"last_name":"Lopez","first_name":"Ana","account_name":"Northwind Dental","email":"ana@northwind-dental.example","lead_source":"Website","description":"Asked for a demo through the contact form."}'
Python
result = client.call("suitecrm", "create_lead", {"last_name":"Lopez","first_name":"Ana","account_name":"Northwind Dental","email":"ana@northwind-dental.example","lead_source":"Website","description":"Asked for a demo through the contact form."})
Node.js
const result = await cotlet.call('suitecrm', 'create_lead', {"last_name":"Lopez","first_name":"Ana","account_name":"Northwind Dental","email":"ana@northwind-dental.example","lead_source":"Website","description":"Asked for a demo through the contact form."});
CLI
cotlet call suitecrm create_lead --data '{"last_name":"Lopez","first_name":"Ana","account_name":"Northwind Dental","email":"ana@northwind-dental.example","lead_source":"Website","description":"Asked for a demo through the contact form."}'

Example response

JSON

{
  "record_id": "5c1e7d0a-3b42-8f19-a6d4-2e7b90c1f3a8",
  "name": "Ana Lopez",
  "status": "New",
  "lead_source": "Website",
  "url": "https://crm.example.com/#/leads/record/5c1e7d0a-3b42-8f19-a6d4-2e7b90c1f3a8"
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.