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

# Update a webhook

`PATCH /v2/webhooks/{webhook_key}`

Updates the specified webhook by setting the values of the parameters passed.

## Path parameters

- `webhook_key` string, required

## Request body

- union
  - object — Webhook Base
    - `events` string[] — A list of events to send to the registered Webhook.
    - `target_url` string, uri, required — URL endpoint Webhook data will be sent to.
  - object — Webhook Base
    - `events` string[], required — A list of events to send to the registered Webhook.
    - `target_url` string, uri — URL endpoint Webhook data will be sent to.

## Response `200`

Updates the specified webhook by setting the values of the parameters passed.

- object
  - `data` object, required — Webhook
    - `created_at` integer — Immutable Unix timestamp in milliseconds taken at time of creation
    - `key` string — A unique identifier used to reference the object
    - `updated_at` integer — Unix timestamp in milliseconds taken at time of last update
    - `events` string[] — A list of events to send to the registered Webhook.
    - `target_url` string, uri — URL endpoint Webhook data will be sent to.
  - `message` string, required
  - `status` integer, required

## Other responses

- `400` — Bad Request Error
- `401` — Unauthorized Error
- `403` — Forbidden Error
- `404` — Not Found Error
- `500` — Internal Server Error

---

[API](https://skmtc.dev/partnerstack/apis/partnerstack-api.md) · [All operations](https://skmtc.dev/partnerstack/apis/partnerstack-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/partnerstack/partnerstack-api/revisions/0f35aebe53a9/schema)
