Claude Code skills for comprehensive Supabase API operations
npx skills add https://github.com/nice-wolf-studio/claude-code-supabase-skills --skill supabase-storageCLI を使用してこのスキルをインストールし、ワークスペースで SKILL.md ワークフローの使用を開始します。
Comprehensive Claude Code skills that wrap the Supabase API for database operations, authentication, storage, realtime subscriptions, and edge functions.
git clone https://github.com/Nice-Wolf-Studio/claude-code-supabase-skills.git
cd claude-code-supabase-skills
Export your Supabase credentials:
export SUPABASE_URL="https://your-project.supabase.co"
export SUPABASE_KEY="your-anon-or-service-role-key"
Permanent setup (add to ~/.zshrc or ~/.bashrc):
echo 'export SUPABASE_URL="https://your-project.supabase.co"' >> ~/.zshrc
echo 'export SUPABASE_KEY="your-anon-or-service-role-key"' >> ~/.zshrc
source ~/.zshrc
Skills are automatically available in Claude Code when this repository is in your workspace. Alternatively, you can:
Option A: Link to global skills directory
# Create skills directory if it doesn't exist
mkdir -p ~/.claude/skills
# Link individual skills
ln -s "$(pwd)/skills/supabase-database" ~/.claude/skills/
ln -s "$(pwd)/skills/supabase-auth" ~/.claude/skills/
ln -s "$(pwd)/skills/supabase-storage" ~/.claude/skills/
ln -s "$(pwd)/skills/supabase-realtime" ~/.claude/skills/
ln -s "$(pwd)/skills/supabase-edge-functions" ~/.claude/skills/
Option B: Use skills from this repository directly
Just reference the skills when working in Claude Code - they'll be available when this project is your working directory.
Database operations using the Supabase REST API.
Common operations:
Usage in Claude Code:
Use the supabase-database skill to query my users table
Authentication and user management.
Common operations:
Usage in Claude Code:
Use the supabase-auth skill to create a new user account
File storage operations.
Common operations:
Usage in Claude Code:
Use the supabase-storage skill to upload a file to my avatars bucket
Realtime WebSocket subscriptions.
Common operations:
Usage in Claude Code:
Use the supabase-realtime skill to listen for changes on my posts table
Serverless edge functions deployment and invocation.
Common operations:
Usage in Claude Code:
Use the supabase-edge-functions skill to invoke my process-payment function
source scripts/supabase-api.sh
# Get all users
supabase_get "/rest/v1/users?select=*"
# Get users with filter
supabase_get "/rest/v1/users?select=*&age=gt.18&order=created_at.desc"
source scripts/supabase-api.sh
# Sign up new user
supabase_post "/auth/v1/signup" '{
"email": "[email protected]",
"password": "secure_password"
}'
BUCKET_NAME="avatars"
FILE_PATH="/path/to/image.jpg"
STORAGE_PATH="user-123/avatar.jpg"
curl -X POST \
"${SUPABASE_URL}/storage/v1/object/${BUCKET_NAME}/${STORAGE_PATH}" \
-H "apikey: ${SUPABASE_KEY}" \
-H "Authorization: Bearer ${SUPABASE_KEY}" \
-F "file=@${FILE_PATH}"
source scripts/supabase-api.sh
supabase_post "/functions/v1/hello-world" '{
"name": "Alice"
}'
scripts/supabase-api.sh provides common functions:
supabase_get(endpoint) - GET requestssupabase_post(endpoint, json_data) - POST requestssupabase_patch(endpoint, json_data) - PATCH requestssupabase_delete(endpoint) - DELETE requestsvalidate_env() - Check environment variablessuccess(message), error(message), warning(message) - Formatted outputAll skills source this helper to avoid duplication.
Each skill is organized as:
skills/
└── supabase-{feature}/
└── SKILL.md # Skill documentation with examples
Skills are self-contained and can be used independently.
jq (JSON processor):
# macOS
brew install jq
# Linux
sudo apt-get install jq # Debian/Ubuntu
sudo yum install jq # RHEL/CentOS
Supabase CLI:
# macOS
brew install supabase/tap/supabase
# Linux
curl -fsSL https://github.com/supabase/cli/releases/latest/download/supabase_linux_amd64.tar.gz | tar -xz
sudo mv supabase /usr/local/bin/
websocat (WebSocket client):
# macOS
brew install websocat
# Linux
wget https://github.com/vi/websocat/releases/download/v1.12.0/websocat.x86_64-unknown-linux-musl
chmod +x websocat.x86_64-unknown-linux-musl
sudo mv websocat.x86_64-unknown-linux-musl /usr/local/bin/websocat
Anon Key (public):
Service Role Key (secret):
Error: SUPABASE_URL environment variable is not set
Solution: Export your environment variables (see Installation step 2)
Error: HTTP 401
Solution: Check that your SUPABASE_KEY is valid and has necessary permissions
Error: HTTP 413 Payload too large
Solution: Check bucket file size limits in Supabase dashboard
Error: HTTP 504 Gateway timeout
Solution: Edge functions have 150s wall clock limit. Optimize function or break into smaller operations.
Contributions welcome! Please:
MIT License - See LICENSE file for details
For issues and questions:
Created for Claude Code - Comprehensive Supabase API wrapper skills