> ## Documentation Index
> Fetch the complete documentation index at: https://api.smartlead.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Campaign Diagnostics

> One read that says whether a campaign can send: status, lead and email counts, disconnected mailboxes, recent send errors and plain-English recommendations

Use this to answer "is my campaign sending, and if not, why?" in one call. It reads only; nothing is changed.

## Path Parameters

**campaignId** `integer` *required*

Campaign ID (positive integer)

## Query Parameters

**api\_key** `string` *required*

Your SmartLead API key

```bash cURL theme={null}
curl "https://server.smartlead.ai/api/v1/mcp-diagnostics/campaign-diagnostics/123?api_key=YOUR_KEY"
```

```python Python theme={null}
import requests

d = requests.get(
    "https://server.smartlead.ai/api/v1/mcp-diagnostics/campaign-diagnostics/123",
    params={"api_key": "YOUR_API_KEY"},
).json()["data"]
print(d["diagnostics"]["isHealthy"], d["diagnostics"]["recommendation"])
```

```json 200 theme={null}
{
  "success": true,
  "data": {
    "campaign": {
      "id": 123,
      "name": "Q4 Outreach",
      "status": "ACTIVE",
      "createdAt": "2026-11-01T10:00:00.000Z",
      "startedAt": "2026-11-02T09:00:00.000Z",
      "completedAt": null,
      "tracking": {
        "openTrackingDisabled": false,
        "clickTrackingDisabled": false,
        "sendAsPlainText": false,
        "forcePlainText": false,
        "trackSettings": []
      },
      "user": { "id": 1001, "email": "jane@example.com", "name": "Jane Doe" }
    },
    "stats": {
      "leads": { "total": 500, "completed": 120, "scheduled": 300, "paused": 10 },
      "emails": { "sent": 800, "opened": 240, "clicked": 30, "replied": 25, "bounced": 12, "unsubscribed": 3 },
      "rates": { "openRate": "30.00", "clickRate": "3.75", "replyRate": "3.13", "bounceRate": "1.50" }
    },
    "emailAccounts": {
      "total": 3,
      "connected": 2,
      "disconnected": [
        { "id": 77, "email": "sales@example.com", "isSmtpConnected": false, "isImapConnected": true, "dailyLimit": 40 }
      ]
    },
    "sequences": 3,
    "errors": [
      { "error_message": "Mailbox daily limit reached", "error_type": "FAILED", "error_count": "4", "last_occurred": "2026-11-27T08:00:00.000Z" }
    ],
    "leadIntegrity": {
      "leadIntegrity": {
        "total_in_progress": "300",
        "leads_with_no_emails": "0",
        "stuck_leads": "2",
        "total_bounces": "12",
        "total_failed": "4",
        "total_stopped": "1"
      },
      "bounceAnalysis": {
        "bounced_leads": "12",
        "gmail_bounces": "5",
        "outlook_bounces": "4",
        "smtp_bounces": "3",
        "unknown_type_bounces": "0",
        "sender_bounces": 0,
        "estimatedHardBounces": 9,
        "estimatedSoftBounces": 2,
        "sampleSize": 12,
        "bounceTypeEstimationNote": "Bounce types estimated from sample of 100 recent bounces",
        "hardBounceContent": [],
        "softBounceContent": []
      }
    },
    "diagnostics": {
      "isHealthy": true,
      "hasEmailAccounts": true,
      "hasActiveAccounts": true,
      "hasHighBounceRate": false,
      "hasRecentErrors": true,
      "tracking": {
        "openTrackingEnabled": true,
        "clickTrackingEnabled": true,
        "lowOpenRateAcceptable": false,
        "lowClickRateAcceptable": false
      },
      "recommendation": [
        "1 email account(s) are disconnected. Reconnect them.",
        "1 error types detected in the last 7 days. Review and fix."
      ]
    }
  }
}
```

```json 403 - Not your campaign theme={null}
{
  "success": false,
  "message": "Campaign not found or unauthorized access"
}
```

```json 500 theme={null}
{
  "success": false,
  "message": "Internal server error"
}
```

## Response Fields

**data.diagnostics.isHealthy** `boolean`

`true` when the campaign is `ACTIVE` and at least one of its mailboxes has a working SMTP connection

**data.diagnostics.recommendation** `array`

Plain-English next steps, for example to reconnect a mailbox or look at a high bounce rate

**data.diagnostics.hasHighBounceRate** `boolean`

`true` when more than 5% of sent emails bounced

**data.emailAccounts.disconnected** `array`

Mailboxes in this campaign whose SMTP or IMAP connection is failing

**data.errors** `array`

Up to 10 most frequent send errors (emails with status `FAILED`, `STOPPED` or `ERROR`) from the last 7 days

**data.stats.rates** `object`

Percentages of sent emails, as strings with 2 decimals (`0` when nothing was sent)

**data.leadIntegrity** `object`

`leadIntegrity`: counts over leads still in progress (`stuck_leads` = last email sent more than 7 days ago). `bounceAnalysis`: bounces by mailbox type, with hard and soft bounces estimated from up to 100 recent bounce messages. Counts from the database come back as strings.

## Related Endpoints

* [Get Campaign](https://api.smartlead.ai/api-reference/campaigns/get-by-id.md)
* [Check Mailbox Domain Deliverability](https://api.smartlead.ai/api-reference/email-accounts/domain-deliverability.md)
* [List Email Accounts](https://api.smartlead.ai/api-reference/email-accounts/get-all.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.