API RU
Early access. API keys are issued on request. How to get a key

Lead, campaign and account status changes, the initial snapshot and completeness of the available history.

#The LeadStatusTransition object

An actual status change. The allowed statuses depend on entity_kind.

Attributes

  • objectstring
    Object type, always message.
  • idstring (uuid)
    Opaque, stable message ID. Do not parse its format.
  • workspace_idstring (uuid)
    Workspace ID.
  • campaign_idstring (uuid)
    Campaign ID.
  • lead_idstring (uuid) or null
    The lead's participation ID in the campaign. May be null in campaign or account history.
  • Entity kind: lead, campaign or account. Always "lead".
  • entity_idstring (uuid)
    The ID of the entity whose status changed.
  • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
  • The previous public status. Unrecognized values are returned as unknown. Values: new contacted completed replied blocked failed suspended deleted opted_out unknown
  • to_statusstring
    The new public status. Unrecognized values are returned as unknown. Values: new contacted completed replied blocked failed suspended deleted opted_out unknown
  • The reason for the status change. unspecified if unknown. Values: operator_action schedule queue_exhausted recipient_not_found telegram_auth subscription recovery unspecified
  • sourcestring
    The record source, or unknown if unavailable. Statistics always use task_states. Values: user system support unknown
  • occurred_atstring (date-time)
    When the change occurred.
  • recorded_atstring (date-time)
    When the change or initial snapshot was recorded.
LeadStatusTransition
{
  "object": "status_transition",
  "id": "00000000-0000-4000-8000-000000000001",
  "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
  "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
  "lead_id": "5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31",
  "entity_kind": "lead",
  "entity_id": "5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31",
  "entity_revision": 1,
  "from_status": "new",
  "to_status": "contacted",
  "reason_code": "operator_action",
  "source": "user",
  "occurred_at": "2026-10-27T09:15:42.000Z",
  "recorded_at": "2026-10-27T09:15:42.000Z"
}

#The CampaignStatusTransition object

An actual status change. The allowed statuses depend on entity_kind.

Attributes

  • objectstring
    Object type, always message.
  • idstring (uuid)
    Opaque, stable message ID. Do not parse its format.
  • workspace_idstring (uuid)
    Workspace ID.
  • campaign_idstring (uuid)
    Campaign ID.
  • lead_idstring (uuid) or null
    The lead's participation ID in the campaign. May be null in campaign or account history.
  • Entity kind: lead, campaign or account. Always "campaign".
  • entity_idstring (uuid)
    The ID of the entity whose status changed.
  • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
  • The previous public status. Unrecognized values are returned as unknown. Values: draft scheduled active paused stopped completed archived launching failed paused_no_credits unknown
  • to_statusstring
    The new public status. Unrecognized values are returned as unknown. Values: draft scheduled active paused stopped completed archived launching failed paused_no_credits unknown
  • The reason for the status change. unspecified if unknown. Values: operator_action schedule queue_exhausted recipient_not_found telegram_auth subscription recovery unspecified
  • sourcestring
    The record source, or unknown if unavailable. Statistics always use task_states. Values: user system support unknown
  • occurred_atstring (date-time)
    When the change occurred.
  • recorded_atstring (date-time)
    When the change or initial snapshot was recorded.
CampaignStatusTransition
{
  "object": "status_transition",
  "id": "00000000-0000-4000-8000-000000000002",
  "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
  "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
  "lead_id": null,
  "entity_kind": "campaign",
  "entity_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
  "entity_revision": 1,
  "from_status": "draft",
  "to_status": "active",
  "reason_code": "operator_action",
  "source": "user",
  "occurred_at": "2026-10-27T09:15:42.000Z",
  "recorded_at": "2026-10-27T09:15:42.000Z"
}

#The AccountStatusTransition object

An actual status change. The allowed statuses depend on entity_kind.

Attributes

  • objectstring
    Object type, always message.
  • idstring (uuid)
    Opaque, stable message ID. Do not parse its format.
  • workspace_idstring (uuid)
    Workspace ID.
  • campaign_idstring (uuid)
    Campaign ID.
  • lead_idstring (uuid) or null
    The lead's participation ID in the campaign. May be null in campaign or account history.
  • Entity kind: lead, campaign or account. Always "account".
  • entity_idstring (uuid)
    The ID of the entity whose status changed.
  • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
  • The previous public status. Unrecognized values are returned as unknown. Values: online offline limited banned deleted locked unauthorized paused unknown
  • to_statusstring
    The new public status. Unrecognized values are returned as unknown. Values: online offline limited banned deleted locked unauthorized paused unknown
  • The reason for the status change. unspecified if unknown. Values: operator_action schedule queue_exhausted recipient_not_found telegram_auth subscription recovery unspecified
  • sourcestring
    The record source, or unknown if unavailable. Statistics always use task_states. Values: user system support unknown
  • occurred_atstring (date-time)
    When the change occurred.
  • recorded_atstring (date-time)
    When the change or initial snapshot was recorded.
