Skip to main content
Use this endpoint to pull performance metrics for any campaign in your workspace. The response includes counters for every major delivery event — sent, delivered, bounced, and replied — as well as the current queue depth and computed rates. Metrics are updated in near real-time, making this endpoint suitable for polling from dashboards or agent workflows that need live visibility into campaign health.
GET /v1/campaigns/:id/stats

Authorization

All requests must include a Bearer token in the Authorization header. You can find your API key in the Leadterra dashboard under Settings → API Keys.

Path Parameters

id
string
required
The unique ID of the campaign whose metrics you want to retrieve. You receive this ID when you create a campaign. Example: camp_123.

Request Body

This endpoint accepts no request body.

Example Request

curl --request GET \
  --url https://app.leadterra.co/v1/campaigns/camp_123/stats \
  --header "Authorization: Bearer sk_live_YOUR_KEY" \
  --header "Content-Type: application/json"

Response Fields

campaignId
string
The ID of the campaign these metrics belong to.
totalEnrolled
integer
Total number of leads enrolled in the campaign, regardless of their current send state.
sent
integer
Number of emails that have been submitted for delivery. Includes emails regardless of delivery outcome.
delivered
integer
Number of emails confirmed as accepted by the recipient’s mail server. Does not imply the email reached the inbox.
bounced
integer
Number of emails that resulted in a hard or soft bounce. Leads that trigger a hard bounce are automatically suppressed from future sends.
replied
integer
Number of leads who have sent at least one reply to any step in the sequence. Leads with a reply are automatically removed from further sequence steps.
queued
integer
Number of emails currently waiting in the send queue. A non-zero value while the campaign is paused indicates held messages that will resume on restart.
openRate
float
Ratio of unique opens to delivered emails, expressed as a decimal between 0 and 1. For example, 0.42 represents a 42 % open rate.
replyRate
float
Ratio of replied leads to delivered emails, expressed as a decimal between 0 and 1. For example, 0.08 represents an 8 % reply rate.

Example Response

{
  "campaignId": "camp_123",
  "totalEnrolled": 500,
  "sent": 480,
  "delivered": 471,
  "bounced": 9,
  "replied": 38,
  "queued": 20,
  "openRate": 0.42,
  "replyRate": 0.08
}

Error Codes

HTTP StatusCodeMeaning
400 Bad Requestinvalid_requestThe request was malformed or contained unexpected parameters.
401 Unauthorizedauthentication_failedThe Authorization header is missing, malformed, or the key is invalid.
404 Not Foundcampaign_not_foundNo campaign with the given id exists in your workspace.