Overview
Webhooks allow you to receive real-time HTTP callbacks when specific events occur in CVAT. This enables you to build custom integrations, automate workflows, and trigger actions based on CVAT activities.Webhooks are available for both CVAT Cloud and self-hosted installations.
What are Webhooks?
Webhooks are HTTP callbacks triggered by events in CVAT. When an event occurs (like task creation, annotation updates, or job completion), CVAT sends an HTTP POST request to your specified endpoint with event details. Common use cases:- Send notifications to Slack or Discord when tasks are completed
- Trigger automated quality checks after annotation updates
- Update external project management systems
- Start model training pipelines when datasets reach certain thresholds
- Log annotation activities to analytics platforms
- Sync data with external databases
Webhook Types
CVAT supports two types of webhooks:Organization Webhooks
Receive events from all resources within an organization:- Project events (create, update, delete)
- Task events (create, update, delete)
- Job events (create, update, delete)
- Issue events (create, update, delete)
- Comment events (create, update, delete)
- Organization events (update, delete)
- Membership events (create, update, delete)
- Invitation events (create, delete)
Project Webhooks
Receive events only from a specific project:- Task events (create, update, delete)
- Job events (create, update, delete)
- Issue events (create, update, delete)
- Comment events (create, update, delete)
- Project events (update, delete)
Creating a Webhook
Via CVAT UI
- Navigate to the Webhooks page in CVAT
- Click Create webhook
- Configure the webhook:
- Target URL: Your endpoint URL (must be HTTPS)
- Description: Optional description for identification
- Type: Organization or Project
- Project: (If Project type) Select the project
- Events: Select which events to subscribe to
- Content Type:
application/json(default) - Secret: Optional secret for signature verification
- Enable SSL: Verify SSL certificates (recommended)
- Click Create
Via API
Create a webhook using the REST API:Via Python SDK
Available Events
Subscribe to specific events based on your needs:Resource Events
| Event | Description |
|---|---|
create:project | Project created |
update:project | Project updated |
delete:project | Project deleted |
create:task | Task created |
update:task | Task updated (includes annotations) |
delete:task | Task deleted |
create:job | Job created |
update:job | Job updated (includes annotations) |
delete:job | Job deleted |
create:issue | Issue created |
update:issue | Issue updated |
delete:issue | Issue deleted |
create:comment | Comment created |
update:comment | Comment updated |
delete:comment | Comment deleted |
Organization Events
| Event | Description |
|---|---|
update:organization | Organization settings updated |
delete:organization | Organization deleted |
create:membership | User added to organization |
update:membership | Membership role changed |
delete:membership | User removed from organization |
create:invitation | Invitation sent |
delete:invitation | Invitation deleted or accepted |
Webhook Payload
When an event occurs, CVAT sends a POST request with this payload structure:Payload Structure
Payload Fields
- event: The event type (e.g.,
create:task,update:job) - webhook_id: ID of the webhook that triggered
- sender: User who performed the action
- [resource]: The affected resource (task, job, project, etc.)
- before_update: (Update events only) Previous values of changed fields
Example: Task Update Event
Securing Webhooks
Signature Verification
CVAT signs webhook payloads using HMAC-SHA256. Verify signatures to ensure requests are from CVAT:Python Example
Node.js Example
SSL/TLS
Always use HTTPS endpoints and enable SSL verification:- Use valid SSL certificates (not self-signed)
- Keep the Enable SSL option checked in webhook settings
- Use certificate pinning for additional security
IP Allowlisting
For self-hosted CVAT, restrict webhook endpoints to your CVAT server IP addresses.Testing Webhooks
Using Webhook.site
Test webhooks without setting up a server:- Go to webhook.site
- Copy your unique URL
- Create a webhook in CVAT with this URL
- Trigger an event in CVAT
- View the received payload on webhook.site
Ping Endpoint
Test webhook connectivity using the ping endpoint:ping event to your webhook URL.
Local Testing with ngrok
Test webhooks on your local machine:Webhook Management
List Webhooks
Update Webhook
View Delivery History
Redeliver Failed Webhooks
Delete Webhook
Example Integrations
Slack Notifications
Automated Quality Checks
Best Practices
Respond Quickly
Respond Quickly
- Return a 200 response within 10 seconds
- Process webhook data asynchronously if needed
- Use job queues for long-running tasks
- CVAT will retry failed deliveries (5xx errors)
Handle Idempotency
Handle Idempotency
- Webhooks may be delivered multiple times
- Use event IDs or timestamps to detect duplicates
- Design handlers to be idempotent
- Store processed event IDs to avoid reprocessing
Monitor Deliveries
Monitor Deliveries
- Regularly check webhook delivery status
- Set up alerts for failed deliveries
- Review and redeliver failed webhooks
- Update webhook URLs when infrastructure changes
Secure Your Endpoints
Secure Your Endpoints
- Always verify webhook signatures
- Use HTTPS with valid certificates
- Implement rate limiting
- Log suspicious requests
Troubleshooting
Webhook Not Firing
- Verify webhook is active (
is_active: true) - Check event type is in the webhook’s subscribed events
- Ensure the resource is within scope (organization/project)
- Review webhook configuration for typos
Failed Deliveries
- Check target URL is accessible from CVAT servers
- Verify SSL certificate is valid
- Ensure endpoint returns 2xx status code
- Check server logs for errors
- Review timeout settings (webhooks timeout after 10s)
Missing Events
- Some events may not fire for bulk operations
- Check the
before_updatefield to detect actual changes - Review CVAT logs for event processing
Signature Verification Failing
- Ensure secret matches exactly (no extra spaces)
- Use raw request body for signature computation
- Verify HMAC algorithm is SHA256
- Check header name is
X-Signature-256