RBAC: roles and permissions
Start with the model overview.
Use from JavaScript
Section titled “Use from JavaScript”See Use from JavaScript.
Before you start
Section titled “Before you start”See Before you start.
Identity
Section titled “Identity”See Identity.
Plain Postgres
Section titled “Plain Postgres”See Plain Postgres.
Supabase and PostgREST
Section titled “Supabase and PostgREST”Subject type
Section titled “Subject type”See Subject type.
The type of current_subject_id()
Section titled “The type of current_subject_id()”See The type of current_subject_id().
Privileges
Section titled “Privileges”See Privileges.
Create roles
Section titled “Create roles”See Create roles.
Scenario 1: app-wide roles
Section titled “Scenario 1: app-wide roles”See Scenario 1: app-wide roles.
Scenario 2: roles scoped to a tenant
Section titled “Scenario 2: roles scoped to a tenant”See Scenario 2: roles scoped to a tenant.
See Rules.
Change and remove roles
Section titled “Change and remove roles”Errors
Section titled “Errors”See Errors.
Clean up with delete_subject
Section titled “Clean up with delete_subject”See Clean up with delete_subject.
Warnings and limits
Section titled “Warnings and limits”See Warnings and limits.