UI Inspect
API Reference

Webhooks

API endpoints for configuring webhook integrations with Slack, Discord, and custom URLs.

Webhooks let you receive real-time notifications when events occur in UI Inspect.

webhook.list

List all configured webhooks.

TypeQuery
AuthProtected

webhook.create

Create a new webhook endpoint.

TypeMutation
AuthProtected

Input:

{
  name: string;
  url: string;                              // Webhook endpoint URL
  type?: "slack" | "discord" | "custom";    // Default: "custom"
  events?: string[];                        // Event types to subscribe to
}

webhook.update

Update an existing webhook.

TypeMutation
AuthProtected

Input:

{
  id: string;
  name?: string;
  url?: string;
  enabled?: boolean;
  events?: string[];
}

webhook.delete

Delete a webhook.

TypeMutation
AuthProtected

Input: { id: string }


webhook.test

Send a test payload to a webhook endpoint.

TypeMutation
AuthProtected

Input: { id: string }

Response:

{
  success: boolean;
  error?: string;
}

Webhook payload

All webhooks receive a JSON payload:

{
  "event": "comparison.complete",
  "timestamp": "2025-01-15T10:30:00Z",
  "data": {
    "id": "comparison-uuid",
    "projectId": "project-uuid",
    "componentName": "homepage",
    "status": "pending",
    "diffsFound": 3
  }
}

Supported events

EventDescription
comparison.completeA comparison has finished analyzing
comparison.failedA comparison failed to process
build.completeA build has finished
build.failedA build failed
baseline.approvedA baseline was approved
baseline.rejectedA baseline was rejected

On this page