JavaScript SDK: swarmhit.campaigns.leads.pause(campaignId, leadId)
Freezes the lead's sequence so the executor stops contacting it
(status becomes paused). It is resumable: step progress and timers are
kept, so resuming continues from where it left off. Applies only to a
pending or running lead; on any other it changes nothing and still
returns 200. A manual message does not pause a lead by itself: to pause
when replying from the inbox, send it with sequenceAction: pause.
Authorization
bearerAuth An API key created on the Access tokens page.
In: header
Path Parameters
The lead's id.
Response Body
application/json
application/json
application/json
curl -X POST "https://example.com/campaigns/string/leads/string/pause"{ "data": { "campaignId": "string", "leadId": "string", "senderId": "string", "linkedinAccountId": "string", "emailAccountId": "string", "emailProvider": "google", "whatsappAccountId": "string", "status": "pending", "stage": "pending", "firstName": "string", "lastName": "string", "headline": "string", "company": "string", "picture": "string", "profileUrl": "string", "publicIdentifier": "string", "email": "string", "openProfile": true, "customVariables": { "property1": "string", "property2": "string" }, "label": "interested", "labelBy": "manual", "labelAt": "2019-08-24T14:15:22Z", "interest": "interested", "interestBy": "manual", "currentStepId": "string", "waitUntil": "2019-08-24T14:15:22Z", "waitReason": "company_limit", "pausedReason": "user", "heldBy": { "campaignId": "string", "campaignName": "string", "senderName": "string" }, "invitationSentAt": "2019-08-24T14:15:22Z", "invitationAccepted": true, "invitationAcceptedAt": "2019-08-24T14:15:22Z", "invitationWithdrawnAt": "2019-08-24T14:15:22Z", "invitationSentWithoutNote": true, "messageSentAt": "2019-08-24T14:15:22Z", "lastReplyAt": "2019-08-24T14:15:22Z", "emailOpenedAt": "2019-08-24T14:15:22Z", "emailClickedAt": "2019-08-24T14:15:22Z", "finishedAt": "2019-08-24T14:15:22Z", "error": "string", "createdAt": "2019-08-24T14:15:22Z" }}List the leads in a campaign GET
**JavaScript SDK:** [`swarmhit.campaigns.leads.list(campaignId, params?)`](/smart-api/sdk/methods#campaigns.leads) The leads in a campaign and each one's progress (stage, step, invite sent/accepted, replied, label), newest first. The filters combine: for example `stage=invited&accountId=…` lists the leads whose connection request from that account waits for an answer, and `reachedStepId=…&label=interested` the interested leads among those a step reached. Step ids are the `sequence.steps[].id` of `GET /campaigns/{id}`.
Remove a lead from a campaign DELETE
**JavaScript SDK:** [`swarmhit.campaigns.leads.remove(campaignId, leadId)`](/smart-api/sdk/methods#campaigns.leads) Removes the lead from this campaign and from the campaign's own list. The underlying lead is kept.