SupabaseS
Supabase11mo ago
anta

Database Webhook not working with Discord

Hi, ive just followed the doc and executed this query :
create trigger "my_webhook" after insert
on "public"."todos" for each row
execute function "supabase_functions"."http_request"(
  'https://discord.com/api/webhooks/myhookid',
  'POST',
  '{"Content-Type":"application/json"}',
  '{}',
  '1000'
);


after insterting a row, nothing happened.
i tried to create webhook using supabase UI (/integrations), same thing.

i verified if webhook url was correct with powershell command :
$Headers = @{ "Content-Type" = "application/json" }; $Body = @{ content = "Test webhook PowerShell" } | ConvertTo-Json; Invoke-WebRequest -Uri "https://discord.com/api/webhooks/myhookid" -Method POST -Headers $Headers -Body $Body

and i correctly received Test webhook PowerShell

any idea ?
thanks for helping
Was this page helpful?