Skip to main content
The Sanity plugin handles incoming webhooks. Point your provider’s subscription URL at your Corsair HTTP handler (see Overview for setup context and the exact URL shape).
New to Corsair? See webhooks and hooks.

Webhook map

  • documents
    • changed (documents.changed)

HTTP handler setup

app/api/webhook/route.ts

Events

Documents

Changed

documents.changed A GROQ-powered webhook fired: a document matching its filter was created, updated or deleted. The body is the webhook’s projection; the operation, document id and dataset come from its headers. Only signed deliveries are accepted. Payload: any
webhookHooks example