Skip to main content
DELETE
/
api
/
v1
/
campaigns
/
{campaign_id}
curl -X DELETE "https://server.smartlead.ai/api/v1/campaigns/123?api_key=YOUR_API_KEY"
{
  "success": true,
  "message": "Campaign deleted successfully"
}
Strongly recommended: Export all important data first and consider using ARCHIVED status instead to preserve data while hiding from active views.
Permanently and irreversibly deletes a campaign and ALL associated data: sequences, lead-campaign mappings, email statistics, webhook configurations, scheduled emails, and conversation history

Path Parameters

campaign_id
number
required
The ID of the campaign to delete

Query Parameters

api_key
string
required
Your SmartLead API key
This action is permanent and cannot be undone!Deleting a campaign will remove:
  • All campaign sequences
  • All lead associations
  • All statistics and analytics data
  • All webhook configurations
  • All email threads and history
Consider using ARCHIVED status instead if you want to keep data.
curl -X DELETE "https://server.smartlead.ai/api/v1/campaigns/123?api_key=YOUR_API_KEY"

Response Codes

200
Success
Request successful
400
Bad Request
Invalid request parameters or malformed request body
401
Unauthorized
Invalid or missing API key. Check your authentication.
404
Not Found
The requested resource (campaign, lead, email account, etc.) does not exist or you don’t have access to it
422
Validation Error
Request validation failed. Check parameter types, required fields, and value constraints.
429
Rate Limit Exceeded
Too many requests. Please slow down and retry after the rate limit resets.
500
Internal Server Error
Server error occurred. Please try again or contact support if the issue persists.
503
Service Unavailable
API is temporarily unavailable or under maintenance. Please try again later.
{
  "success": true,
  "message": "Campaign deleted successfully"
}

Before Deleting

Export leads, statistics, and any important data before deleting
# Export leads first
curl "https://server.smartlead.ai/api/v1/campaigns/123/leads-export?api_key=YOUR_KEY"
Some systems require campaigns to be stopped before deletion
# Stop first
curl -X PATCH "https://server.smartlead.ai/api/v1/campaigns/123/status?api_key=YOUR_KEY" \
  -d '{"status": "STOPPED"}'

# Then delete
curl -X DELETE "https://server.smartlead.ai/api/v1/campaigns/123?api_key=YOUR_KEY"
If you might need the data later, use ARCHIVED status instead
curl -X PATCH "https://server.smartlead.ai/api/v1/campaigns/123/status?api_key=YOUR_KEY" \
  -d '{"status": "ARCHIVED"}'

Alternative: Archive Campaign

Instead of deleting, you can archive:
curl -X PATCH "https://server.smartlead.ai/api/v1/campaigns/123/status?api_key=YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"status": "ARCHIVED"}'
Benefits of Archiving:
  • ✅ Keeps all data
  • ✅ Reversible
  • ✅ Can analyze later
  • ✅ Hides from active list

Implementation Details

PERMANENT deletion. Cannot be undone. Exports data before deleting if you need it later. Response Format: object