Webhooks
Receive real-time notifications when events occur in your knowledge base.
Read time:6 minUpdated:2026-01-10
Webhooks
Receive real-time HTTP notifications when events occur in TyneBase.
Setting Up Webhooks
Create a Webhook
- Go to Settings → Integrations → Webhooks
- Click + Add Webhook
- Enter your endpoint URL
- Select events to subscribe to
- Save and copy the signing secret
Or via API
POST /v1/webhooks
{
"url": "https:tynebase.com/webhooks/apiv1",
"events": [
"document.created",
"document.published",
"document.deleted"
],
"secret": "your-signing-secret"
}
Event Types
Document Events
| Event | Description |
|---|---|
document.created |
New document created |
document.updated |
Document content changed |
document.published |
Document state → published |
document.archived |
Document state → archived |
document.deleted |
Document permanently deleted |
User Events
| Event | Description |
|---|---|
user.invited |
New user invitation sent |
user.joined |
User accepted invitation |
user.removed |
User removed from workspace |
user.role_changed |
User role updated |
AI Events
| Event | Description |
|---|---|
ai.generation_completed |
AI document generation finished |
ai.generation_failed |
AI generation error |
ai.index_updated |
Document re-indexed for RAG |
Webhook Payload
{
"id": "evt_abc123xyz",
"type": "document.published",
"created_at": "2026-01-10T14:30:00Z",
"data": {
"document": {
"id": "doc_123",
"title": "Getting Started Guide",
"slug": "getting-started-guide",
"state": "published",
"author_id": "usr_456"
},
"previous_state": "draft"
},
"tenant": {
"id": "ten_789",
"subdomain": "acme"
}
}
Verifying Signatures
All webhook requests include a signature header:
X-TyneBase-Signature: sha256=abc123...
Verify in your handler:
import crypto from 'crypto';
function verifyWebhook(
payload: string,
signature: string,
secret: string
): boolean {
const expected = crypto
.createHmac('sha256', secret)
.update(payload)
.digest('hex');
return crypto.timingSafeEqual(
Buffer.from(signature.replace('sha256=', '')),
Buffer.from(expected)
);
}
Retry Policy
Failed webhooks are retried with exponential backoff:
| Attempt | Delay |
|---|---|
| 1 | Immediate |
| 2 | 1 minute |
| 3 | 5 minutes |
| 4 | 30 minutes |
| 5 | 2 hours |
After 5 failures, the webhook is disabled.
Testing Webhooks
Use the webhook tester in Settings:
- Select an event type
- Click Send Test
- View request/response in the log