AccountStatusTransition
{
  "object": "status_transition",
  "id": "00000000-0000-4000-8000-000000000003",
  "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
  "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
  "lead_id": null,
  "entity_kind": "account",
  "entity_id": "1d9f6b28-4c3e-4a75-8b19-5e7a2c0f6d83",
  "entity_revision": 1,
  "from_status": "online",
  "to_status": "paused",
  "reason_code": "operator_action",
  "source": "user",
  "occurred_at": "2026-10-27T09:15:42.000Z",
  "recorded_at": "2026-10-27T09:15:42.000Z"
}

#The StatusBaseline object

An initial status snapshot. It is not a transition and does not produce a status change event.

Attributes

Variant 1
  • objectstring
    Object type, always message.
  • workspace_idstring (uuid)
    Workspace ID.
  • campaign_idstring (uuid)
    Campaign ID.
  • lead_idstring (uuid) or null
    The lead's participation ID in the campaign. May be null in campaign or account history.
  • Entity kind: lead, campaign or account. Always "lead".
  • entity_idstring (uuid)
    The ID of the entity whose status changed.
  • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
  • statusstring
    The public status or completeness state. Unrecognized values are returned as unknown. Values: new contacted completed replied blocked failed suspended deleted opted_out unknown
  • recorded_atstring (date-time)
    When the change or initial snapshot was recorded.
  • Always baseline: an initial snapshot, not a status change.
Variant 2
  • objectstring
    Object type, always message.
  • workspace_idstring (uuid)
    Workspace ID.
  • campaign_idstring (uuid)
    Campaign ID.
  • lead_idstring (uuid) or null
    The lead's participation ID in the campaign. May be null in campaign or account history.
  • Entity kind: lead, campaign or account. Always "campaign".
  • entity_idstring (uuid)
    The ID of the entity whose status changed.
  • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
  • statusstring
    The public status or completeness state. Unrecognized values are returned as unknown. Values: draft scheduled active paused stopped completed archived launching failed paused_no_credits unknown
  • recorded_atstring (date-time)
    When the change or initial snapshot was recorded.
  • Always baseline: an initial snapshot, not a status change.
Variant 3
  • objectstring
    Object type, always message.
  • workspace_idstring (uuid)
    Workspace ID.
  • campaign_idstring (uuid)
    Campaign ID.
  • lead_idstring (uuid) or null
    The lead's participation ID in the campaign. May be null in campaign or account history.
  • Entity kind: lead, campaign or account. Always "account".
  • entity_idstring (uuid)
    The ID of the entity whose status changed.
  • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
  • statusstring
    The public status or completeness state. Unrecognized values are returned as unknown. Values: online offline limited banned deleted locked unauthorized paused unknown
  • recorded_atstring (date-time)
    When the change or initial snapshot was recorded.
  • Always baseline: an initial snapshot, not a status change.
StatusBaseline
{
  "object": "status_baseline",
  "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
  "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
  "lead_id": "5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31",
  "entity_kind": "lead",
  "entity_id": "5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31",
  "entity_revision": 0,
  "status": "new",
  "recorded_at": "2026-10-26T07:30:00.000Z",
  "provenance": "baseline"
}

#Lead status history

GET/v1/leads/{id}/status-history

Actual lead status changes in ascending entity_revision order. The initial snapshot is separate, in meta.baseline. New features are enabled for your organization on request.

Permission
leads:read
Request weight
2

Parameters

  • idstring (uuid), pathrequired
    Lead ID.
  • limitinteger, queryoptional
    Number of objects to return per page. From 1 to 100. Defaults to 50.
  • cursorstring, queryoptional
    The next_cursor value from the previous response. Other filters must match the first request.

Response

A list: object, data (an array of LeadStatusTransition objects), has_more, next_cursor, meta. See Pagination.

