Supabase - best setup for admin

Hi! I have auth successfully setup via supabase, but, once we go live and my users set their own passwords, I am wondering the best route to be able to log-in as them or at least mimic what they see for testing/verification?

I am aware of how to setup user roles, but once I setup myself as an admin, I do not quite understand the steps to take to be able to use that role to mimic other users’ experiences - many tables /views are filtered by their user id / company, etc.

thank you for the help!

It’s called impersonation in Supabase, in WeWeb this is kinda hard, you’d probably need to mock the requests somehow.

1 Like

thank you for the response! since impersonation it is difficult in WeWeb, I’m curious is there a typical best practice in WeWeb which admins usually setup? (which doesn’t achieve impersonation, but still helps)

I never seen this pattern of taking over a user honestly. You can do this in Supabase with impersonation. What is exactly your usecase in WeWeb for this?

Right, i’m saying ignoring impersonation/taking over - is there a best-practice setup for an admin in weweb for a typical app? want to make sure i don’t go live with users without thinking of something critical

You’re asking us such a broad question that it’s impossible to answer. What does that even mean. “Best practice setup for an admin”.

It simply means, if you setup an app with users on WeWeb, let’s say it’s a To-Do app where users login, and only the user can see their data in the app - do you add an admin role, and if so, what type of setup do you do / anything to make sure to prep for.

It’s broad on purpose, because, like i mentioned, want to make sure there is nothing critical I am not thinking of something - if I thought of it, then could be specific and would not be an issue :grin: