1MSG
ReferenceCampaigns API

Errors by reason

GET
/api/v1/campaigns/{campaignId}/analytics/errors

Groups failed and skipped recipients by reason. type is failed or skipped. recipientsLimit is how many recipients to include per reason, default 20, maximum 100. Each recipient includes providerConversationId and providerMessageId.

Authorization

bearer
headerAuthorizationBearer <token>

Key issued in Settings → Developer → API key. Inbox methods need the Inbox scope. Campaigns methods need the Campaigns scope.

Path Parameters

campaignId*string

Campaign id returned by create or list.

Query Parameters

recipientsLimit?number

Recipients shown per reason. Default 20, max 100.

type?string

failed keeps send errors. skipped keeps recipients that were not sent. Omit to return both.

Value in"failed""skipped"

Response Body

application/json
  1. response
campaignId*string

Campaign id.

items*array<>

Errors grouped by reason, code, title, and type.

curl -X GET 'https://api.1msg.io/api/v1/campaigns/string/analytics/errors'
{  "campaignId": "cm3campaign01",  "items": [    {      "reason": "closed_window",      "code": "string",      "title": "string",      "type": "failed",      "count": 2,      "share": 0.1667,      "recipients": [        {          "id": "cm3recipient01",          "phone": "+15551234567",          "bsuid": "ab.abc123xyz",          "name": "Ana",          "conversationId": "cm3dialog01",          "messageId": "wamid.HBgM",          "providerConversationId": "[email protected]",          "providerMessageId": "wamid.HBgM"        }      ],      "hasMore": false    }  ]}