The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
Update snippets in the api docs to supabase-js v2
Andrew Smith1667c316589d
diff --git a/studio/components/to-be-cleaned/Docs/Snippets.js b/studio/components/to-be-cleaned/Docs/Snippets.jsindex 937780e7059..6e4995dc0a8 100644--- a/studio/components/to-be-cleaned/Docs/Snippets.js+++ b/studio/components/to-be-cleaned/Docs/Snippets.js@@ -487,7 +487,7 @@ curl -X POST '${endpoint}/auth/v1/signup' \\js: {language: 'js',code: `-let { user, error } = await supabase.auth.signUp({+let { data, error } = await supabase.auth.signUp({email: '[email protected]',password: '${randomPassword}'})@@ -511,7 +511,7 @@ curl -X POST '${endpoint}/auth/v1/token?grant_type=password' \\js: {language: 'js',code: `-let { user, error } = await supabase.auth.signInWithPassword({+let { data, error } = await supabase.auth.signInWithPassword({email: '[email protected]',password: '${randomPassword}'})@@ -534,7 +534,7 @@ curl -X POST '${endpoint}/auth/v1/magiclink' \\js: {language: 'js',code: `-let { user, error } = await supabase.auth.signInWithOtp({+let { data, error } = await supabase.auth.signInWithOtp({email: '[email protected]'})`,@@ -557,7 +557,7 @@ curl -X POST '${endpoint}/auth/v1/signup' \\js: {language: 'js',code: `-let { user, error } = await supabase.auth.signUp({+let { data, error } = await supabase.auth.signUp({phone: '+13334445555',password: 'some-password'})@@ -580,7 +580,7 @@ curl -X POST '${endpoint}/auth/v1/otp' \\js: {language: 'js',code: `-let { user, error } = await supabase.auth.signInWithOtp({+let { data, error } = await supabase.auth.signInWithOtp({phone: '+13334445555'})`,@@ -604,7 +604,7 @@ curl -X POST '${endpoint}/auth/v1/verify' \\js: {language: 'js',code: `-let { session, error } = await supabase.auth.verifyOTP({+let { data, error } = await supabase.auth.verifyOTP({phone: '+13334445555',token: '123456'})@@ -641,7 +641,7 @@ let { data, error } = await supabase.auth.api.inviteUserByEmail('[email protected]js: {language: 'js',code: `-let { user, error } = await supabase.auth.signInWithOAuth({+let { data, error } = await supabase.auth.signInWithOAuth({provider: 'github'})`,@@ -660,7 +660,7 @@ curl -X GET '${endpoint}/auth/v1/user' \\js: {language: 'js',code: `-const user = supabase.auth.user()+const { data: { user } } = await supabase.auth.getUser()`,},}),@@ -705,7 +705,7 @@ let { data, error } = await supabase.auth.api.resetPasswordForEmail(email)js: {language: 'js',code: `-const { user, error } = await supabase.auth.update({+const { data, error } = await supabase.auth.updateUser({email: "[email protected]",password: "new-password",data: { hello: 'world' }