Webhook delivery
Set up webhooks, verify signatures, handle retries, and see the data sent for every Weav event.
Webhooks send events from Weav to your own systems in real time. When a subscribed event happens, Weav sends an HTTPS POST with a JSON body to your webhook URL. Use them to sync conversations and customers to a CRM, trigger automations when a customer replies, or keep your own records of agents and agent training data up to date.
Webhooks are available on plans that include them. Only workspace admins can manage them.
Set up a webhook
- Go to Settings → Developers → Webhooks
- Click New webhook
- Fill in the form:
- Name: a label for your team, for example
CRM sync - Webhook URL: a public
https://URL, up to 500 characters. Private, local, and internal network addresses are rejected. - Signing secret: at least 8 characters. Weav uses it to sign every request. Store the same value on your server.
- Events to listen for: pick individual events, or All events to receive every event, including ones added later
- Name: a label for your team, for example
- Click Create webhook
New webhooks are enabled right away. To change one later, open it and click Save changes. Leave Signing secret blank to keep the current secret.
Manage webhooks
From a webhook's actions menu you can:
- Edit: change the name, URL, signing secret, or events
- Test: pick an event type and click Send test request to send a sample payload, so you can check your endpoint before real traffic arrives. Test payloads contain placeholder data and only a few fields.
- Enable or Disable: pause deliveries without deleting the webhook. Events that happen while a webhook is disabled are not queued or sent later.
- View delivery logs
- Delete
Delivery logs
The Delivery logs tab lists every delivery, including tests, with its status code and payload. Filter by webhook, event type, status, or date. Open a delivery and click Resend to send the same event data again. A resent delivery gets a new delivery id.
Request format
Every delivery is a POST with these headers:
X-Weav-Event: event type, for exampleconversation.createdX-Weav-Signature: hex-encoded HMAC SHA-256 of the raw request body, signed with your webhook secretContent-Type:application/json
Verify signatures
Compute the HMAC SHA-256 of the raw request body with your signing secret and compare it with X-Weav-Signature in constant time. Reject the request if they don't match.
Use the body exactly as received. Parsing the JSON and serializing it again changes the bytes (for example, Weav escapes / as \/), so the signature won't match.
Node.js (Express)
import crypto from "node:crypto";
import express from "express";
const app = express();
app.post("/webhooks/weav", express.raw({ type: "application/json" }), (req, res) => {
const expected = crypto
.createHmac("sha256", process.env.WEAV_WEBHOOK_SECRET)
.update(req.body)
.digest("hex");
const received = req.get("X-Weav-Signature") ?? "";
if (
received.length !== expected.length ||
!crypto.timingSafeEqual(Buffer.from(received), Buffer.from(expected))
) {
return res.sendStatus(401);
}
const event = JSON.parse(req.body);
// Queue event for processing, then respond quickly
res.sendStatus(200);
});
Python (Flask)
import hashlib
import hmac
import os
from flask import Flask, abort, request
app = Flask(__name__)
@app.post("/webhooks/weav")
def weav_webhook():
expected = hmac.new(
os.environ["WEAV_WEBHOOK_SECRET"].encode(),
request.get_data(),
hashlib.sha256,
).hexdigest()
if not hmac.compare_digest(expected, request.headers.get("X-Weav-Signature", "")):
abort(401)
event = request.get_json()
# Queue event for processing, then respond quickly
return "", 200
PHP
$payload = file_get_contents('php://input');
$expected = hash_hmac('sha256', $payload, getenv('WEAV_WEBHOOK_SECRET'));
if (! hash_equals($expected, $_SERVER['HTTP_X_WEAV_SIGNATURE'] ?? '')) {
http_response_code(401);
exit;
}
$event = json_decode($payload, true);
http_response_code(200);
Delivery behavior
- Any
2xxresponse within 30 seconds counts as success 410 Gonedisables the webhook immediately, with no retries- Any other status, a timeout, or a connection error is retried. Each delivery gets up to 10 attempts in total, waiting 1, 2, 4, 8, 16, 32, 64, 128, and then 256 minutes between attempts (about 8.5 hours overall)
- If 10 deliveries in a row fail all their attempts, Weav disables the webhook. Any successful delivery resets the count. Fix your endpoint, then click Enable to turn the webhook back on
- Deliveries to a URL that resolves or redirects to a private or internal address are blocked and not retried
Handle deliveries safely
- Respond fast. Return
2xxas soon as the signature checks out, then do the work in a background job. - Deduplicate on
id. Automatic retries of a delivery reuse the sameid, so store processed IDs and skip repeats. - Don't rely on order. Retries can arrive after newer events. Compare
updated_atindatabefore overwriting newer records. - Use
410deliberately. Only return it when you want Weav to stop sending to this URL.
Payload
The JSON request body contains:
eventstringrequiredEvent type. Same value as the X-Weav-Event header. See Events.
idstringrequiredUnique webhook delivery identifier. UUID. Automatic retries reuse it; Resend creates a new one.
organization_idstringrequiredOrganization UUID that emitted the event. UUID.
dataobjectrequiredEvent-specific payload. Shape depends on event type.
Events
| Event | Sent when | data |
|---|---|---|
conversation.created |
A conversation is created | Conversation |
conversation.deleted |
A conversation is deleted | Conversation |
conversation.assigned.updated |
The assignee changes, including unassigning | Conversation |
conversation.status.updated |
The status changes | Conversation |
conversation.priority.updated |
The priority changes | Conversation |
conversation.tags.updated |
Tags are added or removed | Conversation tags |
conversation.customer.message.created |
A customer sends a message | Message |
conversation.user.message.created |
A teammate sends a reply or internal note | Message |
customer.created |
A customer is created | Customer |
customer.updated |
A customer's details change | Customer |
customer.deleted |
A customer is deleted | Customer |
agent.created |
An AI agent is created | Agent |
agent.updated |
An AI agent's settings are saved | Agent |
agent.deleted |
An AI agent is deleted | Agent |
training.created |
Agent training data is added | Training data |
training.updated |
Agent training data changes, including processing status | Training data |
training.deleted |
Agent training data is deleted | Training data |
training.agent.assigned |
Agent training data is assigned to, or removed from, an AI agent | Training assignment |
One change can send more than one event. For example, closing and reassigning a conversation in one step sends both conversation.status.updated and conversation.assigned.updated.
Training events cover agent training data only. Help Center articles are a separate knowledge base: publishing an article copies it into every agent's training data, but those copies don't send training.* events. Suggested training data waiting for review doesn't send events until it's approved.
Event data
Conversation
{
"id": "019a5a3c-f1ce-7066-86ae-1ed35540a7ce",
"title": "Help with my account",
"status": "open",
"priority": "normal",
"channel": "email",
"assignee_id": null,
"assignee_type": null,
"customer_id": "0197d061-63a9-73c5-b574-e49d8b7964fb",
"created_at": "2025-11-06T17:35:34+00:00",
"updated_at": "2025-11-06T17:35:34+00:00"
}
assignee_type is user, agent, or null.
Conversation tags
{
"id": "019a5a3c-f1ce-7066-86ae-1ed35540a7ce",
"title": "Help with my account",
"tags": ["billing", "vip"]
}
tags is the full list after the change.
Message
{
"id": "019a5a3d-0b12-7a4e-9c11-3f7d2a6b8e01",
"conversation_id": "019a5a3c-f1ce-7066-86ae-1ed35540a7ce",
"content": "Hi, I can't log in to my account.",
"sender_type": "customer",
"sender_id": "0197d061-63a9-73c5-b574-e49d8b7964fb",
"channel": "email",
"created_at": "2025-11-06T17:35:34+00:00"
}
sender_type is customer or user.
Customer
{
"id": "0197d061-63a9-73c5-b574-e49d8b7964fb",
"name": "Jane Doe",
"email": "jane@example.com",
"phone": null,
"company_id": null,
"locale": "en",
"country": "US",
"region": "CA",
"city": "San Francisco",
"timezone": "America/Los_Angeles",
"language": "en",
"created_at": "2025-11-06T17:35:34+00:00",
"updated_at": "2025-11-06T17:35:34+00:00"
}
Agent
{
"id": "019cb3cc-d8d0-739b-81aa-0d123f36ba9d",
"name": "Support agent",
"is_active": true,
"is_copilot": false,
"created_at": "2025-11-06T17:35:34+00:00",
"updated_at": "2025-11-06T17:35:34+00:00"
}
Training data
{
"id": "019a6b1e-2c3d-7f40-8a5b-6c7d8e9f0a1b",
"title": "Refund policy",
"type": "text",
"status": "completed",
"created_at": "2025-11-06T17:35:34+00:00",
"updated_at": "2025-11-06T17:35:34+00:00"
}
type is text, url, file, video, or qa.
Training assignment
{
"training_data_id": "019a6b1e-2c3d-7f40-8a5b-6c7d8e9f0a1b",
"agent_id": "019cb3cc-d8d0-739b-81aa-0d123f36ba9d",
"agent_name": "Support agent",
"training_data_title": "Refund policy",
"training_data_type": "text"
}
When training data is removed from an agent, data also includes "action": "detached". For a single page discovered from a website, data has url_discovery_result_id and url instead of training_data_id, training_data_title, and training_data_type.
Example payload
{
"event": "conversation.created",
"id": "550e8400-e29b-41d4-a716-446655440000",
"organization_id": "123e4567-e89b-12d3-a456-426614174000",
"data": {
"id": "019a5a3c-f1ce-7066-86ae-1ed35540a7ce",
"title": "Help with my account",
"status": "open",
"priority": "normal",
"channel": "email",
"assignee_id": null,
"assignee_type": null,
"customer_id": "0197d061-63a9-73c5-b574-e49d8b7964fb",
"created_at": "2025-11-06T17:35:34+00:00",
"updated_at": "2025-11-06T17:35:34+00:00"
}
}

