The events you can subscribe to
tenant.created, tenant.updated, tenant.deleted, user.invited, user.role_assigned, entitlement.changed, subscription.synced, usage.near_limit, usage.at_limit, and sms.inbound_message. Pick some, or take everything.
TenancyEngine calls your endpoint when a customer is created, a plan changes, or usage reaches a limit. Every call is signed, retried when it fails, and logged.
Webhook endpoints on every plan. Managing them from code needs an API key with the webhooks.manage scope.
tenant.created, tenant.updated, tenant.deleted, user.invited, user.role_assigned, entitlement.changed, subscription.synced, usage.near_limit, usage.at_limit, and sms.inbound_message. Pick some, or take everything.
Each delivery carries an X-TE-Signature header with a timestamp and an HMAC-SHA256 signature of the raw body. The SDK helper rejects a signature older than five minutes, so a captured request cannot be replayed later.
A failed delivery is retried with growing delays, from 10 seconds up to 24 hours, for up to six attempts. The console shows the last 50 attempts for each endpoint, and you can send a test event on demand.
After you rotate a secret, deliveries carry both signatures for 24 hours, so your receiver keeps working while you deploy the new secret. If the old secret leaked, rotate with no overlap.
List, create, update, and delete endpoints, and rotate secrets, from your backend. The signing secret is shown once.
These calls come from the TenancyEngine.Sdk package on NuGet. Every capability is also a REST API, so any language that can make an HTTPS request can use it.
// TenancyEngine calls you: verify the signature before you trust the event.
using var reader = new StreamReader(req.Body);
var rawBody = await reader.ReadToEndAsync();
var signature = req.Headers["X-TE-Signature"].ToString();
return WebhookSignatureVerifier.Verify(rawBody, signature, webhookSecret)
? Results.Ok()
: Results.BadRequest();var created = await te.CreateWebhookAsync(
applicationId,
"https://api.example.com/webhooks/tenancyengine",
"tenant.created,entitlement.changed",
ct);
// The signing secret is shown once. Store it now.
var secret = created.PlainSecret;X-TE-Signature carries the timestamp and signature, and X-TE-Event carries the event type, such as entitlement.changed.
Yes. Compute HMAC-SHA256 over the timestamp, a dot, and the raw body, using your secret. Compare it with v1 in constant time, and reject a timestamp older than five minutes.
TenancyEngine retries with growing delays for up to six attempts. You can see each attempt in the delivery log.
One app and up to five customer workspaces. Upgrade when you need more.
Request access