Endpoints
PATCH /webhooks/{id}
Update URL / events / active flag without rotating the secret.
PATCH
/api/v1/webhooks/{id}secret keyUpdate routing metadata on an existing subscription. The signing secret is preserved — your handler's verification keeps working. Pass only the fields you want to change. To rotate the secret, use the dedicated /rotate-secret endpoint.
Body parameters
urlstringNew HTTPS endpoint. Same validation rules as POST /webhooks.eventsstring[]Replace the events list. Send the full new array — there's no add-only mode.activebooleanPause deliveries without deleting. Disabled subs reject deliveries silently.descriptionstringFree-form label (≤240 chars). Pass `null` to clear.
Request
curl -X PATCH https://sandbox.key2pays.com/api/v1/webhooks/wh_3f6c7b1… \
-H "Authorization: Bearer sk_test_51N8mP...exampleK3Y" \
-H "Content-Type: application/json" \
-d '{ "events": ["payment.completed", "payment.failed", "chargeback.created"] }'Response
{
"id": "wh_3f6c7b…",
"url": "https://acme.com/webhooks/key2pay",
"events": ["payment.completed", "payment.failed", "chargeback.created"],
"active": true,
"description": "Production handler",
"createdAt": "2026-05-10T18:00:00.000Z",
"updatedAt": "2026-05-12T18:00:00.000Z"
}