The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
Minor correction to FCM Push Notifications Guide (#21370)
Ronan O'Driscoll15887ee16433
diff --git a/apps/docs/content/guides/functions/examples/push-notifications.mdx b/apps/docs/content/guides/functions/examples/push-notifications.mdxindex 927a6714f46..9305eef21ba 100644--- a/apps/docs/content/guides/functions/examples/push-notifications.mdx+++ b/apps/docs/content/guides/functions/examples/push-notifications.mdx@@ -130,7 +130,7 @@ Push notifications are an important part of any mobile app. They allow you to seWe will create two tables. One to store the user's FCM token and a `notifications` table. The edge function will be triggered when a new row is inserted into the `notifications` table and sends a push notification to the user.- Run the following SQL to create the tables.+ Create a `notifications` table. Also create a `profiles` table if you don't already have one:```sqlcreate table public.profiles (@@ -142,10 +142,17 @@ Push notifications are an important part of any mobile app. They allow you to seid uuid not null default gen_random_uuid(),user_id uuid references auth.users(id) not null,created_at timestamp with time zone not null default now(),- body text not null,+ body text not null);```+ If you already have a `profiles` table, alter it to include an `fcm_token` column:++ ```sql+ ALTER TABLE public.profiles+ ADD COLUMN fcm_token text;+ ```+With the tables created, we can now create the edge function that will be triggered by database webhook when a notification is inserted.Create the function using the following command: