Skip to main content
A webhook endpoint is a URL you register with SpherePay together with the list of events it should receive. This page covers the full endpoint lifecycle: creating an endpoint, listing and retrieving endpoints, and deleting them.

Register an endpoint

Create an endpoint with POST /v2/webhook-endpoints:
The response returns the endpoint and its signing secret:
The secret (prefixed whsec_) is returned exactly once, in the creation response. It is never returned by GET requests and cannot be retrieved later. Store it securely — you need it to verify the signature on every delivery. Each endpoint has its own distinct secret; secrets are never shared across endpoints.
Newly created endpoints are enabled immediately and begin receiving events that match their subscription.

Updating an endpoint: delete and recreate

There is currently no update operation for webhook endpoints. To change an endpoint’s URL, subscribed events, or any other property, delete the endpoint and create a new one. The same applies to rotating a signing secret — deleting an endpoint invalidates its secret, and the replacement endpoint receives a fresh one.
In-place endpoint updates are coming soon — a future release will let you modify an existing endpoint’s URL and subscriptions without recreating it. Until then, use the delete-and-recreate flow below.
For a zero-gap migration:
  1. Create the new endpoint with the updated configuration. Both endpoints now receive events.
  2. Confirm the new endpoint is receiving and verifying deliveries.
  3. Delete the old endpoint.
During step 1 both endpoints receive matching events, so your handlers should be idempotent — deduplicate on the event id in the payload body.

List and retrieve endpoints

List query parameters:
The subscribedEvents filter matches literally against each endpoint’s subscription list — it does not expand wildcards. Filtering by transfer.* returns endpoints that subscribed with the transfer.* wildcard itself, not endpoints subscribed to individual events like transfer.succeeded (and vice versa). To find every endpoint that would receive a given event, filter by both forms: subscribedEvents=transfer.succeeded,transfer.*,*.
List responses use SpherePay’s standard pagination envelope: { "data": [...], "page", "limit", "total", "totalPages", "hasNext", "hasPrevious" }. Retrieve a single endpoint with GET /v2/webhook-endpoints/{id}. The secret field is never included.

Delete an endpoint

Deletion returns 204 No Content, transitions the endpoint to the deleted state, invalidates its signing secret, and stops all future deliveries. This is terminal and cannot be undone — to resume delivery, create a new endpoint.

Endpoint limits

Each application may have at most 6 active webhook endpoints — endpoints in the enabled, disabled, or errored state. Deleted endpoints do not count toward the limit. Exceeding it returns 409 Conflict.

Endpoint states

Only enabled endpoints receive deliveries.
Failed deliveries do not disable your endpoint. In the current release, SpherePay never changes an endpoint’s state based on delivery outcomes: if your endpoint returns a non-2xx response or times out, the individual delivery is marked failed and no automatic retry occurs, but the endpoint stays enabled and continues receiving subsequent events. Recover missed events with a manual replay.

Errors

Last modified on August 11, 2026