> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ycloud.com/llms.txt
> Use this file to discover all available pages before exploring further.

# whatsapp.template.reviewed

> Occurs when a WhatsApp template receives a review or lifecycle update, including approval, rejection, pausing, disabling, archiving, and unarchiving.

Use `whatsapp.template.reviewed` to handle this event at your webhook endpoint.

## Triggers

Occurs when a WhatsApp template receives a review or lifecycle update, including approval, rejection, pausing, disabling, archiving, and unarchiving.

Subscribe to `whatsapp.template.reviewed` when you [configure your webhook endpoint](https://docs.ycloud.com/en/api-reference/guides/api-fundamentals/configure-webhooks.md).

Use `wabaId`, `name`, and `language` to identify the template. `statusUpdateEvent` describes the triggering change; `status` describes the current state. For example, `UNARCHIVED` can carry `status: APPROVED` without a new approval review.

## Syntax

YCloud sends an HTTP `POST` request to your configured webhook URL. The following shape shows one payload variant. Angle-bracket values are placeholders; their types are listed under **Parameters**. Optional fields and other variants are described below.

```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
{
  "id": "<ID>",
  "type": "whatsapp.template.reviewed",
  "apiVersion": "<API_VERSION>",
  "createTime": "<CREATE_TIME>",
  "whatsappTemplate": {
    "officialTemplateId": "<OFFICIAL_TEMPLATE_ID>",
    "wabaId": "<WABA_ID>",
    "name": "<NAME>",
    "language": "<LANGUAGE>",
    "category": "<CATEGORY>",
    "status": "<STATUS>",
    "statusUpdateEvent": "<STATUS_UPDATE_EVENT>",
    "createTime": "<CREATE_TIME>",
    "updateTime": "<UPDATE_TIME>"
  }
}
```

## Parameters

Validate the `YCloud-Signature` HTTP header before you process the JSON body. See [signature validation](https://docs.ycloud.com/en/api-reference/guides/api-fundamentals/configure-webhooks.md).

### Event envelope

| Parameter | Type | Required | Description |
| - | - | - | - |
| `id` | string | Yes | Unique ID for the event. Minimum length: `6`. Maximum length: `128`. |
| `type` | string | Yes | Always `whatsapp.template.reviewed`. |
| `apiVersion` | string | Yes | The API version used to render this event. |
| `createTime` | string (date-time) | Yes | The time at which this event was created, formatted in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339). e.g., `2022-06-01T12:00:00.000Z`. |

### Event payload

| Parameter | Type | Required | Description |
| - | - | - | - |
| `whatsappTemplate` | object | No | Event-specific `whatsappTemplate` payload. |

The four common envelope fields are required. Payload fields depend on the event variant. In each object table, **Required** applies when its parent object is present. Optional fields can be omitted; a sample does not make a field required.

#### whatsappTemplate

| Parameter | Type | Required | Description |
| - | - | - | - |
| `officialTemplateId` | string | No | Official template ID assigned by WhatsApp. This ID is used to identify the template in WhatsApp's system. |
| `wabaId` | string | Yes | WhatsApp Business Account ID. |
| `name` | string | Yes | Name of the template.Maximum length: `512`. Pattern: `[a-z0-9]{1,512}`. |
| `language` | string | Yes | Language code of the template. See [Supported Languages](https://developers.facebook.com/documentation/business-messaging/whatsapp/templates/supported-languages) for all codes. |
| `category` | string | No | Category of WhatsApp templates.<ul><li>`AUTHENTICATION`: Enable businesses to authenticate users with one-time passcodes, potentially at multiple steps in the login process (e.g., account verification, account recovery, integrity challenges).</li><li>`MARKETING`: Include promotions or offers, informational updates, or invitations for customers to respond / take action. Any conversation that does not qualify as utility or authentication is a marketing conversation.</li><li>`UTILITY`: Facilitate a specific, agreed-upon request or transaction or update to a customer about an ongoing transaction, including post-purchase notifications and recurring billing statements.</li></ul> |
| `status` | string | No | The status of a WhatsApp template.<ul><li>`PENDING`: The template is still under review. Review can take up to 24 hours.</li><li>`REJECTED`: The template has been rejected during review process.</li><li>`APPROVED`: The template is approved, and you may begin sending it to customers.</li><li>`PAUSED`: The template has been paused due to recurring negative feedback from customers. Message templates with this status cannot be sent to customers. See [Template Pausing](https://developers.facebook.com/docs/whatsapp/message-templates/guidelines#template-pausing).</li><li>`DISABLED`: The template has been disabled due to recurring negative feedback from customers or for violating one or more of our policies. Message templates with this status cannot be sent to customers. You may be able to edit a disabled message template and request an appeal. See [Appeals](https://developers.facebook.com/docs/whatsapp/message-templates/guidelines#appeals).</li><li>`ARCHIVED`: The template has been archived. Archived templates cannot be sent or edited.</li><li>`IN_APPEAL`: The template is in appeal. See also [Template Appeals](https://developers.facebook.com/docs/whatsapp/message-templates/guidelines#appeals).</li><li>`DELETED`: The template is deleted.</li></ul> |
| `reason` | string | No | The reason why the template is rejected. |
| `createTime` | string (date-time) | No | The time at which this object is created, formatted in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339). e.g., `2022-06-01T12:00:00.000Z`. |
| `updateTime` | string (date-time) | No | The time at which this object is updated, formatted in [RFC 3339](https://datatracker.ietf.org/doc/html/rfc3339). e.g., `2022-06-01T12:00:00.000Z`. |
| `statusUpdateEvent` | string | No | The WhatsApp template status update event that caused this webhook. For `ARCHIVED`, the template `status` is `ARCHIVED`. For `UNARCHIVED`, the template `status` is the current status returned by Meta, for example `APPROVED`; it does not represent a new approval review\.Values: `PENDING`, `APPROVED`, `REJECTED`, `IN_APPEAL`, `PAUSED`, `FLAGGED`, `DISABLED`, `ARCHIVED`, `UNARCHIVED`, `REINSTATED`, `PENDING_DELETION`. |
| `disableDate` | string | No | The date at which the template will be disabled. When a WhatsApp template `FLAGGED` event is received, this field is set. |
| `whatsappApiError` | object | No | The original error object returned by WhatsApp. See [Handling Errors](https://developers.facebook.com/docs/graph-api/guides/error-handling), [Cloud API Error Codes](https://developers.facebook.com/docs/whatsapp/cloud-api/support/error-codes). |

> [accordion] whatsappTemplate.whatsappApiError
>
> | Parameter | Type | Required | Description |
> | - | - | - | - |
> | `message` | string | Yes | A human-readable description of the error. |
> | `code` | string | Yes | An error code. |
> | `type` | string | No | Error type. |
> | `error_subcode` | string | No | Additional code about the error. |
> | `error_user_msg` | string | No | The message to display to the user. The language of the message is based on the locale of the API request. |
> | `error_user_title` | string | No | The title of the dialog, if shown. The language of the message is based on the locale of the API request. |
> | `fbtrace_id` | string | No | Internal support identifier. When reporting a bug related to a Graph API call, include the fbtrace\_id to help us find log data for debugging. |
> | `error_data` | string or object | No | Additional data about the error. A string or map.<ul><li>For template APIs, this field is a string describing the reason for the error.</li><li>For message APIs, this field is a map with property `details` describing the reason for the error.</li></ul> |

## Example

The following JSON is the body delivered to your receiver. IDs, phone numbers, and other account values are illustrative.

> [accordion] WhatsApp template archived event
>
> Example payload when a WhatsApp template is archived
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_template_archived_123",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2024-01-01T12:00:00.000Z",
>   "whatsappTemplate": {
>     "officialTemplateId": "official-template-id",
>     "wabaId": "whatsapp-business-account-id",
>     "name": "sample_whatsapp_template",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "ARCHIVED",
>     "statusUpdateEvent": "ARCHIVED",
>     "createTime": "2024-01-01T12:00:00.000Z",
>     "updateTime": "2024-01-01T12:00:00.000Z"
>   }
> }
> ```

> [accordion] WhatsApp template unarchived event
>
> Example payload when a WhatsApp template is unarchived. The template status is the current status returned by Meta and does not represent a new approval review.
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_template_unarchived_123",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2024-01-01T12:00:00.000Z",
>   "whatsappTemplate": {
>     "officialTemplateId": "official-template-id",
>     "wabaId": "whatsapp-business-account-id",
>     "name": "sample_whatsapp_template",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "APPROVED",
>     "statusUpdateEvent": "UNARCHIVED",
>     "createTime": "2024-01-01T12:00:00.000Z",
>     "updateTime": "2024-01-01T12:00:00.000Z"
>   }
> }
> ```

> [accordion] Template Approved
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_eEMtA0PkkyACiS5o",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2023-02-20T12:00:00.000Z",
>   "whatsappTemplate": {
>     "wabaId": "WABA-ID",
>     "name": "template_name",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "APPROVED",
>     "reason": "NONE",
>     "statusUpdateEvent": "APPROVED"
>   }
> }
> ```

> [accordion] Template Rejected
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_eEMtA0PkkyACiS5o",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2023-02-20T12:00:00.000Z",
>   "whatsappTemplate": {
>     "wabaId": "WABA-ID",
>     "name": "template_name",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "REJECTED",
>     "reason": "SCAM",
>     "statusUpdateEvent": "REJECTED"
>   }
> }
> ```

> [accordion] Template Paused
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_eEMtA0PkkyACiS5o",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2023-02-20T12:00:00.000Z",
>   "whatsappTemplate": {
>     "wabaId": "WABA-ID",
>     "name": "template_name",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "PAUSED",
>     "reason": "NONE",
>     "statusUpdateEvent": "PAUSED"
>   }
> }
> ```

> [accordion] Template Flagged
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_eEMtA0PkkyACiS5o",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2023-02-20T12:00:00.000Z",
>   "whatsappTemplate": {
>     "wabaId": "WABA-ID",
>     "name": "template_name",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "APPROVED",
>     "reason": "Your WhatsApp message template has been paused for 3 hours until Feb 23 at 5:28 AM UTC because it had issues.",
>     "statusUpdateEvent": "FLAGGED",
>     "disableDate": "February 28, 2023"
>   }
> }
> ```

> [accordion] Template Disabled
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_eEMtA0PkkyACiS5o",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2023-02-20T12:00:00.000Z",
>   "whatsappTemplate": {
>     "wabaId": "WABA-ID",
>     "name": "template_name",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "DISABLED",
>     "reason": "NONE",
>     "statusUpdateEvent": "DISABLED"
>   }
> }
> ```

> [accordion] Template Pending Deletion
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_eEMtA0PkkyACiS5o",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2023-02-20T12:00:00.000Z",
>   "whatsappTemplate": {
>     "wabaId": "WABA-ID",
>     "name": "template_name",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "DELETED",
>     "reason": "NONE",
>     "statusUpdateEvent": "PENDING_DELETION"
>   }
> }
> ```

> [accordion] Template Archived
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_eEMtA0PkkyACiS5o",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2024-01-01T12:00:00.000Z",
>   "whatsappTemplate": {
>     "wabaId": "WABA-ID",
>     "name": "template_name",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "ARCHIVED",
>     "reason": "NONE",
>     "statusUpdateEvent": "ARCHIVED"
>   }
> }
> ```

> [accordion] Template Unarchived
>
> ```json theme={"theme":{"light":"github-light","dark":"github-dark"}}
> {
>   "id": "evt_eEMtA0PkkyACiS5o",
>   "type": "whatsapp.template.reviewed",
>   "apiVersion": "v2",
>   "createTime": "2024-01-01T12:00:00.000Z",
>   "whatsappTemplate": {
>     "wabaId": "WABA-ID",
>     "name": "template_name",
>     "language": "en",
>     "category": "MARKETING",
>     "status": "APPROVED",
>     "reason": "NONE",
>     "statusUpdateEvent": "UNARCHIVED"
>   }
> }
> ```

After verifying the signature and durably accepting the event, return a `2xx` response. Process slow work asynchronously.

```http theme={"theme":{"light":"github-light","dark":"github-dark"}}
HTTP/1.1 200 OK
```

For scenario walkthroughs, see [annotated examples](https://docs.ycloud.com/en/api-reference/guides/examples/webhook-examples/whatsapp-template-reviewed-webhook-examples).


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