1.5 KiB
1.5 KiB
Supabase MCP OAuth Setup
OAuth Callback Routes erstellt
Ich habe die notwendigen OAuth Routes für den MCP Server erstellt:
📁 Neue Dateien:
/app/oauth/consent/route.ts- OAuth Callback Handler/app/oauth/consent/page.tsx- Consent UI/app/oauth/success/page.tsx- Success Seite/app/oauth/error/page.tsx- Error Seite
🔧 Was diese Routes tun:
1. OAuth Callback (/oauth/consent)
- Empfängt den Authorization Code von Supabase
- Tauscht Code gegen Access Tokens
- Leitet auf Success/Error weiter
2. Consent UI (/oauth/consent)
- Zeigt den OAuth-Flow Status
- Bestätigt die MCP Konfiguration
- Leitet zurück zur App
3. Success/Error Pages
- Erfolgsmeldung bei erfolgreicher Konfiguration
- Fehlermeldung bei Problemen
- Navigation zurück zur App
🎯 Nächste Schritte:
-
Supabase OAuth App erstellen:
- Gehe zu: https://supabase.com/dashboard/project/ekbpexbhuochrplzorce/authentication/oauth-apps
- Erstelle neue OAuth App
- Redirect URL:
http://localhost:3000/oauth/consent
-
MCP Konfiguration aktualisieren:
- Client ID und Secret eintragen
- OAuth Callback URL verwenden
-
Testen:
- MCP Server sollte sich verbinden können
- Automatische Datenbank-Verwaltung möglich
🔐 Sicherheit:
- OAuth 2.1 statt Service Keys
- Scoped Permissions
- Row Level Security respektiert
- Development Branch sicher
Nach der OAuth App Erstellung im Supabase Dashboard sollte der MCP Server voll funktionsfähig sein!