> ## 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.

# Eliminar webhook de plantilla

> Elimina permanentemente un webhook de plantilla

export const projectName = 'Omni Z-API';

export const EnterpriseText = ({lang = 'pt'}) => ({
  pt: <>Este endpoint requer a role <strong>ENTERPRISE</strong> na sua conta.</>,
  en: <>This endpoint requires the <strong>ENTERPRISE</strong> role on your account.</>,
  es: <>Este endpoint requiere el rol <strong>ENTERPRISE</strong> en tu cuenta.</>
})[lang];

## Conceptos

Elimina permanentemente un webhook de plantilla. Tras el borrado, {projectName} deja de enviar eventos de plantilla a la URL configurada de forma inmediata.

<Warning>
  El borrado es permanente. Si solo necesitas pausar el webhook temporalmente, usa el endpoint [Actualizar webhook de plantilla](/es/webhooks/update-template-webhook) con `status: "DISABLED"` en lugar de eliminarlo.
</Warning>

<Note>
  <EnterpriseText lang="es" />
</Note>

<Note>
  El `webhookId` se obtiene en la respuesta del endpoint [Crear webhook de plantilla](/es/webhooks/create-template-webhook) o [Listar webhooks de plantilla](/es/webhooks/list-template-webhooks).
</Note>


## OpenAPI

````yaml es/webhooks/openapi-template.json DELETE /v1/webhooks/{webhookId}
openapi: 3.1.0
info:
  title: Omni Z-API - Webhooks de plantilla
  description: >-
    API para crear y gestionar webhooks de plantilla: endpoints que reciben los
    eventos de plantilla de WhatsApp y no dependen de una instancia
    (`instanceId` se guarda como `null`). Requiere el rol ENTERPRISE. Conviven
    con las rutas de webhook por instancia o canal, que se mantienen sin
    cambios.
  version: 1.0.0
servers:
  - url: https://api.omni.z-api.io
security:
  - bearerAuth: []
paths:
  /v1/webhooks/{webhookId}:
    delete:
      tags:
        - Webhooks de plantilla
      summary: Eliminar webhook de plantilla
      description: >-
        Elimina permanentemente el webhook de plantilla. Tras el borrado, ya no
        se entrega ningún evento de plantilla en la URL configurada.
      operationId: deleteTemplateWebhook
      parameters:
        - name: webhookId
          in: path
          required: true
          description: ID del webhook de plantilla
          schema:
            type: string
            example: 8F2C00000000000000000000000000A1
      responses:
        '204':
          description: Webhook eliminado correctamente. No se devuelve contenido.
        '404':
          description: Webhook no encontrado para el tenant
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: Webhook not found
        '422':
          description: Cuenta sin el rol ENTERPRISE
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                error: This action requires ENTERPRISE role
components:
  schemas:
    Error:
      type: object
      properties:
        error:
          type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: Secret Key generada en el panel de Seguridad de Omni Z-API

````