The meta field

  • baselineobject or null
    An initial status snapshot, or null. It is not a transition and does not prove earlier history.
    Child attributes
    • objectstring
      Object type, always message.
    • workspace_idstring (uuid)
      Workspace ID.
    • campaign_idstring (uuid)
      Campaign ID.
    • lead_idstring (uuid) or null
      The lead's participation ID in the campaign. May be null in campaign or account history.
    • Entity kind: lead, campaign or account. Always "lead".
    • entity_idstring (uuid)
      The ID of the entity whose status changed.
    • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
    • statusstring
      The public status or completeness state. Unrecognized values are returned as unknown. Values: new contacted completed replied blocked failed suspended deleted opted_out unknown
    • recorded_atstring (date-time)
      When the change or initial snapshot was recorded.
    • Always baseline: an initial snapshot, not a status change.
  • available_fromstring (date-time) or null
    Start of the period covered by the data. null if unknown.
  • history_started_atstring (date-time) or null
    When history collection started. Earlier changes are not reconstructed.
  • retained_fromstring (date-time) or null
    The beginning of the retained history period, or null if unknown.
  • Data completeness. has_more=false means there are no more pages, not that the history is complete.
    Child attributes
    • statusstring
      complete, partial or unknown. Values: complete partial unknown
    • gapsarray of object
      Up to 50 intervals of possible incompleteness. Up to 50 items.
      Child attributes
      • idstring (uuid)
        Interval ID.
      • fromstring (date-time)
        Start of the interval.
      • tostring (date-time) or null
        End of the interval. null if the interval is not closed yet.
      • statestring
        open, recovering, recovered, unrecoverable or unknown. Values: open recovering recovered unrecoverable unknown
    • true if there are more than 50 intervals.
    • incomplete_fromstring (date-time) or null
      Earliest boundary of the hidden incomplete intervals. null if there are none.
  • observed_atstring (date-time)
    Time the server read the data.

Endpoint-specific errors

  • cursor_mismatch: The cursor is corrupted, was issued for a different route or filters, or the key's permissions and scope have changed.
  • scope_required: The key does not permit the operation. A command requires its kind permission.
  • not_found: The object was not found or is outside the key's scope. An unknown path also returns 404.
  • cursor_expired: The cursor expired: 15 minutes for lists, 30 days for the event feed.

Common errors are described in Errors.

Request
curl https://api.melioralab.io/v1/leads/5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31/status-history \
  -H "Authorization: Bearer $MELIORA_API_KEY"
Response
{
  "object": "list",
  "data": [
    {
      "object": "status_transition",
      "id": "00000000-0000-4000-8000-000000000001",
      "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
      "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
      "lead_id": "5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31",
      "entity_kind": "lead",
      "entity_id": "5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31",
      "entity_revision": 1,
      "from_status": "new",
      "to_status": "contacted",
      "reason_code": "operator_action",
      "source": "user",
      "occurred_at": "2026-10-27T09:15:42.000Z",
      "recorded_at": "2026-10-27T09:15:42.000Z"
    }
  ],
  "has_more": false,
  "next_cursor": null,
  "meta": {
    "baseline": {
      "object": "status_baseline",
      "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
      "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
      "lead_id": "5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31",
      "entity_kind": "lead",
      "entity_id": "5a7c3e92-1f4b-4d68-9c2e-7b0a6d4f8e31",
      "entity_revision": 0,
      "status": "new",
      "recorded_at": "2026-10-26T07:30:00.000Z",
      "provenance": "baseline"
    },
    "available_from": "2026-10-26T07:30:00.000Z",
    "history_started_at": "2026-10-26T07:30:00.000Z",
    "retained_from": "2026-10-26T07:30:00.000Z",
    "completeness": {
      "status": "complete",
      "gaps": [],
      "gaps_truncated": false,
      "incomplete_from": null
    },
    "observed_at": "2026-10-27T09:15:42.000Z"
  }
}

#Campaign status history

GET/v1/campaigns/{id}/status-history

Actual campaign status changes in ascending entity_revision order. New features are enabled for your organization on request.

Permission
campaigns:read
Request weight
2

Parameters

  • idstring (uuid), pathrequired
    Campaign ID.
  • limitinteger, queryoptional
    Number of objects to return per page. From 1 to 100. Defaults to 50.
  • cursorstring, queryoptional
    The next_cursor value from the previous response. Other filters must match the first request.

Response

A list: object, data (an array of CampaignStatusTransition objects), has_more, next_cursor, meta. See Pagination.

