Managing Webhooks — Proposed Guide
Planned API — Reference OnlyManaging Webhooks: Managing a subscription would change event selection or administrative state with a defined effective point. Disabling a subscription…
Overview
Managing a subscription would change event selection or administrative state with a defined effective point. Disabling a subscription differs from deleting historic delivery evidence.
Key concepts
Version configuration and audit administrative changes. Specify whether in-flight attempts use the old or new receiver.
Implementation considerations
Do not erase failed-delivery history when changing a URL. No subscription settings are stored or activated here.
Proposed API behavior
PATCH /v1/webhook-subscriptions/{subscription_id} is an illustrative design for this topic. Path and field names may change before implementation. Access would require an authorized organization context and operation-specific permission; no public API or authorization grant is available here.
| Name | Type | Description |
|---|---|---|
| subscription_idrequired | string | Stable fictional subscription reference; not a secret and not evidence that a resource exists. |
| Name | Type | Description |
|---|---|---|
| event_types | array<string> | Proposed event selection; no subscription is created. |
| status | string | Proposed lifecycle value. Its meaning depends on the resource and must not be inferred from HTTP success. |
| version | integer | Illustrative resource revision for detecting stale updates; no live concurrency contract is published. |
Static example requests
# Proposed request text only; this reserved host is not a live API.
curl -X PATCH 'https://api.remizen.example/v1/webhook-subscriptions/subscription_example_123' \
-H 'Authorization: Bearer YOUR_API_KEY' \
-H 'Content-Type: application/json' \
--data '{
"event_types": [
"expense.updated"
],
"status": "draft",
"version": 1
}'Fictional response example
Fictional documentation data only. No request was sent, record created, review performed, payment initiated or provider connection activated.
{
"data": {
"subscription_id": "subscription_example_123",
"event_types": [
"expense.updated"
],
"version": 1,
"id": "webhook_subscriptions_example_123",
"organization_id": "org_example_123"
},
"meta": {
"request_id": "req_example_123",
"reference_only": true
}
}Illustrative error case
Review this failure case in context: Do not erase failed-delivery history when changing a URL. No subscription settings are stored or activated here.
Synthetic diagnostic example. Human-readable messages must not be used as stable programmatic contracts.
{
"error": {
"code": "validation_error",
"message": "The proposed managing webhooks operation requires review of its input or authorization.",
"request_id": "req_example_123"
}
}Proposed data types
| Name | Type | Description |
|---|---|---|
| subscription_id | string | Stable fictional subscription reference; not a secret and not evidence that a resource exists. |
| event_types | array<string> | Proposed event selection; no subscription is created. |
| status | string | Proposed lifecycle value. Its meaning depends on the resource and must not be inferred from HTTP success. |
| version | integer | Illustrative resource revision for detecting stale updates; no live concurrency contract is published. |