---
title: "Create Broadcast Message"
method: POST
path: "/api/v1/msg/broadcast"
tags: ["Broadcast"]
---

# Create Broadcast Message

`POST /api/v1/msg/broadcast`

Creates a background task to send the same message to each application in your organization.

A completed task will return a payload like the following:
```json
{
  "id": "qtask_33qen93MNuelBAq1T9G7eHLJRsF",
  "status": "finished",
  "task": "message.broadcast",
  "data": {
    "messagesCreated": [
      {
        "appId": "app_33s1An2Zz5cO9SWbhHsYyDmVC6m",
        "msgId": "msg_33s1An2Zz5cO9SWbhHsYyDmVC6m"
      },
      {
        "appId": "app_33sXYjcO6bkWeZIXDI8w6ZYMivz",
        "msgId": "msg_33sZJfmYMOQGApyIgRdteOX0xlX"
      }
    ]
  }
}
```

## Headers

- `idempotency-key` string

## Request body

- MessageBroadcastIn
  - `eventId` string, nullable — Optional unique identifier for the message.
  - `eventType` string, required — The event type's name
  - `payload` object, required
  - `channels` string[], nullable — List of free-form identifiers that endpoints can filter by.
  - `payloadRetentionPeriod` integer, nullable — Optional number of days to retain the message payload. Defaults to 90. Note that this is mutually exclusive with `payloadRetentionHours`.
  - `payloadRetentionHours` integer, nullable — Optional number of hours to retain the message payload. Note that this is mutually exclusive with `payloadRetentionPeriod`.

## Response `202`

- MessageBroadcastOut
  - `id` string, required — The QueueBackgroundTask's ID.
  - `status` 'running' | 'finished' | 'failed', required
  - `task` 'endpoint.replay' | 'endpoint.recover' | 'application.stats' | 'message.broadcast' | 'sdk.generate' | 'event-type.aggregate' | 'application.purge_content' | 'endpoint.bulk-replay', required
  - `updatedAt` string, date-time, required

## Other responses

- `400` — Bad request
- `401` — Unauthorized
- `403` — Forbidden
- `404` — Not Found
- `409` — Conflict
- `422` — Validation Error
- `429` — Too Many Requests

---

[API](https://skmtc.net/svix/apis/svix-api.md) · [All operations](https://skmtc.net/svix/apis/svix-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/svix/svix-api/revisions/16dbcc056c48/schema)
