---
url: https://next.zammad.org/de/reference/rest-api/webhook.md
---

# Webhook

::: info
Webhooks werden von [Triggern](/de/reference/rest-api/trigger) über
den Parameter `notification.webhook` zur Aktions-Ausführung angesprochen
(`{"notification.webhook": {"webhook_id": <id>}}`). Erstellen Sie
zunächst den Webhook und verweisen Sie anschließend in einem oder mehreren
Triggern auf dessen `id`.
:::

## Auflisten

Erforderliche Berechtigung: `admin.webhook`

`GET`-Request gesendet: `/api/v1/webhooks`

::: details

```json
// HTTP-Code 200 OK

[
  {
    "id": 1,
    "name": "Example webhook",
    "endpoint": "https://example.com/webhooks/incoming",
    "http_method": "post",
    "signature_token": "**********",
    "ssl_verify": true,
    "basic_auth_username": "user",
    "basic_auth_password": "**********",
    "bearer_token": null,
    "note": "Notifies an external system about ticket updates.",
    "pre_defined_webhook_type": null,
    "customized_payload": false,
    "custom_payload": null,
    "preferences": {},
    "active": true,
    "updated_by_id": 3,
    "created_by_id": 3,
    "created_at": "2026-09-24T12:31:34.578Z",
    "updated_at": "2026-09-24T12:31:44.512Z"
  }
]

```

:::

::: info
`signature_token`, `basic_auth_password` und `bearer_token` werden
nach ihrer Festlegung als `**********` zurückgegeben. Die API gibt die gespeicherten
Geheimnisse niemals aus. Felder, die nicht gesetzt sind, werden als `null` ausgegeben.
:::

## Anzeigen

Erforderliche Berechtigung: `admin.webhook`

`GET`-Request gesendet: `/api/v1/webhooks/{id}`

::: details

```json
// HTTP-Code 200 OK

{
  "id": 1,
  "name": "Example webhook",
  "endpoint": "https://example.com/webhooks/incoming",
  "http_method": "post",
  "signature_token": "**********",
  "ssl_verify": true,
  "basic_auth_username": "user",
  "basic_auth_password": "**********",
  "bearer_token": null,
  "note": "Notifies an external system about ticket updates.",
  "pre_defined_webhook_type": null,
  "customized_payload": false,
  "custom_payload": null,
  "preferences": {},
  "active": true,
  "updated_by_id": 3,
  "created_by_id": 3,
  "created_at": "2026-09-24T12:31:34.578Z",
  "updated_at": "2026-09-24T12:31:44.512Z"
}

```

:::

## Erstellen

Erforderliche Berechtigung: `admin.webhook`

`POST`-Request gesendet: `/api/v1/webhooks`

:::: details

::: tabs key:reqres

\=== Request

```json
{
  "name": "Example webhook",
  "endpoint": "https://example.com/webhooks/incoming",
  "http_method": "post",
  "signature_token": "your-signature-token",
  "ssl_verify": true,
  "customized_payload": false,
  "note": "Notifies an external system about ticket updates.",
  "active": true
}

```

\=== Response

```json
// HTTP-Code 201 Created

{
  "id": 1,
  "name": "Example webhook",
  "endpoint": "https://example.com/webhooks/incoming",
  "http_method": "post",
  "signature_token": "**********",
  "ssl_verify": true,
  "basic_auth_username": null,
  "basic_auth_password": null,
  "bearer_token": null,
  "note": "Notifies an external system about ticket updates.",
  "pre_defined_webhook_type": null,
  "customized_payload": false,
  "custom_payload": null,
  "preferences": {},
  "active": true,
  "updated_by_id": 3,
  "created_by_id": 3,
  "created_at": "2026-09-24T12:31:34.578Z",
  "updated_at": "2026-09-24T12:31:34.578Z"
}

```

:::

::::

::: info
`ssl_verify` ist für `https://` Endpunkte von Bedeutung; setzen Sie den Wert
auf `true`, um das TLS-Zertifikat des Endpunkts zu überprüfen. Es ist nur für einen
reinen `http://` Endpunkt sinnvoll, den Wert auf `false` zu setzen, falls dieser gar kein
Zertifikat besitzt, das überprüft werden kann.
:::

## Aktualisierung

Erforderliche Berechtigung: `admin.webhook`

`PUT`-Request gesendet: `/api/v1/webhooks/{id}`

Die Struktur der Nutzlast entspricht der von Create. Die Antwort besteht aus
dem aktualisierten Datensatz, dessen Struktur der von Show/Create
entspricht, wobei `updated_at` aktualisiert wird.

::: tip
Auch eine teilweise Nutzlast funktioniert, z.B. `{"active": false}`, um nur
dieses Feld umzuschalten.
:::

:::: details

::: tabs key:reqres

\=== Request

```json
{
  "name": "Example webhook",
  "endpoint": "https://example.com/webhooks/incoming",
  "http_method": "post",
  "signature_token": "your-signature-token",
  "ssl_verify": true,
  "customized_payload": false,
  "note": "Notifies an external system about ticket updates.",
  "active": true,
  "id": 1
}

```

\=== Response

```json
// HTTP-Code 200 OK

{
  "id": 1,
  "name": "Example webhook",
  "endpoint": "https://example.com/webhooks/incoming",
  "http_method": "post",
  "signature_token": "**********",
  "ssl_verify": true,
  "basic_auth_username": null,
  "basic_auth_password": null,
  "bearer_token": null,
  "note": "Notifies an external system about ticket updates.",
  "pre_defined_webhook_type": null,
  "customized_payload": false,
  "custom_payload": null,
  "preferences": {},
  "active": true,
  "updated_by_id": 3,
  "created_by_id": 3,
  "created_at": "2026-09-24T12:31:34.578Z",
  "updated_at": "2026-09-24T12:31:48.115Z"
}

```

:::

::::

## Löschen

Erforderliche Berechtigung: `admin.webhook`

::: danger
**Dies ist eine dauerhafte Entfernung**

Bitte beachten Sie, dass das Entfernen von Webhooks nicht rückgängig gemacht werden kann.
:::

Ein Webhook, der noch von der `perform` Aktion eines anderen Objekts
(z.B. einem [Trigger](/de/reference/rest-api/trigger)) referenziert wird,
kann nicht gelöscht werden. Die API antwortet mit `422 Unprocessable Entity`
und listet die referenzierenden Objekte auf. Entfernen Sie zuerst diese
Referenzen.

`DELETE`-Request gesendet: `/api/v1/webhooks/{id}`

::: details

```json
// HTTP-Code 200 OK

{}

```

:::

::: details

```json
// HTTP-Code 422 Unprocessable Entity

{
  "error": "This object is referenced by other object(s) and thus cannot be deleted: %s",
  "error_human": "This object is referenced by other object(s) and thus cannot be deleted: %s",
  "unprocessable_content": [
    "Trigger / Notify customer on auto-close (#5)"
  ]
}

```

:::
