v1

latestOpenAPI 3.0.02026-08-0696238481.7 KB
Webhooks

Update a webhook endpoint

This is used to update a webhook by its unique Id

patch/webhooks/{webhookId}

Path parameters

webhookIdstring required
Example:wh_01FCTS1XMKH9FF43CAFA4CXT3P

Webhook Id to update

Request body

urlstring nullable

The new URL of your webhook endpoint

activeboolean nullable

Whether the endpoint is active (receiving events) or not

eventTypesEventType[] nullable

The event types you want the endpoint to receive

Example request

{
  "url": "https://example-endpoint.com/webhook",
  "active": true,
  "eventTypes": [
    "PaymentSession.captured",
    "PaymentSession.refunded"
  ]
}

Response

Webhook endpoint successfully updated

idstring

The unique Id for the webhook endpoint

activeboolean

Whether the endpoint is actively receiving events or not

urlstring

The URL of the webhook endpoint

eventTypesEventType[]

The event types the endpoint is receiving

createdTimestampinteger

The epoch timestamp (seconds) when the webhook endpoint was created

lastUpdatedTimestampinteger

The epoch timestamp (seconds) when the webhook endpoint was last updated

Example response

{
  "id": "wh_31fba123-0fef-41d6-92ad-fd7089f49f8a",
  "active": true,
  "url": "https://example-endpoint.com/webhook",
  "eventTypes": [
    "PaymentSession.captured",
    "PaymentSession.refunded"
  ],
  "createdTimestamp": 1470989538,
  "lastUpdatedTimestamp": 1470989538
}