API reference

Broadcasts

Create, manage, execute, and analyze broadcast campaigns.

Every request needs x-tenant-id and an API key or OAuth token. Channel IDs are copied from Settings → Developer in the app. See Authentication.

List broadcasts

get/api/public/v1/broadcasts

Returns a paginated, filterable, sortable list of broadcasts for the authenticated tenant.

Query parameters

  • pageinteger

    Default 1

  • limitinteger

    Default 25

  • sortstring

    namestatuscreatedAtupdatedAt

    Default "updatedAt"

  • orderstring

    ascdesc

    Default "desc"

  • statusstring

    DRAFTSCHEDULEDRUNNINGPAUSEDCOMPLETEDCANCELLEDFAILED

  • searchstring
  • channelIdstring

    WhatsApp channel to send from. Copy it from Settings → Developer → Channels in the inaiy app.

  • templateIdstring
  • createdBystring
  • isArchivedboolean
  • createdAfterstring (date-time)
  • createdBeforestring (date-time)
  • fieldsstring
Response 200Paginated list of broadcasts
  • successboolean
  • dataobject[]
    15 child fields
    • idstring
    • namestring
    • descriptionstring | null
    • statusstring | null

      One ofDRAFTSCHEDULEDRUNNINGPAUSEDCOMPLETEDCANCELLEDFAILEDnull

    • templateIdstring | null
    • compositionobject | null
      2 child fields
      • templateIdstring | null
      • parametersobject | null
    • audienceobject | null
      4 child fields
      • typestring | null

        One ofMANUALALLSEGMENTnull

      • selectionobject | null
        4 child fields
        • contactIdsstring[]
        • includeTagsstring[]
        • excludeContactIdsstring[]
        • excludeTagsstring[]
      • countsobject | null
      • validationobject | null
    • scheduleobject | null
    • statsobject | null
    • progressobject | null
    • executionobject | null
      7 child fields
      • executionIdstring | null
      • statusstring | null
      • modestring | null
      • startedAtstring (date-time) | null
      • completedAtstring (date-time) | null
      • cancelledAtstring (date-time) | null
      • failureReasonstring | null
    • monitoringobject | null
    • isArchivedboolean
    • createdAtstring (date-time) | null
    • updatedAtstring (date-time) | null
  • paginationobject
    8 child fields
    • pageinteger
    • limitinteger
    • totalinteger
    • totalPagesinteger
    • hasNextPageboolean
    • hasPrevPageboolean
    • nextCursorstring | null
    • prevCursorstring | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 422Validation failed (invalid body, empty/segment audience, missing template, no connected channel)
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X GET "https://api.inaiy.com/api/public/v1/broadcasts" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Response 200
{
  "success": true,
  "data": [
    {
      "id": "6650a1b2c3d4e5f6a7b8c9d0",
      "name": "July promo blast",
      "description": "Summer sale announcement",
      "status": "DRAFT",
      "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
      "composition": {
        "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
        "parameters": {
          "body": [
            "Jane"
          ]
        }
      },
      "audience": {
        "type": "MANUAL",
        "selection": {
          "contactIds": [
            "663fa1b2c3d4e5f6a7b8c9d0"
          ],
          "includeTags": [
            "vip"
          ],
          "excludeContactIds": [],
          "excludeTags": []
        },
        "counts": {
          "estimated": 240,
          "resolved": 240,
          "lastEstimatedAt": "2026-07-12T09:00:00.000Z",
          "lastResolvedAt": "2026-07-12T09:00:00.000Z"
        },
        "validation": {
          "isValid": true,
          "issues": [],
          "lastValidatedAt": "2026-07-12T09:00:00.000Z"
        }
      },
      "schedule": null,
      "stats": {
        "total": 240,
        "pending": 240,
        "queued": 0,
        "processing": 0,
        "completed": 0,
        "failed": 0,
        "cancelled": 0,
        "skipped": 0
      },
      "progress": {
        "processed": 0,
        "total": 240,
        "percent": 0
      },
      "execution": null,
      "monitoring": null,
      "isArchived": false,
      "createdAt": "2026-07-12T09:00:00.000Z",
      "updatedAt": "2026-07-12T09:00:00.000Z"
    }
  ],
  "pagination": {
    "page": 1,
    "limit": 25,
    "total": 12,
    "totalPages": 1,
    "hasNextPage": false,
    "hasPrevPage": false,
    "nextCursor": null,
    "prevCursor": null
  },
  "meta": {
    "apiVersion": "v1",
    "sort": {
      "field": "updatedAt",
      "order": "desc"
    }
  },
  "requestId": "a1f4c2e0-9b6d-4a1e-8c3f-2d7e5b9a0c11",
  "timestamp": "2026-07-12T09:00:00.000Z"
}

