Prerequisites
- A Supabase project on the Pro, Team, or Enterprise plan. Supabase offers log drains on these plans only.
- An ingest key. See Create an ingest key.
Set up the drain
- In Supabase, open Project Settings and select Log Drains.
- Add a destination of type OpenTelemetry (OTLP).
- Set Endpoint to
https://ingest.squasher.ai/v1/logs. - Set Protocol to
http/protobuf. You can turn on Gzip: Squasher reads gzip OTLP bodies. - In Headers, add
x-squasher-keywith your ingest key, then save the drain.
What Squasher keeps from each record
Squasher stores the attributes that Supabase sends as they are. See
What Squasher does with each signal.
Report Edge Function errors
SaveSQUASHER_API_KEY and SQUASHER_PROJECT_ID as Edge Function secrets, then post errors to
the event endpoint:
supabase/functions/checkout/index.ts
handleCheckout is your own function.
Verify
- Select Logs in the sidebar in Squasher. Logs from your Supabase project appear there.
- Make the Edge Function throw once.
- Select Issues in the sidebar. The error is at the top of the list.
Limits
- The Supabase drain sends logs only. It does not send database metrics or traces.
- Which Supabase logs reach
ERRORseverity depends on Supabase.
Next steps
HTTP API
See every event field.
OpenTelemetry
See how Squasher reads OTLP logs.