SDK reference · Python SDK

prov.webhooks.update

prov.webhooks.update in Python SDK.

Signature

prov.webhooks.update(endpoint_id: str, **body: Any = …) -> Any

Parameters

endpoint_idstrRequired
**bodyAny

Request fields

idstringpathRequired
The object's ID.
urlstring
A URL.
event_typesarray of strings
The event types, or * for all.
statusenum
The object's current status. One of active, disabled.
api_versionstring
The API version deliveries are rendered at, such as 2026-11-30.

Returns

Any The updated endpoint.

HTTP operation

PATCH /v1/webhook_endpoints/{id}: Update a webhook endpoint

Errors

Example

const step1 = await (await fetch(`${process.env.PROVENANCE_API}/v1/webhook_endpoints`, {
  method: "POST",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json" },
  body: JSON.stringify({
    "url": "http://localhost:4242/webhooks",
    "event_types": [
      "mandate.approval.approved"
    ]
  }),
})).json();
const endpointId = step1.id;
const data = await (await fetch(`${process.env.PROVENANCE_API}/v1/webhook_endpoints/${endpointId}`, {
  method: "PATCH",
  headers: { Authorization: "Bearer prv_test_acct_P9xN2vQ7bT4mW8sYd3cFjLh6gAe1kR5", "Content-Type": "application/json" },
  body: JSON.stringify({ "event_types": ["*"] }),
})).json();

Was this page helpful? Send us feedback

LLM? Read llms.txt.