Create a broadcast

post/api/public/v1/broadcasts

Creates a broadcast (composite). Returns 201 for a draft or 202 Accepted when queued/scheduled.

Request bodyrequired

  • namestringrequired
  • descriptionstring | null
  • templateobject

    Provide either templateId, or name + language.

    5 child fields
    • templateIdstring
    • namestring
    • languagestring
    • variablesobject

      Alias of parameters.

    • parametersobject
  • audienceobject
    5 child fields
    • typestringrequired

      One ofMANUALALLSEGMENT

    • contactIdsstring[]
    • includeTagsstring[]
    • excludeContactIdsstring[]
    • excludeTagsstring[]
  • sendImmediatelyboolean
  • scheduleobject
    1 child field
    • scheduledAtstring
Response 201Draft broadcast created
  • successboolean
  • dataobject
    15 child fields
    • idstring
    • namestring
    • descriptionstring | null
    • statusstring | null

      One ofDRAFTSCHEDULEDRUNNINGPAUSEDCOMPLETEDCANCELLEDFAILEDnull

    • templateIdstring | null
    • compositionobject | null
      2 child fields
      • templateIdstring | null
      • parametersobject | null
    • audienceobject | null
      4 child fields
      • typestring | null

        One ofMANUALALLSEGMENTnull

      • selectionobject | null
        4 child fields
        • contactIdsstring[]
        • includeTagsstring[]
        • excludeContactIdsstring[]
        • excludeTagsstring[]
      • countsobject | null
      • validationobject | null
    • scheduleobject | null
    • statsobject | null
    • progressobject | null
    • executionobject | null
      7 child fields
      • executionIdstring | null
      • statusstring | null
      • modestring | null
      • startedAtstring (date-time) | null
      • completedAtstring (date-time) | null
      • cancelledAtstring (date-time) | null
      • failureReasonstring | null
    • monitoringobject | null
    • isArchivedboolean
    • createdAtstring (date-time) | null
    • updatedAtstring (date-time) | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 409Conflicting state (not editable, cancel not allowed, already running)
  • 422Validation failed (invalid body, empty/segment audience, missing template, no connected channel)
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X POST "https://api.inaiy.com/api/public/v1/broadcasts" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
{
  "name": "July promo blast",
  "description": "Summer sale",
  "template": {
    "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
    "parameters": {
      "body": [
        "Jane"
      ]
    }
  },
  "audience": {
    "type": "ALL"
  }
}
Response 201
{
  "success": true,
  "data": {
    "id": "6650a1b2c3d4e5f6a7b8c9d0",
    "name": "July promo blast",
    "description": "Summer sale announcement",
    "status": "DRAFT",
    "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
    "composition": {
      "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
      "parameters": {
        "body": [
          "Jane"
        ]
      }
    },
    "audience": {
      "type": "MANUAL",
      "selection": {
        "contactIds": [
          "663fa1b2c3d4e5f6a7b8c9d0"
        ],
        "includeTags": [
          "vip"
        ],
        "excludeContactIds": [],
        "excludeTags": []
      },
      "counts": {
        "estimated": 240,
        "resolved": 240,
        "lastEstimatedAt": "2026-07-12T09:00:00.000Z",
        "lastResolvedAt": "2026-07-12T09:00:00.000Z"
      },
      "validation": {
        "isValid": true,
        "issues": [],
        "lastValidatedAt": "2026-07-12T09:00:00.000Z"
      }
    },
    "schedule": null,
    "stats": {
      "total": 240,
      "pending": 240,
      "queued": 0,
      "processing": 0,
      "completed": 0,
      "failed": 0,
      "cancelled": 0,
      "skipped": 0
    },
    "progress": {
      "processed": 0,
      "total": 240,
      "percent": 0
    },
    "execution": null,
    "monitoring": null,
    "isArchived": false,
    "createdAt": "2026-07-12T09:00:00.000Z",
    "updatedAt": "2026-07-12T09:00:00.000Z"
  },
  "meta": {
    "apiVersion": "v1"
  },
  "requestId": "a1f4c2e0-9b6d-4a1e-8c3f-2d7e5b9a0c11",
  "timestamp": "2026-07-12T09:00:00.000Z"
}

