> ## Documentation Index
> Fetch the complete documentation index at: https://developer.omni.z-api.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Changelog

> Cambios en la API y en los webhooks de Omni Z-API que afectan su integración

Esta página registra los cambios de Omni Z-API que alteran lo que recibe su integración. Cada entrada trae la fecha en que el cambio entró en producción, qué cambia, el antes y el después, y qué necesita hacer.

> [!NOTE]
>
> Trate su integración por `status`, `error`, `code` y `subCode`. El texto de `message` es para lectura humana y puede cambiar sin aviso.

**18/11/2026**

Errores de autenticación y plan, webhooks Z\_API y rutas /send-\*

Los tres cambios de abajo entraron en producción el 18/11/2026.

## Errores más claros en la autenticación, el plan, el código QR y el canal desconectado

Los errores de abajo pasan a traer `message`, con qué pasó, por qué y qué hacer. Tres de ellos cambian de status. Donde ya había un texto, sigue como **inicio** de `message`.

> [!NOTE]
>
> Los cambios de status de abajo — `400`→`401`, `400`→`403 ip_not_allowed` y `422`→`403 plan_required` — son de la **API Omni** (`https://api.omni.z-api.io/v1/...`). En la [ruta compatible Z-API](https://developer.omni.z-api.io/es/z-api/introduction.md) (`https://zapi.omni.z-api.io`) la autenticación y la lista de IPs **no cambiaron**: una credencial rechazada sigue en `400`/`422` `{"error": "Authorization invalid"}` y una IP fuera de la lista sigue en `400` `{"error": "<ip> not allowed"}`.

| Situación | Antes | Después |
| - | - | - |
| Secret key ausente, vacía, fuera de formato, Public Key en su lugar o inexistente | `400` `{"error": "Authorization invalid"}` | **`401`**, header `WWW-Authenticate: Bearer`, `{"error": "Authorization invalid", "message": "..."}` |
| IP fuera de la [lista de IPs](https://developer.omni.z-api.io/es/security/ip-restriction.md) del workspace | `400` `{"error": "<ip> not allowed"}` | **`403`** `{"error": "ip_not_allowed", "message": "<ip> not allowed: ..."}` |
| Operación de canal con la secret key, sin el rol `ENTERPRISE` | `422` `{"error": "Channel listing requires ENTERPRISE role"}` (y variantes) | **`403`** `{"error": "plan_required", "message": "Channel listing requires ENTERPRISE role: ..."}` |
| Workspace bloqueado | `422` `{"error": "You are blocked, contact support."}` | `422`, mismo `error`, con `message` |
| Código QR de WhatsApp Web rechazado (`NEED_SIGN_ZAPI`) | `422` con el sobre en `error` | `422`, mismo `error`, con `message` en la raíz |
| Canal desconectado en el envío y en la edición (`CHANNEL_DISCONNECTED`) | `422`, `message` `"Channel is disconnected"` | `422`, mismos `code` y `subCode`, `message` nuevo |

### Secret key rechazada: 400 pasa a 401

Vale para las rutas de la **API Omni** (`/v1/...`) que aceptan la secret key. El `message` depende del motivo:

| Motivo | `message` |
| - | - |
| Header ausente o vacío | `Authorization invalid: the Authorization header is missing or empty. Send the workspace Secret Key as "Authorization: Bearer <secret-key>". See https://developer.omni.z-api.io/en/authentication` |
| Public Key (empieza con `pk_`) | `Authorization invalid: this is the Public Key, which only works in the channel connection SDK. Send the workspace Secret Key as "Authorization: Bearer <secret-key>". See https://developer.omni.z-api.io/en/authentication` |
| Fuera de formato (por ejemplo, el token del canal) | `Authorization invalid: the value sent is not a Secret Key. Send the workspace Secret Key, generated under Security in the panel, as "Authorization: Bearer <secret-key>". The channel token is not accepted here. See https://developer.omni.z-api.io/en/authentication` |
| Inexistente o revocada | `Authorization invalid: this Secret Key does not exist or is no longer valid. Copy the current Secret Key under Security in the panel and send it as "Authorization: Bearer <secret-key>". See https://developer.omni.z-api.io/en/authentication` |

El `<secret-key>` es literal: la respuesta nunca repite el valor que usted envió.

Antes:

```http theme={null}
HTTP/1.1 400 Bad Request

{"error": "Authorization invalid"}
```

Después:

```http theme={null}
HTTP/1.1 401 Unauthorized
WWW-Authenticate: Bearer

{
  "error": "Authorization invalid",
  "message": "Authorization invalid: this Secret Key does not exist or is no longer valid. Copy the current Secret Key under Security in the panel and send it as \"Authorization: Bearer <secret-key>\". See https://developer.omni.z-api.io/en/authentication"
}
```

### IP fuera de la lista: 400 pasa a 403

Antes:

```http theme={null}
HTTP/1.1 400 Bad Request

{"error": "203.0.113.10 not allowed"}
```

Después:

```http theme={null}
HTTP/1.1 403 Forbidden

{
  "error": "ip_not_allowed",
  "message": "203.0.113.10 not allowed: this workspace only accepts API calls from the IPs on its allow list. The workspace Owner can add this IP under Administration > Security > IP Restriction in the panel (changes take up to 10 minutes to apply), or call from an allowed IP. See https://developer.omni.z-api.io/en/security/ip-restriction"
}
```

Cuando no se puede identificar el IP de origen, el `message` empieza con `ip not allowed: `.

### Sin el rol ENTERPRISE: 422 pasa a 403 plan\_required

Vale para las seis operaciones de canal con la secret key: listar, leer, crear, eliminar, suscribir y cancelar la suscripción. Cada una mantiene su texto actual como inicio de `message`: `Channel listing requires ENTERPRISE role` (listar y leer), `Channel creation requires ENTERPRISE role`, `Channel deletion requires ENTERPRISE role` y `Channel subscription requires ENTERPRISE role` (suscribir y cancelar).

Antes:

```http theme={null}
HTTP/1.1 422 Unprocessable Entity

{"error": "Channel listing requires ENTERPRISE role"}
```

Después:

```http theme={null}
HTTP/1.1 403 Forbidden

{
  "error": "plan_required",
  "message": "Channel listing requires ENTERPRISE role: listing and reading channels with the Secret Key is limited to partner accounts with the ENTERPRISE role. Ask support to enable the role, or see your channels in the panel at https://app.omni.z-api.io. See https://developer.omni.z-api.io/en/channels/introduction"
}
```

### Workspace bloqueado: mismo status, con message

Vale para el envío, la edición de mensajes y las rutas de grupo, con la secret key o con token OAuth.

Antes:

```http theme={null}
HTTP/1.1 422 Unprocessable Entity

{"error": "You are blocked, contact support."}
```

Después:

```http theme={null}
HTTP/1.1 422 Unprocessable Entity

{
  "error": "You are blocked, contact support.",
  "message": "You are blocked, contact support. This workspace is blocked on the platform, so sending, editing and group calls are refused until it is unblocked. Talk to support through the panel at https://app.omni.z-api.io."
}
```

### Código QR rechazado: mismo status y mismo error, con message

Vale para `GET /v1/channels/{id}/zapi/qr-code` y `GET /v1/channels/{id}/zapi/qr-code/image`, cuando el rechazo viene con `NEED_SIGN_ZAPI`. El objeto `error` no cambia, campo por campo. Los demás rechazos del código QR siguen como hoy.

Antes:

```http theme={null}
HTTP/1.1 422 Unprocessable Entity

{
  "error": {
    "timestamp": "2026-11-17T10:00:00Z",
    "status": 424,
    "errors": [
      {
        "code": "307",
        "name": "NEED_SIGN_ZAPI",
        "message": "Z-API signature required",
        "description": "The Z-API account must be signed before proceeding"
      }
    ]
  }
}
```

Después:

```http theme={null}
HTTP/1.1 422 Unprocessable Entity

{
  "error": {
    "timestamp": "2026-11-17T10:00:00Z",
    "status": 424,
    "errors": [
      {
        "code": "307",
        "name": "NEED_SIGN_ZAPI",
        "message": "Z-API signature required",
        "description": "The Z-API account must be signed before proceeding"
      }
    ]
  },
  "message": "Z-API signature required: Z-API refused to generate the QR code for this WhatsApp Web channel. The usual cause is a channel without an active subscription: activate it in the panel at https://app.omni.z-api.io (ENTERPRISE accounts can also call GET /v1/channels/{channelId}/subscribe after the checkout) and request the QR code again. If the subscription is already active, try again in a few minutes and contact support if it keeps failing. See https://developer.omni.z-api.io/en/connect/whatsapp-web"
}
```

### Canal desconectado: solo cambia el message

Vale para `POST /v1/channels/{id}/messages`, para las rutas `/send-*` y para `PUT /v1/channels/{id}/messages/{messageId}`. Status, `timestamp`, `code` y `subCode` no cambian.

Antes:

```json theme={null}
{
  "timestamp": "2026-11-17T10:00:00Z",
  "code": "BUSINESS_RULE_VIOLATION",
  "subCode": "CHANNEL_DISCONNECTED",
  "message": "Channel is disconnected"
}
```

Después, en el envío:

```json theme={null}
{
  "timestamp": "2026-11-17T10:00:00Z",
  "code": "BUSINESS_RULE_VIOLATION",
  "subCode": "CHANNEL_DISCONNECTED",
  "message": "Channel is disconnected: the message was not sent because the channel is not connected right now. Reconnect the channel (WhatsApp Web by reading a new QR code; WhatsApp Official, Instagram and Messenger through the Meta connection; Telegram with the bot token) and send again. See https://developer.omni.z-api.io/en/connect/introduction"
}
```

En la edición (`PUT .../messages/{messageId}`), el texto dice `the message was not edited` y termina con `and edit again`. Una edición hecha por `POST .../messages` con `editMessageId` recibe el texto del envío.

### Qué hacer

* Si su integración trata la credencial rechazada por `status == 400`, pase a tratar `401`.
* Si trata el IP fuera de la lista por `400`, pase a tratar `403` con `error` `ip_not_allowed`.
* Si trata la falta del rol `ENTERPRISE` por `422`, pase a tratar `403` con `error` `plan_required`. El texto antiguo salió de `error` y está al inicio de `message`.
* Si compara el `error` del IP o del rol con el texto exacto, pase a compararlo con `ip_not_allowed` y `plan_required`.
* Workspace bloqueado, código QR rechazado y canal desconectado no requieren cambios: status, `error`, `code` y `subCode` siguen iguales.
* En la [ruta compatible Z-API](https://developer.omni.z-api.io/es/z-api/introduction.md) nada cambia aquí: una credencial rechazada sigue en `400`/`422` y una IP fuera de la lista sigue en `400`.

El camino del token OAuth no cambia: `invalid_token`, `insufficient_scope` e `ip_not_allowed` siguen como hoy, y la lectura de canales con el token sigue sin exigir el rol `ENTERPRISE`. La Public Key usada en el SDK de conexión tampoco cambia.

## Webhooks en el formato Z\_API: notificación en la raíz del callback

En los eventos de notificación (grupo, llamada, perfil, canal y mensajes de sistema), el webhook con `payloadFormat` `Z_API` pasa a entregar `notification` como texto y `notificationParameters` como lista, ambos en la raíz del `ReceivedCallback`, como en Z-API. Hoy los dos llegan dentro de un objeto `notification`.

Antes:

```json theme={null}
{
  "type": "ReceivedCallback",
  "phone": "5511999999999",
  "notification": {
    "notification": "GROUP_PARTICIPANT_ADD",
    "notificationParameters": ["5511988888888"],
    "type": "notification"
  }
}
```

Después:

```json theme={null}
{
  "type": "ReceivedCallback",
  "phone": "5511999999999",
  "notification": "GROUP_PARTICIPANT_ADD",
  "notificationParameters": ["5511988888888"]
}
```

* `notificationParameters` solo se envía cuando el evento tiene parámetros. Puede venir vacío (`[]`).
* Fijar mensaje sigue en `pinMessage`, sin cambios.
* Los formatos `DEFAULT` y `CHATWOOT` no cambian.
* En canales de la API oficial (Meta), el valor de `notification` sigue siendo el que envía Meta (por ejemplo, `revoke`). Solo cambia la posición de los campos.

### Qué hacer

Si su integración lee `notification.notification` o `notification.notificationParameters`, pase a leer `notification` y `notificationParameters` en la raíz. Si ya sigue la documentación de Z-API, no necesita cambiar nada. Vea [Introducción a los webhooks](https://developer.omni.z-api.io/es/webhooks/introduction.md).

## Las rutas /send-\* pasan a aceptar el payload de Omni

Las rutas `POST /v1/channels/{id}/send-*` pasan a aceptar el **mismo cuerpo** de `POST /v1/channels/{id}/messages`, `{"recipient": {...}, "content": {...}}`, y a responder como él: `200` con `{"messageId": "..."}`. El tipo de mensaje viene de la ruta, así que `content.type` es opcional.

Antes, estas rutas reenviaban el cuerpo sin interpretarlo, y el envío no ocurría: la respuesta era `502`, `400` o `415`, según el cuerpo.

Antes:

```http theme={null}
POST /v1/channels/{id}/send-text

{"phone": "5511999999999", "message": "hola"}
```

```http theme={null}
HTTP/1.1 502 Bad Gateway
```

Después:

```http theme={null}
POST /v1/channels/{id}/send-text

{
  "recipient": {"identifier": "5511999999999"},
  "content": {"body": {"message": "hola"}}
}
```

```http theme={null}
HTTP/1.1 200 OK

{"messageId": "..."}
```

### Ruta y tipo

| Ruta | `content.type` |
| - | - |
| `send-text` | `TEXT` |
| `send-image` | `IMAGE` |
| `send-video` | `VIDEO` |
| `send-audio` | `AUDIO` |
| `send-ptv` | `PTV` |
| `send-gif` | `GIF` |
| `send-sticker` | `STICKER` |
| `send-document` y `send-document/{extension}` | `DOCUMENT` |
| `send-link` | `LINK` |
| `send-location` | `LOCATION` |
| `send-contact` | `CONTACT` |
| `send-contacts` | `CONTACT_ARRAY` |
| `send-reaction` | `REACTION` |
| `send-template` | `TEMPLATE` |
| `send-option-list` | `INTERACTIVE_LIST` |
| `send-button-list` | `INTERACTIVE_BUTTON` |
| `send-button-actions` | `INTERACTIVE_ACTION` |
| `send-button-otp` | `INTERACTIVE_OTP` |
| `send-carousel` | `INTERACTIVE_CAROUSEL` |

En `send-document/{extension}`, el segmento de la ruta se ignora: la extensión va en cada adjunto, como en `/messages`. `send-template` sigue aceptando solo canales de WhatsApp oficial (Meta). Si el canal no soporta el tipo, el rechazo es el mismo de `/messages`.

### Errores

| Situación | Respuesta |
| - | - |
| `content` ausente o que no es objeto JSON (por ejemplo, el cuerpo en el formato de Z-API) | `400` `{"error": "invalid_request", "field": "content", "message": "content must be a JSON object; /send-text takes the same body as POST /v1/channels/{id}/messages"}` |
| `content.type` distinto del tipo de la ruta | `400` `{"error": "invalid_request", "field": "content.type", "message": "content.type must be TEXT on /send-text; leave it out, or send other types with POST /v1/channels/{id}/messages"}` |
| Ruta sin tipo equivalente en Omni | `422` `{"error": "send_route_not_supported", "message": "/send-poll has no Omni content type; send it with POST /v1/channels/{id}/messages"}` |
| `/send-*` fuera de `/v1/channels/{id}` | `404` `{"error": "Resource not found"}` |

Los ejemplos usan `send-text`, `TEXT` y `send-poll`. En cada ruta, el texto trae su nombre y su tipo.

Las rutas sin tipo equivalente responden `422` con cualquier credencial o sin ninguna, y no cuentan en el límite de envío de la app: `send-link-list`, `send-option-multi-list`, `send-button-pix`, `send-remove-reaction`, `send-poll`, `send-poll-vote`, `send-call`, `send-chat-expiration`, `send-text-status`, `send-image-status`, `send-video-status`, `send-order`, `send-request-payment`, `send-event`, `send-edit-event`, `send-event-response`, `send-comment`, `send-catalog`, `send-product` y `send-newsletter-admin-invite`.

Las rutas `/send-*` pasan a existir **solo** en `/v1/channels/{id}`. Las variantes `/channels/{id}/send-*`, `/v1/instances/{id}/send-*`, `/instances/{id}/send-*`, `/v1/devices/{id}/send-*` y `/devices/{id}/send-*` pasan a responder `404`. `POST .../messages` y `PUT .../messages/{messageId}` siguen en todas las variantes.

Con token OAuth, las rutas tipadas exigen el mismo alcance `messages:send` de `/messages` y cuentan en el mismo límite diario de envío de la app.

### Qué hacer

* Para enviar por una ruta `/send-*`, use el cuerpo de `POST /v1/channels/{id}/messages`, en la ruta `/v1/channels/{id}/send-*`. Vea [Mensajes](https://developer.omni.z-api.io/es/messages/introduction.md).
* El cuerpo sigue siendo JSON. El envío de archivos por `multipart/form-data` no se acepta: envíe el medio por URL o Base64 dentro del JSON.
* Si su integración usa el cuerpo de Z-API (`phone`, `message`), use la [compatibilidad con Z-API](https://developer.omni.z-api.io/es/z-api/introduction.md), en `https://zapi.omni.z-api.io`, que acepta ese formato.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.