Skip to main content
DELETE
/
campaigns
/
{campaignId}
/
leads
/
{leadId}
Delete or Unsubscribe Lead
curl --request DELETE \
  --url https://api.lemlist.com/api/campaigns/{campaignId}/leads/{leadId} \
  --header 'Authorization: Basic <encoded-value>'
{
  "firstName": "Bastien",
  "lastName": "Velitchkine",
  "companyName": "Bastien VELITCHKINE EI",
  "jobTitle": "Growth Engineer",
  "companyDomain": "bvelitchkine.com",
  "email": "[email protected]",
  "preferredContactMethod": "email",
  "industry": "Technology",
  "Company name": "Bastien Velitchkine",
  "_id": "lea_mizMsAEkRrJuhouYe",
  "isPaused": false,
  "campaignId": "cam_9NsHPnykWESTncCW8",
  "contactId": "ctc_Rofmb6uNGyaPNZ2ni",
  "emailStatus": "deliverable"
}
This endpoint uses the Lead object. Make sure to also check the Contact object to understand the distinction between the two.
This endpoint deletes a lead from a campaign. You need to specify action=remove in the params to delete a lead. If you don’t specify action=remove, the endpoint fallbacks to unsubscribing the lead and to do so you need to provide the lead email.

Authorizations

Authorization
string
header
required

Basic authentication header of the form Basic <encoded-value>, where <encoded-value> is the base64-encoded string username:password.

Path Parameters

campaignId
string
required

The unique identifier of the campaign

leadId
string
required

The unique identifier of the lead

Query Parameters

action
string

Use 'remove' to force delete. Otherwise it will just unsubscribe the lead from the campaign.

Response

Success

firstName
string
lastName
string
companyName
string
jobTitle
string
companyDomain
string
email
string<email>
preferredContactMethod
string
industry
string
Company name
string
_id
string
isPaused
boolean
campaignId
string
contactId
string
emailStatus
string
{key}
string