Get a broadcast by id

get/api/public/v1/broadcasts/{id}

Fetch a single broadcast by its id.

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Query parameters

  • fieldsstring

    Comma-separated list of fields to return (sparse fieldset).

Response 200The broadcast
  • successboolean
  • dataobject
    15 child fields
    • idstring
    • namestring
    • descriptionstring | null
    • statusstring | null

      One ofDRAFTSCHEDULEDRUNNINGPAUSEDCOMPLETEDCANCELLEDFAILEDnull

    • templateIdstring | null
    • compositionobject | null
      2 child fields
      • templateIdstring | null
      • parametersobject | null
    • audienceobject | null
      4 child fields
      • typestring | null

        One ofMANUALALLSEGMENTnull

      • selectionobject | null
        4 child fields
        • contactIdsstring[]
        • includeTagsstring[]
        • excludeContactIdsstring[]
        • excludeTagsstring[]
      • countsobject | null
      • validationobject | null
    • scheduleobject | null
    • statsobject | null
    • progressobject | null
    • executionobject | null
      7 child fields
      • executionIdstring | null
      • statusstring | null
      • modestring | null
      • startedAtstring (date-time) | null
      • completedAtstring (date-time) | null
      • cancelledAtstring (date-time) | null
      • failureReasonstring | null
    • monitoringobject | null
    • isArchivedboolean
    • createdAtstring (date-time) | null
    • updatedAtstring (date-time) | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X GET "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Response 200
{
  "success": true,
  "data": {
    "id": "6650a1b2c3d4e5f6a7b8c9d0",
    "name": "July promo blast",
    "description": "Summer sale announcement",
    "status": "DRAFT",
    "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
    "composition": {
      "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
      "parameters": {
        "body": [
          "Jane"
        ]
      }
    },
    "audience": {
      "type": "MANUAL",
      "selection": {
        "contactIds": [
          "663fa1b2c3d4e5f6a7b8c9d0"
        ],
        "includeTags": [
          "vip"
        ],
        "excludeContactIds": [],
        "excludeTags": []
      },
      "counts": {
        "estimated": 240,
        "resolved": 240,
        "lastEstimatedAt": "2026-07-12T09:00:00.000Z",
        "lastResolvedAt": "2026-07-12T09:00:00.000Z"
      },
      "validation": {
        "isValid": true,
        "issues": [],
        "lastValidatedAt": "2026-07-12T09:00:00.000Z"
      }
    },
    "schedule": null,
    "stats": {
      "total": 240,
      "pending": 240,
      "queued": 0,
      "processing": 0,
      "completed": 0,
      "failed": 0,
      "cancelled": 0,
      "skipped": 0
    },
    "progress": {
      "processed": 0,
      "total": 240,
      "percent": 0
    },
    "execution": null,
    "monitoring": null,
    "isArchived": false,
    "createdAt": "2026-07-12T09:00:00.000Z",
    "updatedAt": "2026-07-12T09:00:00.000Z"
  },
  "meta": {
    "apiVersion": "v1"
  },
  "requestId": "a1f4c2e0-9b6d-4a1e-8c3f-2d7e5b9a0c11",
  "timestamp": "2026-07-12T09:00:00.000Z"
}

