This covers OAuth setup for Google, GitHub, Apple, X, and custom providers, plus JWT lifetime tuning and post-login hooks. You get two tools: manage_oauth for provider config and manage_auth_config for everything else. The role model is clean: anonymous, end-user JWT, or service key, each with different RLS behavior. Auth hooks are fire-and-forget functions that run after login, useful for creating profile rows or sending welcome emails but not for returning data to users. Service keys bypass RLS entirely, so the usual warnings apply. The redirect URI format is strict and provider quirks are documented, which saves time when Apple only returns names once or X refuses to give you emails.

GitHub stars
532
last updated
Jun 11, 2026

Install

$ npx -y skills add butterbase-ai/butterbase-skills --skill auth-setup --agent claude-code

Installs into .claude/skills of the current project.

Files

Butterbase Auth Setup

Two umbrella tools cover end-user authentication:

  • manage_oauth — provider configuration (Google, GitHub, Apple, X, custom)
  • manage_auth_config — auth hooks, JWT lifetimes, service key generation

For broad app build-out, see also butterbase-skills:build-app. This skill is the deep dive.


1. The role model

Every request runs under one of three database roles:

Auth headerRolecurrent_user_id()RLS
nonebutterbase_anonNULLenforced; default deny
End-user JWT (issued by manage_oauth or email login)butterbase_useruser UUIDenforced
Service key (bb_sk_*)butterbase_serviceNULLbypassed

Auth is what transforms a request into the right role. RLS is what filters the data. Both must be configured.


2. Configure an OAuth provider

Sponsors

Details

Repository
github.com/butterbase-ai/butterbase-skills
Categories
Frontend Development, Backend & APIs, Security, Git & Pull Requests, Rust
License
MIT
First seen
Jun 11, 2026

More from butterbase-ai/butterbase-skills

All 39
1butterbase-ai avatardebug-rlsbutterbase-ai/butterbase-skillsWhen your frontend users complain they can't see their data or they're seeing everyone else's data, this is the protocol to follow.0skills.sh installs
2butterbase-ai avatarjourney-deploybutterbase-ai/butterbase-skillsUse as the deploy-verification stage of the Butterbase journey, after journey-frontend (or after any build stage if there is no frontend). Smoke-tests the deplo0skills.sh installs
3butterbase-ai avatarjourney-planbutterbase-ai/butterbase-skillsUse as stage 2 of the Butterbase journey, after journey-idea has written 01-idea.md. Translates the idea + capability map into a concrete Butterbase plan — tabl0skills.sh installs
4butterbase-ai avatarjourney-storagebutterbase-ai/butterbase-skillsUse as the storage build stage of the Butterbase journey. Implements the Storage section of 02-plan.md by delegating to the storage skill. Calls manage_storage 0skills.sh installs
5composiohq avatartheme-factorycomposiohq/awesome-claude-pluginsToolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with colors/fo0skills.sh installs
6daffy0208 avatarFigma Developerdaffy0208/ai-dev-standardsExtract components from Figma, convert designs to React components, sync design tokens, and generate code from designs. Bridge the gap between design and code w0skills.sh installs