Skip to content

Documentation

Update a webhook endpoint

PATCH/v1/webhooks/{webhook}Webhooks

Changes the address, the events or the note, or pauses and resumes it. Fields left out stay.

Parameters

ParameterTypeRequiredDescription
webhookstring, in the pathrequiredThe endpoint's id.

Request body

JSON, sent with Content-Type: application/json.

FieldTypeRequiredDescription
urlstringoptional
eventslink.created | link.updated | link.deleted | link.clicked | link.failing | link.recovered | page.changed[]optionallink.created: A link was made, through any door. link.updated: A link's destination, ending, title, rules, schedule or state changed. link.deleted: A link was deleted. link.clicked: Visits, sent in batches of up to 100 every few seconds. link.failing: A link's destination stopped answering (two failed checks in a row). link.recovered: A failing destination answers again. page.changed: A watched page's words changed.
descriptionstring, nulloptional
enabledbooleanoptionalfalse pauses it (what is waiting is dropped); true switches it back on, a failing one included.

Example request

curl -s -X PATCH "https://snip.link/v1/webhooks/webhook" \
  -H "Authorization: Bearer $SNIP_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'

Example response

{
  "webhook": {
    "id": "5c2e7a10-3f4b-4d8e-9a61-2b7c0d4e8f13",
    "url": "https://example.com/hooks/snip",
    "description": "Orders service",
    "events": [
      "link.created",
      "link.clicked"
    ],
    "enabled": true,
    "disabled_reason": null,
    "disabled_at": null,
    "failing_since": null,
    "last_success_at": "2026-10-24T09:12:03.000Z",
    "waiting": 0,
    "created_at": "2026-10-20T12:00:00.000Z",
    "updated_at": "2026-10-20T12:00:00.000Z"
  }
}

Response fields

FieldTypeDescription
webhookWebhook
webhook.idstring
webhook.urlstringWhere deliveries go: https, a public domain, the standard port.
webhook.descriptionstring, null
webhook.eventslink.created | link.updated | link.deleted | link.clicked | link.failing | link.recovered | page.changed[]
webhook.enabledbooleanFalse while paused, or after three days in which every delivery failed.
webhook.disabled_reasonpaused | failing | nullpaused by the account, or failing: switched off after three days of failures.
webhook.disabled_atstring, null
webhook.failing_sincestring, nullWhen the current run of failed deliveries began; null while the last one worked.
webhook.last_success_atstring, null
webhook.waitingintegerDeliveries queued or waiting for a retry.
webhook.created_atstring
webhook.updated_atstring

Errors

StatusMeaning
400The body or query is invalid. details names each field.
401The API key is missing, malformed or revoked.
404No webhook endpoint by that id in this account.
429Either the key exceeded its requests-per-second limit (honor Retry-After), or a daily or plan quota is used up (details.reason).

Back to getting started