Toolverse
All skills

supabase-rls-policy-generator

by hopeoverture

This skill should be used when the user requests to generate, create, or add Row-Level Security (RLS) policies for Supabase databases in multi-tenant or role-based applications. It generates comprehensive RLS policies using auth.uid(), auth.jwt() claims, and role-based access

Installation

Pick a client and clone the repository into its skills directory.

Installation

Quick info

Category
Backend
Views
102

About this skill

This skill should be used when the user requests to generate, create, or add Row-Level Security (RLS) policies for Supabase databases in multi-tenant or role-based applications. It generates comprehensive RLS policies using auth.uid(), auth.jwt() claims, and role-based access patterns. Trigger terms include RLS, row level security, supabase security, generate policies, auth policies, multi-tenant security, role-based access, database security policies, supabase permissions, tenant isolation.

How to use

  1. Przygotuj schemat bazy danych — zbierz ścieżkę do pliku schematu lub listę nazw tabel, które wymagają ochrony RLS. Narzędzie przeanalizuje strukturę tabel, klucze obce i relacje między nimi.

  2. Zdefiniuj model bezpieczeństwa — określ, czy aplikacja jest wielodostępowa (izolacja tenant_id), oparta na rolach (admin, użytkownik, widz) czy hybrydowa. Wskaż, czy istnieją zasoby publiczne i prywatne, czy użytkownicy mogą udostępniać zasoby między kontami, oraz czy występują hierarchiczne uprawnienia (organizacja > zespół > użytkownik).

  3. Zidentyfikuj wymagania dostępu — określ, jakie operacje (SELECT, INSERT, UPDATE, DELETE) każda rola powinna móc wykonywać. Narzędzie będzie generować odpowiednie polityki dla każdego typu dostępu.

  4. Wygeneruj polityki RLS — narzędzie utworzy polityki SELECT (kontrola odczytu), INSERT (kontrola tworzenia), UPDATE (kontrola edycji) i DELETE (kontrola usuwania) dla każdej tabeli. Każda polityka będzie wykorzystywać auth.uid() do identyfikacji użytkownika i auth.jwt() do weryfikacji roli.

  5. Przejrzyj i dostosuj wygenerowany kod SQL — sprawdź wygenerowane instrukcje ALTER TABLE i polityki. Możesz je modyfikować w zależności od specyficznych wymagań aplikacji przed wdrożeniem w bazie danych.

  6. Wdróż polityki w Supabase — zastosuj wygenerowany kod SQL w konsoli Supabase lub za pośrednictwem migracji bazy danych, aby aktywować RLS i zastosować polityki bezpieczeństwa.

Related skills

supabase-developer

by daffy0208

Build full-stack applications with Supabase (PostgreSQL, Auth, Storage, Real-time, Edge Functions). Use when implementing authentication, database design with RLS, file storage, real-time features, or serverless functions.

Backend
78170

youtube-transcript

by michalparkola

Download YouTube video transcripts when user provides a YouTube URL or asks to download/get/fetch a transcript from YouTube. Also use when user wants to transcribe or get captions/subtitles from a YouTube video.

Backend
53214

literature-review

by K-Dense-AI

Conduct comprehensive, systematic literature reviews using multiple academic databases (PubMed, arXiv, bioRxiv, Semantic Scholar, etc.). This skill should be used when conducting systematic literature reviews, meta-analyses, research synthesis, or comprehensive literature

Backend
238507

api-design-principles

by wshobson

Master REST and GraphQL API design principles to build intuitive, scalable, and maintainable APIs that delight developers. Use when designing new APIs, reviewing API specifications, or establishing API design standards.

Backend
50146

travel-planner

by ailabs-393

This skill should be used whenever users need help planning trips, creating travel itineraries, managing travel budgets, or seeking destination advice. On first use, collects comprehensive travel preferences including budget level, travel style, interests, and dietary

Backend
4379

youtube-transcribe-skill

by feiskyer

Extract subtitles/transcripts from a YouTube video URL and save as a local file. Use when you need to extract subtitles from a YouTube video.

Backend
24178