---
title: "Preview a transmission"
method: POST
path: "/api/v1/transmissions/preview"
tags: ["transmissions"]
---

# Preview a transmission

`POST /api/v1/transmissions/preview`

## Request

- Base URL: `https://api.izap.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.izap.ai/api/v1/transmissions/preview`
- Auth: HTTP bearer

Validates the recipient list and template and stores the result as a draft, without sending anything. Review the draft, then confirm it to dispatch.

## Headers

- `business-id` string, uuid, required

## Request body

- CreateTransmissionPreviewIn: Validate CSV recipients against a template and create a DRAFT transmission. No messages are sent. ``recipients`` are parsed CSV rows (header -> value); each row must contain ``phone_column`` and the columns that fill the template's variables. Confirm the returned draft id with ``confirm_transmission`` to send.
  - `name` string, required: Human label for the transmission.
  - `transmission_type` 'whatsapp_template' | 'whatsapp_freeform': The kind of bulk message a transmission sends. ``WHATSAPP_TEMPLATE`` sends an approved template to a phone list. ``WHATSAPP_FREEFORM`` sends a fixed text and only reaches contacts inside Meta's 24h customer-service window. Modelled as an enum so further channels can be added without a schema change to the stored value.
  - `max_messages_per_minute` integer: Sending pace cap. Must be between 1 and 200 messages per minute.
  - `template_name` string: Name of the pre-approved WhatsApp Cloud API template to send. Required for 'whatsapp_template'; not accepted for 'whatsapp_freeform', which stores a fixed default.
  - `template_language` string: Template language/locale code as registered with Meta, e.g. 'pt_BR'.
  - `recipients` object[], required: Parsed CSV rows; each row maps a string column header to its string cell value. Must include the phone column and the columns that supply the template's variables.
  - `phone_column` string: Name of the CSV column holding the recipient phone number (E.164 or local).
  - `variable_columns` string[], nullable: For positional templates ({{1}}, {{2}}, ...): the ordered CSV header names mapping to {{1}}, {{2}}, ... If omitted, the first non-phone columns are used in order. Ignored for templates with named placeholders.
  - `message_text` string, nullable: Text to send. Required for 'whatsapp_freeform', which only reaches contacts inside the WhatsApp customer-service window; others are skipped.
  - `scheduled_at` string, date-time, nullable: When to send. Omit or null to send immediately on confirm. If the value has no timezone offset it is interpreted in 'timezone'.
  - `timezone` string, nullable: IANA timezone used to interpret a naive 'scheduled_at'. Defaults to the business's configured timezone (America/Sao_Paulo when none is set).
  - `business_id` string, uuid, nullable

## Response `200`

Successful Response

- TransmissionPreviewOut
  - `transmission_id` string, uuid, required
  - `name` string, required
  - `status` string, required
  - `transmission_type` string, required
  - `template_name` string, nullable, required
  - `template_language` string, required
  - `uses_named_variables` boolean, required
  - `recipient_count` integer, required
  - `valid_count` integer, required
  - `invalid_count` integer, required
  - `duplicate_count` integer, required
  - `not_on_whatsapp_count` integer
  - `outside_window_count` integer
  - `column_mapping` object, required
  - `phone_column` string, required
  - `sample_errors` PreviewRowErrorOut[], required
    - `row_index` integer, required
    - `phone` string, nullable, required
    - `error` string, required
  - `estimated_duration_seconds` integer, required
  - `scheduled_at` string, date-time, nullable, required
  - `warnings` string[], required
  - `business_id` string, uuid, required

## Other responses

- `401`: Missing or invalid credentials.
- `403`: The credential is valid but not authorized for this action.
- `404`: The resource, or the business named in the request, does not exist.
- `422`: Validation Error
- `default`: Unexpected error.

---

[API](https://skmtc.dev/izap/apis/izap-api.md) · [All operations](https://skmtc.dev/izap/apis/izap-api/llms.txt) · [OpenAPI document](https://skmtc.dev/izap/apis/izap-api/revisions/e6358c8bf5e9?raw)
