Create a webhook subscription
Manage outbound webhook subscriptions for the authenticated tenant.
Subscriptions are tenant-scoped. Only active subscriptions are returned
by list and retrieve. Deletion is permanent — the row is removed
from the DB and any associated delivery rows cascade.
On this page
HTTP request
POST https://api.parsewise.ai/api/v1/webhooks/
Request Header
| Name | Required | Type | Description |
|---|---|---|---|
X-API-Key |
Yes | string | API key with the pw_live_ prefix. See Authentication. |
Request Body
Supported content types: application/json, application/x-www-form-urlencoded, multipart/form-data.
| Name | Required | Type | Description |
|---|---|---|---|
name |
No | string | Friendly name for this subscription (optional). |
url |
Yes | string | HTTPS URL Parsewise will POST webhook events to. |
subscribed_events |
Yes | array<string> | Event names this subscription should receive. |
headers |
No | object<string, string> | Custom HTTP headers to include with every delivery. Encrypted at rest. Up to 10 entries; values up to 1KB each; total ≤ 4KB. The Host, Connection, Content-Length, Transfer-Encoding, Content-Type and any Parsewise-* headers are reserved. |
Responses
| Status | Type | Description |
|---|---|---|
201 |
V1WebhookSubscription | — |
Security
- ApiKeyAuth — apiKey — in
X-API-Keyheader. API key with pw_live_ prefix.
Python example
import os
import requests
API_KEY = os.environ["PARSEWISE_API_KEY"]
BASE_URL = "https://api.parsewise.ai/api/v1"
body = {
"name": "...", # optional
"url": "...",
"subscribed_events": [],
"headers": {}, # optional
}
resp = requests.post(
f"{BASE_URL}/webhooks/",
headers={"X-API-Key": API_KEY},
json=body,
)
resp.raise_for_status()
print(resp.json() if resp.content else None)
Definitions
V1WebhookSubscription
Read-side serializer. Used by list / retrieve / create / update responses.
| Name | Required | Type | Description |
|---|---|---|---|
id |
Yes | string (uuid) | |
name |
Yes | string | |
url |
Yes | string | |
subscribed_events |
Yes | array<string> | Event names this subscription is subscribed to. |
is_active |
Yes | boolean | |
headers |
Yes | object<string, string> | Custom request header keys registered for this subscription. Values are always redacted. |
created_at |
Yes | string (date-time) | |
updated_at |
Yes | string (date-time) |
V1WebhookSubscriptionWriteRequest
Validates create / update bodies. Not bound to the model.
| Name | Required | Type | Description |
|---|---|---|---|
name |
No | string | Friendly name for this subscription (optional). |
url |
Yes | string | HTTPS URL Parsewise will POST webhook events to. |
subscribed_events |
Yes | array<string> | Event names this subscription should receive. |
headers |
No | object<string, string> | Custom HTTP headers to include with every delivery. Encrypted at rest. Up to 10 entries; values up to 1KB each; total ≤ 4KB. The Host, Connection, Content-Length, Transfer-Encoding, Content-Type and any Parsewise-* headers are reserved. |