Skip to main content
When a lead responds to one of your outbound sequences, Leadterra automatically classifies the reply and surfaces it through this endpoint. Each reply object includes the sender’s email, the campaign it belongs to, a classification label (such as interested or out_of_office), a snippet of the thread, and the timestamp it was received. You can retrieve all replies across your workspace or narrow the results to a single campaign using the campaignId query parameter.

Endpoint

GET /v1/replies

Authorization

All requests must include a valid API key in the Authorization header as a Bearer token.
Authorization: Bearer sk_live_YOUR_KEY

Query Parameters

campaignId
string
When provided, the response is filtered to include only replies associated with the specified campaign. Omit this parameter to retrieve replies across all campaigns in your workspace.

Example Request

curl -G https://app.leadterra.co/v1/replies \
  -H "Authorization: Bearer sk_live_YOUR_KEY" \
  --data-urlencode "campaignId=camp_123"

Response Fields

The response is an array of reply objects. Each object contains the following fields:
id
string
The unique identifier for this reply.
email
string
The email address of the lead who sent the reply.
campaignId
string
The ID of the campaign that generated the outbound thread this reply belongs to.
classification
string
Leadterra’s automated classification of the reply intent. Possible values:
  • interested — the lead has expressed positive intent or requested more information.
  • not_interested — the lead has declined or asked to stop outreach.
  • out_of_office — an automated out-of-office or vacation reply was detected.
  • bounce — the message could not be delivered and generated a delivery failure notice.
  • unsubscribe — the lead explicitly requested removal from future emails.
receivedAt
string
ISO 8601 timestamp indicating when the reply was received by Leadterra.
threadSnippet
string
A short excerpt from the reply body, suitable for displaying in a list view or feeding into a downstream agent prompt.

Example Response

[
  {
    "id": "rpl_001",
    "email": "ava@example.com",
    "campaignId": "camp_123",
    "classification": "interested",
    "receivedAt": "2025-06-10T14:22:00Z",
    "threadSnippet": "Hi, this looks really interesting — can you send over more details on pricing?"
  },
  {
    "id": "rpl_002",
    "email": "ben@example.com",
    "campaignId": "camp_123",
    "classification": "out_of_office",
    "receivedAt": "2025-06-10T15:05:00Z",
    "threadSnippet": "I'm currently out of the office until June 17th. I'll respond when I return."
  }
]
Prefer webhooks over polling. If you’re building an agent or automation that needs to react to replies in real time, register a webhook for the reply.received event instead of repeatedly polling this endpoint. See the Webhooks reference for setup instructions. Use GET /v1/replies for on-demand lookups, dashboards, or back-filling historical data.

Error Codes

CodeMeaning
400Bad Request — a query parameter is malformed or contains an invalid value.
401Unauthorized — your API key is missing, invalid, or revoked.
404Not Found — no campaign exists for the provided campaignId in your workspace.
422Unprocessable Entity — the request could not be processed due to a validation error.