- Exactly-once processing guarantees ensuring every event is processed once and only once.
- Automatic retries and backoff for failed events.
- Filtering of events with no PL/pgSQL required.
- Backfill support to sync historical data.
- End-to-end observability and debugging tools for failed events.
- Sinks to other streams and queues like SQS and Kafka.
Prerequisites
You are about to migrate a Supabase webhook to a Sequin webhook sink that sends HTTP POST requests to your endpoint when database rows change. You’ll need the following:- A Supabase project
- Sequin installed locally
- Your Supabase database connected to Sequin
Example Supabase webhook to migrate
As an example, here’s a webhook trigger in Supabase for a hypotheticalorders table:
- SQL
- Supabase Console
orders table. The trigger then fires a webhook (via pg_net) to send the data to an HTTP endpoint.
When the trigger fires, Supabase sends the data to the endpoint with the following payload:
Create a Sequin webhook sink
To replicate this exact webhook in Sequin, you’ll create a webhook sink on theorders table with no filters. Here’s how to do it:
1
Create a new sink
Navigate to the “Sinks” tab, click the “Create Sink” button, and select “Webhook Sink”.
2
Select source tables
Select the schemas and tables you want to capture changes from (i.e
public.users or public).3
Add filters (optional)
Add filters to the sink to control which database changes are sent to your webhook endpoint.
4
Configure backfill
Leave “Backfill” toggled off for now.
5
Configure message grouping
Under “Message grouping”, leave the default option selected to ensure events for the same row are sent to your webhook endpoint in order.
6
Configure sink settings
Under “Webhook Sink configuration” leave the defaults:
- Leave the default value of
30000 msfor “Request timeout” as this is more than enough time for your function to process the request - Leave the default value of
1for “Batch size” for now to mimic the behavior of the Supabase webhook.
7
Configure HTTP endpoint
Add your webhook URL and any required headers.
Sequin gives you more control over webhook delivery and retries including a higher request timeout, automatic retries, and the ability to configure max ack pending (e.g. the consumer will stop sending new events to the endpoint if a certain number of events are not acknowledged). Additionally, you can authenticate the messages delivered to your endpoint with encrypted headers.
8
Name and create sink
Give your sink a name (e.g.
orders_webhook_sink) and click “Create Webhook Sink”.Sequin’s data payload is slightly different than Supabase’s webhook payload:
- Sequin’s
metadatafield includes additional metadata about the consumer and the table. - Sequin captures the operation type (e.g.
insert,update,delete) in theactionfield not thetypefield. - Sequin captures changes for
updateanddeleteoperations in thechangesfield not theold_recordfield.- Updates: Sequin’s
changesobject only contains the changed columns and their old values, while Supabase’sold_recordfield contains the prior state of the entire record before it was updated. - Deletes: Sequin’s
recordfield contains the prior state of the record before it was deleted and thechangesfield isnull, while Supabase’sold_recordcontains the the prior state of the record before it was deleted and therecordfield isnull.
- Updates: Sequin’s

