Skip to main content
This event is triggered when a campaign is paused, either manually through the dashboard/API or automatically due to system conditions.

When This Event Fires

  • Campaign is paused via the Pause Campaign API
  • Campaign is manually paused through the dashboard
  • Campaign transitions to PAUSED status

Payload

{
  "eventId": "evt_1708456789123_abc123def",
  "eventType": "campaign.paused",
  "timestamp": "2024-02-24T10:30:00.000Z",
  "workspaceId": "ws_abc123xyz",
  "data": {
    "campaignId": "camp_xyz789",
    "campaignName": "Q1 Tech Founders Outreach",
    "pausedAt": "2024-02-24T10:30:00.000Z",
    "pausedBy": "api"
  }
}

Payload Fields

FieldTypeDescription
eventIdstringUnique event identifier for idempotency
eventTypestringAlways campaign.paused
timestampstringISO 8601 timestamp when the event occurred
workspaceIdstringYour workspace ID
data.campaignIdstringUnique campaign identifier
data.campaignNamestringHuman-readable campaign name
data.pausedAtstringISO 8601 timestamp when the campaign was paused
data.pausedBystringHow the campaign was paused: api, user, or system

Use Cases

Monitoring

Track when campaigns stop running

Alerting

Alert team when campaigns are paused unexpectedly

Reporting

Track campaign uptime and pauses

Automation

Trigger follow-up actions when campaigns pause

Example Handler

app.post('/webhooks/sendpilot', async (req, res) => {
  const event = req.body;
  
  if (event.eventType === 'campaign.paused') {
    const { campaignId, campaignName, pausedAt, pausedBy } = event.data;
    
    // Log the pause event
    await analytics.track('campaign_paused', {
      campaignId,
      campaignName,
      pausedBy
    });
    
    // Alert if paused by system (might indicate an issue)
    if (pausedBy === 'system') {
      await slack.postMessage({
        channel: '#alerts',
        text: `⚠️ Campaign auto-paused by system!\n` +
              `Name: ${campaignName}\n` +
              `Time: ${pausedAt}\n` +
              `Please check the campaign for issues.`
      });
    } else {
      await slack.postMessage({
        channel: '#campaigns',
        text: `⏸️ Campaign paused\n` +
              `Name: ${campaignName}\n` +
              `Paused by: ${pausedBy}`
      });
    }
    
    console.log(`Campaign ${campaignName} paused by ${pausedBy}`);
  }
  
  res.status(200).send('OK');
});
When a campaign is paused, no new actions will be taken for leads. In-progress actions may still complete. The campaign can be resumed via the API or dashboard.