Supabase
Connecting Supabase unlocks everything beyond a static frontend — a database, user authentication, integrations like Stripe and OpenAI, and secure storage for API keys. Devaiy uses YOUR Supabase project, on YOUR account.
What Supabase gives your app
- Postgres database — tables that the AI creates and queries for any feature that needs to persist data (user profiles, posts, todos, orders, etc.)
- Authentication — sign-up / sign-in flows for your end users. See Authentication for details.
- Edge Functions — serverless functions that run on Supabase’s infrastructure. We deploy one per integration (e.g.,
openai-chatwhen you connect OpenAI). Your app calls these functions instead of holding API keys on the frontend. - Vault — encrypted storage for your API keys (Stripe secret, OpenAI key, etc.). The keys are accessible only inside Supabase Edge Functions, not to the browser.
How to connect
From your project’s Settings → Integrations tab, click Connect with Supabase. You’ll be redirected to Supabase’s OAuth consent screen. After authorizing, you’ll see your Supabase organizations and projects.
You can either:
- Connect an existing Supabase project — pick one from your list. A small heads-up: on connect, Devaiy adds a few authentication-related config tables that your app relies on, so it’s best to use a project that isn’t already powering another live app.
- Create a new Supabase project — Devaiy can provision one inside an organization you choose. Takes ~30 seconds. This is the simplest path if you’re starting fresh.
Either way, the connection takes about 2 minutes end to end.
What gets created in your Supabase
- Tables — only as the AI builds features that need them. You can see and edit them in the Supabase dashboard at any time.
- Edge Functions — one per integration you connect through Devaiy. For example, connecting Stripe deploys
stripe-checkoutandstripe-webhook. Connecting OpenAI deploys five functions for chat, image, speech, transcription, and moderation. - Vault secrets — your API keys go here, encrypted at rest. The Edge Functions read them at runtime; nothing on the frontend ever sees them.
What Devaiy does NOT have access to
- Your data. Everything your app stores lives in your Supabase project. We don’t replicate it, mirror it, or read it.
- Your Supabase credentials are stored encrypted. They’re never shared with third parties or exposed to your app’s frontend.
Disconnecting
Disconnect from Settings → Integrations → Disconnect Supabase. When you disconnect:
- The integration record on Devaiy is marked inactive.
- Your data stays — the tables and rows in your Supabase project are untouched.
- Your app’s database calls will start failing until you reconnect.
If you have Stripe, OpenAI, or any other integration connected, click their individual Disconnect buttons before disconnecting Supabase — this will delete the edge functions and secrets associated with those integrations.
You can reconnect at any time. If you reconnect to the same Supabase project, everything just resumes working.
One Devaiy app per Supabase project
Each Devaiy app needs its own Supabase project. There are two reasons for this: on connect, Devaiy adds a small set of authentication config tables that two Devaiy apps would end up fighting over, and more broadly, two apps sharing the same Supabase would likely clash on table names too (both apps creating a posts or users table in the same schema would collide). Keeping one app per Supabase project sidesteps both issues.
Single environment per project
The Supabase project you connect powers both your in-app previews and your deployed production app — Devaiy doesn’t support a separate dev and prod Supabase today. There’s no built-in way to clone schema, edge functions, Vault secrets, and integration configuration into a second Supabase project, so plan accordingly: connect a Supabase project you’re comfortable using as your production backend, and consider any data the AI generates while building (test users, sample rows) as “live” once you deploy.
Troubleshooting
- OAuth fails or returns an error? Make sure you’re signed into the correct Google/email account for Supabase in your browser before clicking Connect.
- Don’t see your existing Supabase project? Make sure the organization is one you have access to. Personal projects under a different email won’t appear.
- Want to switch which Supabase project a Devaiy project uses? Disconnect first, then reconnect and pick a different one. Safe to do early on, but not advisable once the AI has built tables — it’s risky and effectively destructive. The new Supabase won’t have those tables, while Devaiy and the AI still expect them to exist, so your app will break until things are rebuilt.
