ยฉ 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
SupabaseS
Supabaseโ€ข4y agoโ€ข
9 replies
thestepafter

Securing access to database functions only

I am considering only having database functions in the public schema to ensure that the frontend application we are building receives very specific data already formatted as JSON. My hope is to prevent any direct table access through the API which reduces the number of decisions my frontend team needs to make. This should also prevent n+1 queries and any other performance issues that may happen when calling the API using JS. My question is, if I provide access using RLS to the underlying tables in a different schema to my users with the idea that they will only access the data using the database functions, is it possible for those users to access the direct tables in the non-public tables through the API?
Supabase banner
SupabaseJoin
Supabase gives you the tools, documentation, and community that makes managing databases, authentication, and backend infrastructure a lot less overwhelming.
45,816Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Securing Helper Functions in RPC
SupabaseSSupabase / help-and-questions
4d ago
Database Functions vs Edge Functions
SupabaseSSupabase / help-and-questions
5mo ago
Database Functions - Auth
SupabaseSSupabase / help-and-questions
4y ago
Call Edge Functions from Database Functions
SupabaseSSupabase / help-and-questions
7mo ago