Update a broadcast

patch/api/public/v1/broadcasts/{id}

Update a DRAFT broadcast (name/description/template/audience).

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Request body

  • namestring
  • descriptionstring | null
  • templateobject

    Provide either templateId, or name + language.

    5 child fields
    • templateIdstring
    • namestring
    • languagestring
    • variablesobject

      Alias of parameters.

    • parametersobject
  • audienceobject
    5 child fields
    • typestringrequired

      One ofMANUALALLSEGMENT

    • contactIdsstring[]
    • includeTagsstring[]
    • excludeContactIdsstring[]
    • excludeTagsstring[]
Response 200The updated broadcast
  • successboolean
  • dataobject
    15 child fields
    • idstring
    • namestring
    • descriptionstring | null
    • statusstring | null

      One ofDRAFTSCHEDULEDRUNNINGPAUSEDCOMPLETEDCANCELLEDFAILEDnull

    • templateIdstring | null
    • compositionobject | null
      2 child fields
      • templateIdstring | null
      • parametersobject | null
    • audienceobject | null
      4 child fields
      • typestring | null

        One ofMANUALALLSEGMENTnull

      • selectionobject | null
        4 child fields
        • contactIdsstring[]
        • includeTagsstring[]
        • excludeContactIdsstring[]
        • excludeTagsstring[]
      • countsobject | null
      • validationobject | null
    • scheduleobject | null
    • statsobject | null
    • progressobject | null
    • executionobject | null
      7 child fields
      • executionIdstring | null
      • statusstring | null
      • modestring | null
      • startedAtstring (date-time) | null
      • completedAtstring (date-time) | null
      • cancelledAtstring (date-time) | null
      • failureReasonstring | null
    • monitoringobject | null
    • isArchivedboolean
    • createdAtstring (date-time) | null
    • updatedAtstring (date-time) | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 409Conflicting state (not editable, cancel not allowed, already running)
  • 422Validation failed (invalid body, empty/segment audience, missing template, no connected channel)
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X PATCH "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Request body
{
  "name": "string",
  "description": "string",
  "template": {
    "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
    "name": "order_update",
    "language": "en_US",
    "variables": {},
    "parameters": {}
  },
  "audience": {
    "type": "MANUAL",
    "contactIds": [
      "663fa1b2c3d4e5f6a7b8c9d0"
    ],
    "includeTags": [
      "vip"
    ],
    "excludeContactIds": [
      "string"
    ],
    "excludeTags": [
      "string"
    ]
  }
}
Response 200
{
  "success": true,
  "data": {
    "id": "6650a1b2c3d4e5f6a7b8c9d0",
    "name": "July promo blast",
    "description": "Summer sale announcement",
    "status": "DRAFT",
    "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
    "composition": {
      "templateId": "6650a1b2c3d4e5f6a7b8c9d1",
      "parameters": {
        "body": [
          "Jane"
        ]
      }
    },
    "audience": {
      "type": "MANUAL",
      "selection": {
        "contactIds": [
          "663fa1b2c3d4e5f6a7b8c9d0"
        ],
        "includeTags": [
          "vip"
        ],
        "excludeContactIds": [],
        "excludeTags": []
      },
      "counts": {
        "estimated": 240,
        "resolved": 240,
        "lastEstimatedAt": "2026-07-12T09:00:00.000Z",
        "lastResolvedAt": "2026-07-12T09:00:00.000Z"
      },
      "validation": {
        "isValid": true,
        "issues": [],
        "lastValidatedAt": "2026-07-12T09:00:00.000Z"
      }
    },
    "schedule": null,
    "stats": {
      "total": 240,
      "pending": 240,
      "queued": 0,
      "processing": 0,
      "completed": 0,
      "failed": 0,
      "cancelled": 0,
      "skipped": 0
    },
    "progress": {
      "processed": 0,
      "total": 240,
      "percent": 0
    },
    "execution": null,
    "monitoring": null,
    "isArchived": false,
    "createdAt": "2026-07-12T09:00:00.000Z",
    "updatedAt": "2026-07-12T09:00:00.000Z"
  },
  "meta": {
    "apiVersion": "v1"
  },
  "requestId": "a1f4c2e0-9b6d-4a1e-8c3f-2d7e5b9a0c11",
  "timestamp": "2026-07-12T09:00:00.000Z"
}

