POST
/
user
/
lead
{
  "phone_number": "+1234567890",
  "campaign_id": 1,
  "variables": [
    {
      "customer_name": "John Doe",
      "email": "john.doe@example.com"
    }
  ],
  "allow_dupplicate": false
}
{
  "message": "Lead created successfully",
  "data": {
    "id": "1234569"
  }
}
This endpoint allows you to create a new lead in the Lacy.ai system.

Request body

phone_number
string
required
The phone number of the lead in E.164 format (e.g. +1234567890)
campaign_id
integer
required
The ID of the campaign to create the lead for
variables
array
The variables to pass to the lead
allow_dupplicate
boolean
Whether to allow duplicate leads in a campaign.

Response fields

message
string
The message of the response
data
object
The data of the response
data.id
string
The id of the lead
{
  "phone_number": "+1234567890",
  "campaign_id": 1,
  "variables": [
    {
      "customer_name": "John Doe",
      "email": "john.doe@example.com"
    }
  ],
  "allow_dupplicate": false
}
{
  "message": "Lead created successfully",
  "data": {
    "id": "1234569"
  }
}