Anonymous Sign In With Supabase

Actions & Logic

Hi, I'm trying to create a custom action to use supabase to create an anonymous user to get their access token to then use to make requests to an edge function. But it's saying that the signInAnonymously isn't a method for GoTrueClient even though it is in the flutter docs.

What have you tried so far?

I've looked at the wrapper function for supabase in the backend/supabase.dart and wrote this as my custom action

void anonSignIn() async {
  await SupaFlow.initialize();
  final supabase = SupaFlow.client;
  await supabase.auth.signInAnonymously();
}

But it says that the method doesn't exist. I've confirmed that supabase.auth is returning a GoTrueClient and the docs say that GoTrueClient has the method. So how do I login anonymously??? I can't do it in a new edge function because the edge function in supabase would require a JWT which is what I'm trying to get by anon sign in.

Did you check FlutterFlow's Documentation for this topic?
Yes
4
2 replies