The meta field

  • baselineobject or null
    An initial status snapshot, or null. It is not a transition and does not prove earlier history.
    Child attributes
    • objectstring
      Object type, always message.
    • workspace_idstring (uuid)
      Workspace ID.
    • campaign_idstring (uuid)
      Campaign ID.
    • lead_idstring (uuid) or null
      The lead's participation ID in the campaign. May be null in campaign or account history.
    • Entity kind: lead, campaign or account. Always "campaign".
    • entity_idstring (uuid)
      The ID of the entity whose status changed.
    • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
    • statusstring
      The public status or completeness state. Unrecognized values are returned as unknown. Values: draft scheduled active paused stopped completed archived launching failed paused_no_credits unknown
    • recorded_atstring (date-time)
      When the change or initial snapshot was recorded.
    • Always baseline: an initial snapshot, not a status change.
  • available_fromstring (date-time) or null
    Start of the period covered by the data. null if unknown.
  • history_started_atstring (date-time) or null
    When history collection started. Earlier changes are not reconstructed.
  • retained_fromstring (date-time) or null
    The beginning of the retained history period, or null if unknown.
  • Data completeness. has_more=false means there are no more pages, not that the history is complete.
    Child attributes
    • statusstring
      complete, partial or unknown. Values: complete partial unknown
    • gapsarray of object
      Up to 50 intervals of possible incompleteness. Up to 50 items.
      Child attributes
      • idstring (uuid)
        Interval ID.
      • fromstring (date-time)
        Start of the interval.
      • tostring (date-time) or null
        End of the interval. null if the interval is not closed yet.
      • statestring
        open, recovering, recovered, unrecoverable or unknown. Values: open recovering recovered unrecoverable unknown
    • true if there are more than 50 intervals.
    • incomplete_fromstring (date-time) or null
      Earliest boundary of the hidden incomplete intervals. null if there are none.
  • observed_atstring (date-time)
    Time the server read the data.

Endpoint-specific errors

  • cursor_mismatch: The cursor is corrupted, was issued for a different route or filters, or the key's permissions and scope have changed.
  • scope_required: The key does not permit the operation. A command requires its kind permission.
  • not_found: The object was not found or is outside the key's scope. An unknown path also returns 404.
  • cursor_expired: The cursor expired: 15 minutes for lists, 30 days for the event feed.

Common errors are described in Errors.

Request
curl https://api.melioralab.io/v1/campaigns/4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14/status-history \
  -H "Authorization: Bearer $MELIORA_API_KEY"
Response
{
  "object": "list",
  "data": [
    {
      "object": "status_transition",
      "id": "00000000-0000-4000-8000-000000000002",
      "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
      "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
      "lead_id": null,
      "entity_kind": "campaign",
      "entity_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
      "entity_revision": 1,
      "from_status": "draft",
      "to_status": "active",
      "reason_code": "operator_action",
      "source": "user",
      "occurred_at": "2026-10-27T09:15:42.000Z",
      "recorded_at": "2026-10-27T09:15:42.000Z"
    }
  ],
  "has_more": false,
  "next_cursor": null,
  "meta": {
    "baseline": {
      "object": "status_baseline",
      "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
      "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
      "lead_id": null,
      "entity_kind": "campaign",
      "entity_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
      "entity_revision": 0,
      "status": "draft",
      "recorded_at": "2026-10-26T07:30:00.000Z",
      "provenance": "baseline"
    },
    "available_from": "2026-10-26T07:30:00.000Z",
    "history_started_at": "2026-10-26T07:30:00.000Z",
    "retained_from": "2026-10-26T07:30:00.000Z",
    "completeness": {
      "status": "complete",
      "gaps": [],
      "gaps_truncated": false,
      "incomplete_from": null
    },
    "observed_at": "2026-10-27T09:15:42.000Z"
  }
}

#Campaign account status history

GET/v1/campaigns/{id}/accounts/{account_id}/status-history

Account history in the selected campaign, without exposing other campaigns. New features are enabled for your organization on request.

Permission
accounts:read
Request weight
2

Parameters

  • idstring (uuid), pathrequired
    Campaign ID.
  • account_idstring (uuid), pathrequired
    Account ID.
  • limitinteger, queryoptional
    Number of objects to return per page. From 1 to 100. Defaults to 50.
  • cursorstring, queryoptional
    The next_cursor value from the previous response. Other filters must match the first request.

Response

A list: object, data (an array of AccountStatusTransition objects), has_more, next_cursor, meta. See Pagination.

The meta field

  • baselineobject or null
    An initial status snapshot, or null. It is not a transition and does not prove earlier history.
    Child attributes
    • objectstring
      Object type, always message.
    • workspace_idstring (uuid)
      Workspace ID.
    • campaign_idstring (uuid)
      Campaign ID.
    • lead_idstring (uuid) or null
      The lead's participation ID in the campaign. May be null in campaign or account history.
    • Entity kind: lead, campaign or account. Always "account".
    • entity_idstring (uuid)
      The ID of the entity whose status changed.
    • The entity's record sequence number. Transitions start at 1; the initial snapshot may have revision 0.
    • statusstring
      The public status or completeness state. Unrecognized values are returned as unknown. Values: online offline limited banned deleted locked unauthorized paused unknown
    • recorded_atstring (date-time)
      When the change or initial snapshot was recorded.
    • Always baseline: an initial snapshot, not a status change.
  • available_fromstring (date-time) or null
    Start of the period covered by the data. null if unknown.
  • history_started_atstring (date-time) or null
    When history collection started. Earlier changes are not reconstructed.
  • retained_fromstring (date-time) or null
    The beginning of the retained history period, or null if unknown.
  • Data completeness. has_more=false means there are no more pages, not that the history is complete.
    Child attributes
    • statusstring
      complete, partial or unknown. Values: complete partial unknown
    • gapsarray of object
      Up to 50 intervals of possible incompleteness. Up to 50 items.
      Child attributes
      • idstring (uuid)
        Interval ID.
      • fromstring (date-time)
        Start of the interval.
      • tostring (date-time) or null
        End of the interval. null if the interval is not closed yet.
      • statestring
        open, recovering, recovered, unrecoverable or unknown. Values: open recovering recovered unrecoverable unknown
    • true if there are more than 50 intervals.
    • incomplete_fromstring (date-time) or null
      Earliest boundary of the hidden incomplete intervals. null if there are none.
  • observed_atstring (date-time)
    Time the server read the data.

Endpoint-specific errors

  • cursor_mismatch: The cursor is corrupted, was issued for a different route or filters, or the key's permissions and scope have changed.
  • scope_required: The key does not permit the operation. A command requires its kind permission.
  • not_found: The object was not found or is outside the key's scope. An unknown path also returns 404.
  • cursor_expired: The cursor expired: 15 minutes for lists, 30 days for the event feed.

Common errors are described in Errors.

Request
curl https://api.melioralab.io/v1/campaigns/4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14/accounts/1d9f6b28-4c3e-4a75-8b19-5e7a2c0f6d83/status-history \
  -H "Authorization: Bearer $MELIORA_API_KEY"
Response
{
  "object": "list",
  "data": [
    {
      "object": "status_transition",
      "id": "00000000-0000-4000-8000-000000000003",
      "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
      "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
      "lead_id": null,
      "entity_kind": "account",
      "entity_id": "1d9f6b28-4c3e-4a75-8b19-5e7a2c0f6d83",
      "entity_revision": 1,
      "from_status": "online",
      "to_status": "paused",
      "reason_code": "operator_action",
      "source": "user",
      "occurred_at": "2026-10-27T09:15:42.000Z",
      "recorded_at": "2026-10-27T09:15:42.000Z"
    }
  ],
  "has_more": false,
  "next_cursor": null,
  "meta": {
    "baseline": {
      "object": "status_baseline",
      "workspace_id": "3f6a9d21-8b4c-4e7f-a102-5c9e8d7b6a43",
      "campaign_id": "4d8b2f73-6e1a-4c95-b7d0-8a3f5e2c9b14",
      "lead_id": null,
      "entity_kind": "account",
      "entity_id": "1d9f6b28-4c3e-4a75-8b19-5e7a2c0f6d83",
      "entity_revision": 0,
      "status": "online",
      "recorded_at": "2026-10-26T07:30:00.000Z",
      "provenance": "baseline"
    },
    "available_from": "2026-10-26T07:30:00.000Z",
    "history_started_at": "2026-10-26T07:30:00.000Z",
    "retained_from": "2026-10-26T07:30:00.000Z",
    "completeness": {
      "status": "complete",
      "gaps": [],
      "gaps_truncated": false,
      "incomplete_from": null
    },
    "observed_at": "2026-10-27T09:15:42.000Z"
  }
}