---
title: "Update a webhook endpoint"
method: PATCH
path: "/webhooks/{id}"
tags: ["Webhooks"]
---

# Update a webhook endpoint

`PATCH /webhooks/{id}`

## Request

- Base URL: `https://www.unitpost.com/api/v1`
- URL: `https://www.unitpost.com/api/v1/webhooks/{id}`
- Auth: HTTP bearer

Update a webhook endpoint's `url`, subscribed `events`, `name`, and/or `status` (use `status` to pause and re-enable deliveries without deleting the endpoint). The signing secret is never changed by an update. Verify your changes with [Send a test event](#post-webhooks-id-test). Requires the `webhooks:manage` capability.

## Request body

- WebhookUpdate
  - `url` string
  - `events` string[]
  - `name` string
  - `status` 'enabled' | 'disabled'

## Response `200`

The updated endpoint.

- Webhook
  - `object` 'webhook', required
  - `id` string, required
  - `name` string, required
  - `url` string, required
  - `events` string[], required
  - `status` 'enabled' | 'disabled' | 'suspended', required
  - `created_at` string, required
  - `updated_at` string, required

## Other responses

- `401`: Missing or invalid API key.
- `403`: Insufficient scope.
- `404`: Webhook not found.
- `409`: That URL or name is already used by another endpoint.
- `422`: Validation error.

---

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