I'm using the regular FF UI CRUD for Supabase and I'm running into RLS issues that seem to be JWT related...
I just want to insert a row into a table if the user is authenticated. Seems pretty simple. Here is the policy I created:
CREATE POLICY "Allow insert for authenticated users"
ON public.tenants
FOR INSERT
WITH CHECK (current_setting('jwt.claims.role') = 'authenticated');
I'm not worried about matching the UUID as it's for a new tenant insert at signup but this should allow any authenticated user to insert into this table but I can't get it working.
Any tips would be greatly appreciated!