curl --request PATCH \
--url https://api.lemlist.com/api/campaigns/{campaignId} \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "New campaign name",
"emoji": "🎯",
"stopOnEmailReplied": true,
"stopOnMeetingBooked": true,
"stopOnLinkClicked": false,
"leadsPausedByInterest": false,
"opportunityReplied": true,
"opportunityClicked": false,
"autoLeadInterest": true,
"disableTrackOpen": false,
"disableTrackClick": false,
"disableTrackReply": false,
"disableOutOfOffice": false,
"sequenceSharing": false,
"sendUserIds": [
"usr_2aBCdEfGHiJkLmNOp",
"usr_7xYzAbCdEfGhIjKlM"
],
"autoReview": true,
"autoReviewConditions": [
"deliverable",
"risky"
]
}
'import requests
url = "https://api.lemlist.com/api/campaigns/{campaignId}"
payload = {
"name": "New campaign name",
"emoji": "🎯",
"stopOnEmailReplied": True,
"stopOnMeetingBooked": True,
"stopOnLinkClicked": False,
"leadsPausedByInterest": False,
"opportunityReplied": True,
"opportunityClicked": False,
"autoLeadInterest": True,
"disableTrackOpen": False,
"disableTrackClick": False,
"disableTrackReply": False,
"disableOutOfOffice": False,
"sequenceSharing": False,
"sendUserIds": ["usr_2aBCdEfGHiJkLmNOp", "usr_7xYzAbCdEfGhIjKlM"],
"autoReview": True,
"autoReviewConditions": ["deliverable", "risky"]
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'New campaign name',
emoji: '🎯',
stopOnEmailReplied: true,
stopOnMeetingBooked: true,
stopOnLinkClicked: false,
leadsPausedByInterest: false,
opportunityReplied: true,
opportunityClicked: false,
autoLeadInterest: true,
disableTrackOpen: false,
disableTrackClick: false,
disableTrackReply: false,
disableOutOfOffice: false,
sequenceSharing: false,
sendUserIds: ['usr_2aBCdEfGHiJkLmNOp', 'usr_7xYzAbCdEfGhIjKlM'],
autoReview: true,
autoReviewConditions: ['deliverable', 'risky']
})
};
fetch('https://api.lemlist.com/api/campaigns/{campaignId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));require 'uri'
require 'net/http'
url = URI("https://api.lemlist.com/api/campaigns/{campaignId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"New campaign name\",\n \"emoji\": \"🎯\",\n \"stopOnEmailReplied\": true,\n \"stopOnMeetingBooked\": true,\n \"stopOnLinkClicked\": false,\n \"leadsPausedByInterest\": false,\n \"opportunityReplied\": true,\n \"opportunityClicked\": false,\n \"autoLeadInterest\": true,\n \"disableTrackOpen\": false,\n \"disableTrackClick\": false,\n \"disableTrackReply\": false,\n \"disableOutOfOffice\": false,\n \"sequenceSharing\": false,\n \"sendUserIds\": [\n \"usr_2aBCdEfGHiJkLmNOp\",\n \"usr_7xYzAbCdEfGhIjKlM\"\n ],\n \"autoReview\": true,\n \"autoReviewConditions\": [\n \"deliverable\",\n \"risky\"\n ]\n}"
response = http.request(request)
puts response.read_body<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.lemlist.com/api/campaigns/{campaignId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'New campaign name',
'emoji' => '🎯',
'stopOnEmailReplied' => true,
'stopOnMeetingBooked' => true,
'stopOnLinkClicked' => false,
'leadsPausedByInterest' => false,
'opportunityReplied' => true,
'opportunityClicked' => false,
'autoLeadInterest' => true,
'disableTrackOpen' => false,
'disableTrackClick' => false,
'disableTrackReply' => false,
'disableOutOfOffice' => false,
'sequenceSharing' => false,
'sendUserIds' => [
'usr_2aBCdEfGHiJkLmNOp',
'usr_7xYzAbCdEfGhIjKlM'
],
'autoReview' => true,
'autoReviewConditions' => [
'deliverable',
'risky'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}Update Campaign
Updates the settings and configuration of an existing campaign.
curl --request PATCH \
--url https://api.lemlist.com/api/campaigns/{campaignId} \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/json' \
--data '
{
"name": "New campaign name",
"emoji": "🎯",
"stopOnEmailReplied": true,
"stopOnMeetingBooked": true,
"stopOnLinkClicked": false,
"leadsPausedByInterest": false,
"opportunityReplied": true,
"opportunityClicked": false,
"autoLeadInterest": true,
"disableTrackOpen": false,
"disableTrackClick": false,
"disableTrackReply": false,
"disableOutOfOffice": false,
"sequenceSharing": false,
"sendUserIds": [
"usr_2aBCdEfGHiJkLmNOp",
"usr_7xYzAbCdEfGhIjKlM"
],
"autoReview": true,
"autoReviewConditions": [
"deliverable",
"risky"
]
}
'import requests
url = "https://api.lemlist.com/api/campaigns/{campaignId}"
payload = {
"name": "New campaign name",
"emoji": "🎯",
"stopOnEmailReplied": True,
"stopOnMeetingBooked": True,
"stopOnLinkClicked": False,
"leadsPausedByInterest": False,
"opportunityReplied": True,
"opportunityClicked": False,
"autoLeadInterest": True,
"disableTrackOpen": False,
"disableTrackClick": False,
"disableTrackReply": False,
"disableOutOfOffice": False,
"sequenceSharing": False,
"sendUserIds": ["usr_2aBCdEfGHiJkLmNOp", "usr_7xYzAbCdEfGhIjKlM"],
"autoReview": True,
"autoReviewConditions": ["deliverable", "risky"]
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Basic <encoded-value>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: 'New campaign name',
emoji: '🎯',
stopOnEmailReplied: true,
stopOnMeetingBooked: true,
stopOnLinkClicked: false,
leadsPausedByInterest: false,
opportunityReplied: true,
opportunityClicked: false,
autoLeadInterest: true,
disableTrackOpen: false,
disableTrackClick: false,
disableTrackReply: false,
disableOutOfOffice: false,
sequenceSharing: false,
sendUserIds: ['usr_2aBCdEfGHiJkLmNOp', 'usr_7xYzAbCdEfGhIjKlM'],
autoReview: true,
autoReviewConditions: ['deliverable', 'risky']
})
};
fetch('https://api.lemlist.com/api/campaigns/{campaignId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));require 'uri'
require 'net/http'
url = URI("https://api.lemlist.com/api/campaigns/{campaignId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"New campaign name\",\n \"emoji\": \"🎯\",\n \"stopOnEmailReplied\": true,\n \"stopOnMeetingBooked\": true,\n \"stopOnLinkClicked\": false,\n \"leadsPausedByInterest\": false,\n \"opportunityReplied\": true,\n \"opportunityClicked\": false,\n \"autoLeadInterest\": true,\n \"disableTrackOpen\": false,\n \"disableTrackClick\": false,\n \"disableTrackReply\": false,\n \"disableOutOfOffice\": false,\n \"sequenceSharing\": false,\n \"sendUserIds\": [\n \"usr_2aBCdEfGHiJkLmNOp\",\n \"usr_7xYzAbCdEfGhIjKlM\"\n ],\n \"autoReview\": true,\n \"autoReviewConditions\": [\n \"deliverable\",\n \"risky\"\n ]\n}"
response = http.request(request)
puts response.read_body<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.lemlist.com/api/campaigns/{campaignId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'name' => 'New campaign name',
'emoji' => '🎯',
'stopOnEmailReplied' => true,
'stopOnMeetingBooked' => true,
'stopOnLinkClicked' => false,
'leadsPausedByInterest' => false,
'opportunityReplied' => true,
'opportunityClicked' => false,
'autoLeadInterest' => true,
'disableTrackOpen' => false,
'disableTrackClick' => false,
'disableTrackReply' => false,
'disableOutOfOffice' => false,
'sequenceSharing' => false,
'sendUserIds' => [
'usr_2aBCdEfGHiJkLmNOp',
'usr_7xYzAbCdEfGhIjKlM'
],
'autoReview' => true,
'autoReviewConditions' => [
'deliverable',
'risky'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}emoji is a campaign field, not a setting: the deprecation above does not apply to it. It can be changed but not removed.
sendUserIds replaces the sender pool and keeps the first account of each channel type for each sender. To add a sender without a replacement, or to pick a mailbox, a WhatsApp account or an alias, use the Senders endpoints.Authorizations
Body
Array of user IDs (usr_xxx format) to assign as campaign senders. Cannot be used on campaigns with a dynamic sender strategy (contactOwner, leadImporter, customField). Each sender is validated against the campaign's sending channels (email, LinkedIn, SMS, WhatsApp): senders without capabilities for at least one channel are excluded, and every channel that a lead can reach in the sequence must be covered by at least one sender. Replaces the sender pool, with the first account of each channel type for each sender. To add a sender without a replacement, pick an account or an alias, use the Senders endpoints.
Email deliverability statuses for which a lead is auto-launched when autoReview is enabled. Only leads whose email verification matches one of these statuses are launched automatically. Invalid values are rejected with a 400 error.
deliverable, risky, undeliverable, unverified Response
Success
Was this page helpful?