Skip to main content
The WebhooksService class (accessed via client.webhooks) lets you register HTTPS endpoints that receive real-time push notifications as deliveries progress — so your systems react to events instead of polling the API.
Secret key required. Webhook management uses a secret key (tybrite_sk_*). Publishable keys are rejected — these endpoints expose your account’s event configuration.

createWebhook

Registers a new endpoint and subscribes it to the events you care about.
The signing_secret is returned only once, at creation. It cannot be retrieved again — store it immediately in your secrets manager. Use it to verify the signature on every incoming delivery.
Returns { webhook } — wrapped. The webhook.signing_secret field is present only on this create response. Available event names:

listWebhooks

Lists the endpoints registered on your account.
Returns your webhook endpoints (without the one-time signing secrets).

deleteWebhook

Removes an endpoint so it stops receiving events.

testWebhook

Sends a realistic sample event to the endpoint so you can verify connectivity and your signature-verification code before relying on live traffic.
The test payload is marked test: true and livemode: false so your handler can distinguish it from real events. Sandbox keys (tybrite_sk_test_*) also deliver real events with livemode: false — check that flag if you must treat live and sandbox traffic differently.

Delivery contract

  • At-least-once delivery — make your handler idempotent and dedupe on the event id.
  • Signed — verify every delivery with the signing_secret from createWebhook before acting on it.
  • Respond fast — return 2xx quickly and do heavy work asynchronously; slow responses are treated as failures and retried.