Delete a broadcast

delete/api/public/v1/broadcasts/{id}

Soft-delete a DRAFT broadcast. Returns 204 No Content.

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 409Conflicting state (not editable, cancel not allowed, already running)
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X DELETE "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"

Execute a broadcast now

post/api/public/v1/broadcasts/{id}/execute

Queues a DRAFT broadcast for immediate asynchronous execution. Returns 202 Accepted. Execution never bypasses the queue.

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Response 202Broadcast queued for execution
  • successboolean
  • dataobject
    8 child fields
    • broadcastIdstring | null
    • statusstring | null
    • executionobject | null
    • scheduleobject | null
    • progressobject | null
    • statsobject | null
    • estimatedRecipientsinteger
    • timezonestring | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 409Conflicting state (not editable, cancel not allowed, already running)
  • 422Validation failed (invalid body, empty/segment audience, missing template, no connected channel)
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X POST "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0/execute" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Response 202
{
  "success": true,
  "data": {
    "broadcastId": "6650a1b2c3d4e5f6a7b8c9d0",
    "status": "RUNNING",
    "execution": {
      "executionId": "exec_9f8e7d",
      "status": "queued",
      "mode": "immediate",
      "startedAt": "2026-07-12T09:05:00.000Z",
      "completedAt": null,
      "cancelledAt": null,
      "failureReason": null
    },
    "schedule": null,
    "progress": {
      "processed": 0,
      "total": 240,
      "percent": 0
    },
    "stats": {
      "total": 240,
      "pending": 240,
      "queued": 0,
      "processing": 0,
      "completed": 0,
      "failed": 0,
      "cancelled": 0,
      "skipped": 0
    },
    "estimatedRecipients": 240,
    "timezone": "Asia/Kolkata"
  },
  "meta": {
    "apiVersion": "v1",
    "queued": true
  },
  "requestId": "a1f4c2e0-9b6d-4a1e-8c3f-2d7e5b9a0c11",
  "timestamp": "2026-07-12T09:05:00.000Z"
}

Schedule a broadcast

post/api/public/v1/broadcasts/{id}/schedule

Schedules a DRAFT broadcast for future execution. Returns 202 Accepted.

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Request bodyrequired

  • scheduledAtstringrequired

    Local datetime; converted to the org timezone.

