What problem does it solve?
This Skill ensures secure and correct data access in the Chravel application by auditing and implementing robust Supabase Row-Level Security (RLS) policies, managing edge functions, and integrating with Supabase authentication. It prevents unauthorized data access and ensures data integrity.
Core Features & Use Cases
- RLS Policy Implementation: Define and enforce granular access controls for database tables based on user roles and trip memberships.
- Edge Function Security: Secure server-side operations by validating authentication tokens and applying business logic.
- Auth Integration: Ensure all data fetching respects Supabase's authentication model, using
auth.uid() as the sole source of truth for user identity.
- Use Case: When a new feature requires users to interact with trip-specific data, this Skill can be used to audit and implement the necessary RLS policies to ensure only authorized members can view, edit, or delete trip items.
Quick Start
Audit the RLS policies for the 'trip_items' table to ensure only trip members can select, insert, update, or delete records.