Response 202Broadcast scheduled
  • successboolean
  • dataobject
    8 child fields
    • broadcastIdstring | null
    • statusstring | null
    • executionobject | null
    • scheduleobject | null
    • progressobject | null
    • statsobject | null
    • estimatedRecipientsinteger
    • timezonestring | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 409Conflicting state (not editable, cancel not allowed, already running)
  • 422Validation failed (invalid body, empty/segment audience, missing template, no connected channel)
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X POST "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0/schedule" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Request body
{
  "scheduledAt": "2026-07-15T10:00:00"
}
Response 202
{
  "success": true,
  "data": {
    "broadcastId": "6650a1b2c3d4e5f6a7b8c9d0",
    "status": "RUNNING",
    "execution": {
      "executionId": "exec_9f8e7d",
      "status": "queued",
      "mode": "immediate",
      "startedAt": "2026-07-12T09:05:00.000Z",
      "completedAt": null,
      "cancelledAt": null,
      "failureReason": null
    },
    "schedule": null,
    "progress": {
      "processed": 0,
      "total": 240,
      "percent": 0
    },
    "stats": {
      "total": 240,
      "pending": 240,
      "queued": 0,
      "processing": 0,
      "completed": 0,
      "failed": 0,
      "cancelled": 0,
      "skipped": 0
    },
    "estimatedRecipients": 240,
    "timezone": "Asia/Kolkata"
  },
  "meta": {
    "apiVersion": "v1",
    "queued": true
  },
  "requestId": "a1f4c2e0-9b6d-4a1e-8c3f-2d7e5b9a0c11",
  "timestamp": "2026-07-12T09:05:00.000Z"
}

Cancel a broadcast

post/api/public/v1/broadcasts/{id}/cancel

Cancels a SCHEDULED broadcast (reverts to draft) or a RUNNING broadcast. Returns 200.

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Response 200Broadcast cancelled
  • successboolean
  • dataobject
    8 child fields
    • broadcastIdstring | null
    • statusstring | null
    • executionobject | null
    • scheduleobject | null
    • progressobject | null
    • statsobject | null
    • estimatedRecipientsinteger
    • timezonestring | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 409Conflicting state (not editable, cancel not allowed, already running)
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X POST "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0/cancel" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Response 200
{
  "success": true,
  "data": {
    "broadcastId": "6650a1b2c3d4e5f6a7b8c9d0",
    "status": "RUNNING",
    "execution": {
      "executionId": "exec_9f8e7d",
      "status": "queued",
      "mode": "immediate",
      "startedAt": "2026-07-12T09:05:00.000Z",
      "completedAt": null,
      "cancelledAt": null,
      "failureReason": null
    },
    "schedule": null,
    "progress": {
      "processed": 0,
      "total": 240,
      "percent": 0
    },
    "stats": {
      "total": 240,
      "pending": 240,
      "queued": 0,
      "processing": 0,
      "completed": 0,
      "failed": 0,
      "cancelled": 0,
      "skipped": 0
    },
    "estimatedRecipients": 240,
    "timezone": "Asia/Kolkata"
  },
  "meta": {
    "apiVersion": "v1",
    "queued": true
  },
  "requestId": "a1f4c2e0-9b6d-4a1e-8c3f-2d7e5b9a0c11",
  "timestamp": "2026-07-12T09:05:00.000Z"
}

Get broadcast progress

get/api/public/v1/broadcasts/{id}/progress

Returns real-time progress: status, phase, recipient counts (processed/queued/failed/completed), completion percent, and retry counters.

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Query parameters

  • fieldsstring

    Comma-separated list of fields to return (sparse fieldset).

Response 200Broadcast progress snapshot
  • successboolean
  • dataobject
    8 child fields
    • broadcastIdstring | null
    • statusstring | null
    • phasestring | null
    • countsobject
    • completionPercentnumber
    • timingobject | null
    • retryobject | null
    • lastUpdatedAtstring (date-time) | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X GET "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0/progress" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Response 200
{
  "success": true,
  "data": {
    "broadcastId": "string",
    "status": "string",
    "phase": "string",
    "counts": {},
    "completionPercent": 42,
    "timing": {},
    "retry": {},
    "lastUpdatedAt": "2026-07-12T09:30:00.000Z"
  },
  "meta": {
    "apiVersion": "v1"
  },
  "requestId": "string",
  "timestamp": "2026-07-12T09:30:00.000Z"
}

Get broadcast analytics

get/api/public/v1/broadcasts/{id}/analytics

Returns delivery metrics (sent/delivered/read/failed + rates), timing, summary, and optional charts.

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Query parameters

  • executionIdstring
  • includeChartsboolean

    Default true

  • fieldsstring
Response 200Broadcast analytics
  • successboolean
  • dataobject
    6 child fields
    • broadcastobject
    • metricsobject | null
    • timingobject | null
    • summaryobject | null
    • hasDataboolean
    • chartsobject | null
  • metaobject
    1 child field
    • apiVersionstring
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X GET "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0/analytics" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Response 200
{
  "success": true,
  "data": {
    "broadcast": {},
    "metrics": {},
    "timing": {},
    "summary": {},
    "hasData": true,
    "charts": {}
  },
  "meta": {
    "apiVersion": "v1"
  },
  "requestId": "string",
  "timestamp": "2026-07-12T09:30:00.000Z"
}

List broadcast recipients

get/api/public/v1/broadcasts/{id}/recipients

Per-recipient delivery log for the latest execution of a broadcast, with the WhatsApp delivery status and failure reason of each recipient. Returns an empty list for broadcasts that have not run.

Path parameters

  • idstringrequired

    24-char broadcast ObjectId

Query parameters

  • deliveryStatusstring

    queuedsentdeliveredreadfailed

  • statusstring

    pendingqueuedsendingsentfailedcancelled

  • searchstring

    Substring match on contact name or phone.

  • pageinteger
  • limitinteger
  • sortstring

    updatedAtcontactNamephonestatusdeliveryStatussentAtdeliveredAtreadAtretryCount

  • orderstring

    ascdesc

Response 200Broadcast recipients
  • successboolean
  • dataobject[]
    14 child fields
    • idstring
    • contactIdstring | null
    • contactNamestring | null
    • phonestring | null
    • statusstring | null

      Send pipeline state.

    • deliveryStatusstring | null

      WhatsApp delivery outcome.

    • messageIdstring | null

      Message id, usable with GET /messages/{id}.

    • failureReasonstring | null
    • retryCountinteger
    • queuedAtstring (date-time) | null
    • sentAtstring (date-time) | null
    • deliveredAtstring (date-time) | null
    • readAtstring (date-time) | null
    • updatedAtstring (date-time) | null
  • paginationobject
  • metaobject
  • requestIdstring | null
  • timestampstring (date-time)

Errors

  • 400Malformed request or missing tenant context
  • 401Missing or invalid API key
  • 403Forbidden - developer platform disabled, key expired/disabled, or tenant mismatch
  • 404Broadcast or template not found
  • 422Validation failed (invalid body, empty/segment audience, missing template, no connected channel)
  • 429Too many requests - rate limit exceeded
  • 500Unexpected server error
Error envelope and fixes →
curl -X GET "https://api.inaiy.com/api/public/v1/broadcasts/6650a1b2c3d4e5f6a7b8c9d0/recipients" \
  -H "x-tenant-id: demo" \
  -H "x-api-key: wp_live_xxxxxxxxxxxxxxxxxxxx"
Response 200
{
  "success": true,
  "data": [
    {
      "id": "6650a1b2c3d4e5f6a7b8c9e1",
      "contactId": "6650a1b2c3d4e5f6a7b8c9f2",
      "contactName": "Asha",
      "phone": "+919800000000",
      "status": "sent",
      "deliveryStatus": "read",
      "messageId": "string",
      "failureReason": null,
      "retryCount": 0,
      "queuedAt": "2026-07-12T09:30:00.000Z",
      "sentAt": "2026-07-12T09:30:00.000Z",
      "deliveredAt": "2026-07-12T09:30:00.000Z",
      "readAt": "2026-07-12T09:30:00.000Z",
      "updatedAt": "2026-07-12T09:30:00.000Z"
    }
  ],
  "pagination": {},
  "meta": {},
  "requestId": "string",
  "timestamp": "2026-07-12T09:30:00.000Z"
}