Merge branch 'chore/decouple-editor-panel' into feature/database-tests

This commit is contained in:
Saxon Fletcher committed 2025-08-06 14:09:36 +10:00
commit b5b13853b2
336 files changed
+70398 -58326

No files matched your search

+3
View File
@@ -14,6 +14,9 @@ concurrency:
permissions:
contents: read
env:
CI: true
jobs:
build:
runs-on: ubuntu-latest
+8
View File
@@ -5,6 +5,7 @@ import { NextResponse } from 'next/server'
import { z } from 'zod'
import { ApiError, convertZodToInvalidRequestError, InvalidRequestError } from '~/app/api/utils'
import { BASE_PATH, IS_DEV } from '~/lib/constants'
import { sendToLogflare, LOGGING_CODES } from '~/lib/logger'
import { rootGraphQLSchema } from '~/resources/rootSchema'
import { createQueryDepthLimiter } from './validators'
@@ -154,6 +155,13 @@ export async function OPTIONS(request: Request): Promise<NextResponse> {
export async function POST(request: Request): Promise<NextResponse> {
try {
const vercelId = request.headers.get('x-vercel-id')
sendToLogflare(LOGGING_CODES.CONTENT_API_REQUEST_RECEIVED, {
vercelId,
origin: request.headers.get('Origin'),
userAgent: request.headers.get('User-Agent'),
})
const result = await handleGraphQLRequest(request)
// Do not let Vercel close the process until Sentry has flushed
// https://github.com/getsentry/sentry-javascript/issues/9626
@@ -2181,6 +2181,10 @@ export const platform: NavMenuConstant = {
name: 'Transfer Project',
url: '/guides/platform/project-transfer',
},
{
name: 'Duplicate Project',
url: '/guides/platform/clone-project',
},
{
name: 'Single Sign-On',
url: '/guides/platform/sso',
@@ -12,5 +12,5 @@ Your database will be available in less than a minute.
You can find your project credentials on the dashboard:
- [Database connection strings](https://supabase.com/dashboard/project/_/settings/api?showConnect=true): Direct and Pooler connection details including the connection string and parameters.
- [Database password](https://supabase.com/dashboard/project/_/settings/database): Reset database password here if you do not have it.
- [Database password](https://supabase.com/dashboard/project/_/database/settings): Reset database password here if you do not have it.
- [API credentials](https://supabase.com/dashboard/project/_/settings/api): your serverless API URL and `anon` / `service_role` keys.
@@ -54,6 +54,28 @@
}
```
Or, if using `pnpm` instead of `npm`
```json
{
"mcpServers": {
"supabase": {
"command": "cmd",
"args": [
"/c",
"pnpm",
"dlx",
"@supabase/mcp-server-supabase@latest",
"--read-only",
"--project-ref=<project-ref>"
],
"env": {
"SUPABASE_ACCESS_TOKEN": "<personal-access-token>"
}
}
}
}
```
Replace `<project-ref>` with your project ref, and `<personal-access-token>` with your personal access token.
<Admonition type="note">
@@ -11,7 +11,7 @@ For data science or ephemeral workloads, the [Supabase Vecs](https://supabase.gi
<Admonition type="tip">
You can get your connection string from the [**Database Settings**](https://supabase.com/dashboard/project/_/settings/database) page in your dashboard. Make sure to check **Use connection pooling**, then copy the URI. Also, change the URI scheme from `postgres` to `postgresql`. `vecs` uses SQLAlchemy under the hood, which only supports `postgresql` as a dialect.
You can get your connection string from the [**Database Settings**](https://supabase.com/dashboard/project/_/database/settings) page in your dashboard. Make sure to check **Use connection pooling**, then copy the URI. Also, change the URI scheme from `postgres` to `postgresql`. `vecs` uses SQLAlchemy under the hood, which only supports `postgresql` as a dialect.
</Admonition>
@@ -189,7 +189,7 @@ Since we're managing users and authentication outside of Supabase, we have two o
#### Direct Postgres connection
You can directly connect to your Supabase Postgres DB using the [connection info](/dashboard/project/_/settings/database) on your project's database settings page. To use RLS with this method, we use a custom session variable that contains the current user's ID:
You can directly connect to your Supabase Postgres DB using the [connection info](/dashboard/project/_/database/settings) on your project's Database Settings page. To use RLS with this method, we use a custom session variable that contains the current user's ID:
```sql
-- enable row level security
@@ -24,7 +24,7 @@ Magic Links are a form of passwordless login where users click on a link sent to
Email authentication methods, including Magic Links, are enabled by default.
Configure the Site URL and any additional redirect URLs. These are the only URLs that are allowed as redirect destinations after the user clicks a Magic Link. You can change the URLs on the [Auth Providers page](/dashboard/project/_/auth/providers) for hosted projects, or in the [configuration file](/docs/guides/cli/config#auth.additional_redirect_urls) for self-hosted projects.
Configure the Site URL and any additional redirect URLs. These are the only URLs that are allowed as redirect destinations after the user clicks a Magic Link. You can change the URLs on the [URL Configuration page](/dashboard/project/_/auth/url-configuration) for hosted projects, or in the [configuration file](/docs/guides/cli/config#auth.additional_redirect_urls) for self-hosted projects.
By default, a user can only request a magic link once every <SharedData data="config">auth.rate_limits.magic_link.period</SharedData> and they expire after <SharedData data="config">auth.rate_limits.magic_link.validity</SharedData>.
@@ -37,7 +37,6 @@ hideToc: true
```bash name=Terminal
npm create vite@latest my-app -- --template react
```
</StepHikeCompact.Code>
@@ -65,14 +64,14 @@ hideToc: true
<StepHikeCompact.Step step={4}>
<StepHikeCompact.Details title="Set up your login component">
In `App.js`, create a Supabase client using your [Project URL and public API (anon) key](https://supabase.com/dashboard/project/_/settings/api).
In `App.jsx`, create a Supabase client using your [Project URL and public API (anon) key](https://supabase.com/dashboard/project/_/settings/api).
You can configure the Auth component to display whenever there is no session inside `supabase.auth.getSession()`
</StepHikeCompact.Details>
<StepHikeCompact.Code>
```js name=src/App.js
```jsx name=src/App.jsx
import './index.css'
import { useState, useEffect } from 'react'
import { createClient } from '@supabase/supabase-js'
@@ -121,7 +120,7 @@ hideToc: true
<StepHikeCompact.Code>
```bash name=Terminal
npm start
npm run dev
```
</StepHikeCompact.Code>
@@ -171,7 +171,7 @@ If you wish to make your own JWTs or have access to the private key or shared se
Use the [Supabase CLI](/docs/reference/cli/introduction) to quickly and securely generate a private key ready for import:
```sh
supabase gen generate-key ES256
supabase gen signing-key --algorithm ES256
```
Make sure you store this private key in a secure location, as it will not be extractable from Supabase.
@@ -712,7 +712,7 @@ val supabaseClient = createSupabaseClient(
**Use the Compose Auth plugin in your Auth Screen**
```kotlin
val authState = supabaseClient.composeAuth.rememberLoginWithGoogle(
val authState = supabaseClient.composeAuth.rememberSignInWithGoogle(
onResult = {
when(it) { //handle errors
NativeSignInResult.ClosedByUser -> TODO()
@@ -27,13 +27,6 @@ Attempting to create a second Job with the same name (and case) will overwrite t
4. Choose a schedule for your Job by inputting cron syntax (refer to the syntax chart in the form) or natural language.
5. Input SQL snippet or select a Database function, HTTP request, or Supabase Edge Function.
<Image
alt="Cron Create"
src="/docs/img/guides/database/cron/cron-create.png"
className="max-w-[700px] !mx-auto border rounded-md"
zoomable
/>
</TabPanel>
<TabPanel id="sql-schedule-job" label="SQL">
@@ -99,13 +92,6 @@ You can input seconds for your Job schedule interval as long as you're on Postgr
2. Click on the three vertical dots menu on the right side of the Job and click `Edit cron job`.
3. Make your changes and then click `Save cron job`.
<Image
alt="Cron Edit"
src="/docs/img/guides/database/cron/cron-edit.png"
className="max-w-[700px] !mx-auto border rounded-md"
zoomable
/>
</TabPanel>
<TabPanel id="sql-edit-job" label="SQL">
@@ -148,13 +134,6 @@ It is also possible to modify a job by using the `cron.schedule()` function by i
1. Go to the [Jobs](/dashboard/project/_/integrations/cron/jobs) section and find the Job you'd like to unschedule.
2. Toggle the `Active`/`Inactive` switch next to Job name.
<Image
alt="Cron Toggle"
src="/docs/img/guides/database/cron/cron-toggle.png"
className="max-w-[700px] !mx-auto border rounded-md"
zoomable
/>
</TabPanel>
<TabPanel id="sql-unschedule-job" label="SQL">
@@ -190,13 +169,6 @@ select cron.alter_job(
2. Click on the three vertical dots menu on the right side of the Job and click `Delete cron job`.
3. Confirm deletion by entering the Job name.
<Image
alt="Cron Unschedule"
src="/docs/img/guides/database/cron/cron-unschedule.png"
className="max-w-[700px] !mx-auto border rounded-md"
zoomable
/>
</TabPanel>
<TabPanel id="sql-delete-job" label="SQL">
@@ -227,13 +199,6 @@ Unscheduling a Job will permanently delete the Job from `cron.job` table but its
1. Go to the [Jobs](/dashboard/project/_/integrations/cron/jobs) section and find the Job you want to see the runs of.
2. Click on the `History` button next to the Job name.
<Image
alt="Cron Job Runs"
src="/docs/img/guides/database/cron/cron-history.png"
className="max-w-[700px] !mx-auto border rounded-md"
zoomable
/>
</TabPanel>
<TabPanel id="sql-runs-job" label="SQL">
@@ -28,7 +28,7 @@ hideToc: true
<StepHikeCompact.Details title="Get your connection credentials">
Get your connection credentials from the [`Database Settings`](https://supabase.com/dashboard/project/_/settings/database). You will need:
Get your connection credentials from the [`Database Settings`](https://supabase.com/dashboard/project/_/database/settings). You will need:
- host
- username
- password
@@ -50,7 +50,7 @@ hideToc: true
<StepHikeCompact.Details title="Download your SSL Certificate">
Download your SSL certificate from the Dashboard's [`Database Settings`](https://supabase.com/dashboard/project/_/settings/database)
Download your SSL certificate from the Dashboard's [`Database Settings`](https://supabase.com/dashboard/project/_/database/settings)
![SSL](/docs/img/guides/database/connecting-to-postgres/beekeeper-studio/certificate.png)
</StepHikeCompact.Details>
@@ -64,7 +64,7 @@ Choose one of these Vercel Deploy Templates which use our [Vercel Deploy Integra
### Manual configuration
In your [`Database Settings`](https://supabase.com/dashboard/project/_/settings/database), make sure `Use connection pooler` is checked and `Transaction` mode is selected, then copy the URI and save it as the `POSTGRES_URL` environment variable. Remember to replace the password placeholder with your actual database password and add the following suffix `?workaround=supabase-pooler.vercel`.
In your [`Database Settings`](https://supabase.com/dashboard/project/_/database/settings), make sure `Use connection pooler` is checked and `Transaction` mode is selected, then copy the URI and save it as the `POSTGRES_URL` environment variable. Remember to replace the password placeholder with your actual database password and add the following suffix `?workaround=supabase-pooler.vercel`.
```txt .env.local
POSTGRES_URL="postgres://postgres.cfcxynqnhdybqtbhjemm:[YOUR-PASSWORD]@aws-0-ap-southeast-1.pooler.supabase.com:6543/postgres?workaround=supabase-pooler.vercel"
@@ -11,7 +11,7 @@ Every [Compute Add-On](/docs/guides/platform/compute-add-ons) has a pre-configur
### Configuring Supavisor's pool size
You can change how many database connections Supavisor can manage by altering the pool size in the "Connection pooling configuration" section of the [Database Settings](/dashboard/project/_/settings/database):
You can change how many database connections Supavisor can manage by altering the pool size in the "Connection pooling configuration" section of the [Database Settings](/dashboard/project/_/database/settings):
![Connection Info and Certificate.](/docs/img/database/pool-size.png)
@@ -64,7 +64,7 @@ If you do not have DBeaver, you can download it from its [website](https://dbeav
<StepHikeCompact.Step step={5}>
<StepHikeCompact.Details title="Download certificate">
In the [Database Settings](https://supabase.com/dashboard/project/_/settings/database), download your SSL certificate.
In the [Database Settings](https://supabase.com/dashboard/project/_/database/settings), download your SSL certificate.
</StepHikeCompact.Details>
<StepHikeCompact.Code>
@@ -66,7 +66,7 @@ If you plan on solely using Drizzle instead of the Supabase Data API (PostgREST)
Connect to your database using the Connection Pooler.
In your [`Database Settings`](https://supabase.com/dashboard/project/_/settings/database), make sure `Use connection pooler` is checked, then copy the URI and save it as the `DATABASE_URL` environment variable. Remember to replace the password placeholder with your actual database password.
In your [`Database Settings`](https://supabase.com/dashboard/project/_/database/settings), make sure `Use connection pooler` is checked, then copy the URI and save it as the `DATABASE_URL` environment variable. Remember to replace the password placeholder with your actual database password.
</StepHikeCompact.Details>
@@ -98,7 +98,7 @@ By default, Supabase enforces query statement timeouts to ensure fair resource a
### 3. Estimate your required disk size
Large datasets consume disk space. Ensure your Supabase project has sufficient disk capacity to accommodate the imported data. If you know how big your database is going to be, you can manually increase the size in your [projects database settings](/dashboard/project/_/settings/database).
Large datasets consume disk space. Ensure your Supabase project has sufficient disk capacity to accommodate the imported data. If you know how big your database is going to be, you can manually increase the size in your [projects database settings](/dashboard/project/_/database/settings).
Read more about [disk management](/docs/guides/platform/database-size#disk-management).
@@ -72,7 +72,7 @@ hideToc: true
<StepHikeCompact.Details title="SSL">
Download your SSL certificate from Dashboard's [`Database Settings`](https://supabase.com/dashboard/project/_/settings/database).
Download your SSL certificate from Dashboard's [`Database Settings`](https://supabase.com/dashboard/project/_/database/settings).
In pgAdmin, navigate to the Parameters tab and select connection parameter as Root Certificate. Next navigate to the Root certificate input, it will open up a file-picker modal. Select the certificate you downloaded earlier and save the server details. pgAdmin should now be able to connect to your Postgres via SSL.
@@ -36,7 +36,7 @@ hideToc: true
Create a `db.js` file with the connection details.
To get your connection details, go to your [`Database Settings`](https://supabase.com/dashboard/project/_/settings/database). Make sure `Use connection pooling` is enabled. Choose `Transaction Mode` if you're on a platform with transient connections, such as a serverless function, and `Session Mode` if you have a long-lived connection. Copy the URI and save it as the environment variable `DATABASE_URL`.
To get your connection details, go to your [`Database Settings`](https://supabase.com/dashboard/project/_/database/settings). Make sure `Use connection pooling` is enabled. Choose `Transaction Mode` if you're on a platform with transient connections, such as a serverless function, and `Session Mode` if you have a long-lived connection. Copy the URI and save it as the environment variable `DATABASE_URL`.
</StepHikeCompact.Details>
@@ -42,7 +42,7 @@ If you use special symbols in your Postgres password, you must remember to [perc
### Changing your project password
When you created your project you were also asked to enter a password. This is the password for the `postgres` role in your database. You can update this from the Dashboard under the [database settings](https://supabase.com/dashboard/project/_/settings/database) page. You should _never_ give this to third-party service unless you absolutely trust them. Instead, we recommend that you create a new user for every service that you want to give access too. This will also help you with debugging - you can see every query that each role is executing in your database within `pg_stat_statements`.
When you created your project you were also asked to enter a password. This is the password for the `postgres` role in your database. You can update this from the Dashboard under the [Database Settings](https://supabase.com/dashboard/project/_/database/settings) page. You should _never_ give this to third-party service unless you absolutely trust them. Instead, we recommend that you create a new user for every service that you want to give access too. This will also help you with debugging - you can see every query that each role is executing in your database within `pg_stat_statements`.
Changing the password does not result in any downtime. All connected services, such as PostgREST, PgBouncer, and other Supabase managed services, are automatically updated to use the latest password to ensure availability. However, if you have any external services connecting to the Supabase database using hardcoded username/password credentials, a manual update will be required.
@@ -104,7 +104,7 @@ Let's say you have a table called `profiles` in the public schema and you want t
-- 1. Create table
create table profiles (
id uuid primary key,
user_id references auth.users,
user_id uuid references auth.users,
avatar_url text
);
@@ -27,7 +27,7 @@ select pg_create_logical_replication_slot('example_slot', 'pgoutput');
<Admonition type="note">
This will need a **direct** connection (not a Connection Pooler) to your database and you can find the connection info in the [Dashboard](https://supabase.com/dashboard/project/_/settings/database).
This will need a **direct** connection (not a Connection Pooler) to your database and you can find the connection info in the [Dashboard](https://supabase.com/dashboard/project/_/database/settings).
You will also need to ensure that IPv6 is supported by your replication destination (or you can enable the [IPv4 add-on](/docs/guides/platform/ipv4-address))
@@ -79,7 +79,7 @@ Prisma is unable to allocate connections to pending queries fast enough to meet
- **Increase the pool timeout**: Increase the `pool_timeout` parameter in your Prisma configuration to give the pooler more time to allocate connections.
- **Reduce the connection limit**: If you've explicitly increased the `connection_limit` parameter in your Prisma configuration, try reducing it to a more reasonable value.
- **Increase pool size**: If you are connecting with Supavisor, try increasing the pool size in the [Database Settings](https://supabase.com/dashboard/project/_/settings/database).
- **Increase pool size**: If you are connecting with Supavisor, try increasing the pool size in the [Database Settings](https://supabase.com/dashboard/project/_/database/settings).
- **Optimize queries**: [Improve the efficiency of your queries](https://supabase.com/docs/guides/database/query-optimization) to reduce execution time.
- **Increase compute size**: Like the preceding option, this is a strategy to reduce query execution time.
@@ -118,14 +118,14 @@ Postgres or Supavisor rejected a request for more connections
### Possible causes:[#possible-causes-max-client-connections-reached]
- **When working in transaction mode (port 6543):** The error "Max client connections reached" occurs when clients try to form more connections with the pooler than it can support.
- **When working in session mode (port 5432):** The max amount of clients is restricted to the "Pool Size" value in the [Database Settings](https://supabase.com/dashboard/project/_/settings/database). If the "Pool Size" is set to 15, even if the pooler can handle 200 client connections, it will still be effectively capped at 15 for each unique ["database-role+database" combination](https://github.com/orgs/supabase/discussions/21566).
- **When working in session mode (port 5432):** The max amount of clients is restricted to the "Pool Size" value in the [Database Settings](https://supabase.com/dashboard/project/_/database/settings). If the "Pool Size" is set to 15, even if the pooler can handle 200 client connections, it will still be effectively capped at 15 for each unique ["database-role+database" combination](https://github.com/orgs/supabase/discussions/21566).
- **When working with direct connections**: Postgres is already servicing the max amount of connections
### Solutions [#solutions-causes-max-client-connections-reached]
- **Transaction Mode for serverless apps**: If you are using serverless functions (Supabase Edge, Vercel, AWS Lambda), switch to transaction mode (port 6543). It handles more connections than session mode or direct connections.
- **Reduce the number of Prisma connections**: A single client-server can establish multiple connections with a pooler. Typically, serverless setups do not need many connections. Starting with fewer, like five or three, or even just one, is often sufficient. In serverless setups, begin with `connection_limit=1`, increasing cautiously if needed to avoid maxing out connections.
- **Increase pool size**: If you are connecting with Supavisor, try increasing the pool size in the [Database Settings](https://supabase.com/dashboard/project/_/settings/database).
- **Increase pool size**: If you are connecting with Supavisor, try increasing the pool size in the [Database Settings](https://supabase.com/dashboard/project/_/database/settings).
- **Disconnect appropriately**: Close Prisma connections when they are no longer needed.
- **Decrease query time**: Reduce query complexity or add [strategic indexes](https://supabase.com/docs/guides/database/postgres/indexes) to your tables to speed up queries.
- **Increase compute size**: Sometimes the best option is to increase your compute size, which also increases your max client size and query execution speed
+1 -1
View File
@@ -17,7 +17,7 @@ You can obtain your connection info and Server root certificate from your applic
Download your [SSL certificate](#connecting-with-ssl) to `/path/to/prod-supabase.cer`.
Find your connection settings. Go to your [`Database Settings`](https://supabase.com/dashboard/project/_/settings/database) and make sure `Use connection pooling` is checked. Change the connection mode to `Session`, and copy the parameters into the connection string:
Find your connection settings. Go to your [`Database Settings`](https://supabase.com/dashboard/project/_/database/settings) and make sure `Use connection pooling` is checked. Change the connection mode to `Session`, and copy the parameters into the connection string:
```shell
psql "sslmode=verify-full sslrootcert=/path/to/prod-supabase.cer host=[CLOUD_PROVIDER]-0-[REGION].pooler.supabase.com dbname=postgres user=postgres.[PROJECT_REF]"
@@ -17,6 +17,60 @@ In the Supabase Dashboard:
6. Configure the other options as needed to automate your GitHub connection.
7. Click **Enable integration**.
## Preparing your Git repository
You will be using the [Supabase CLI](/docs/guides/cli) to initialise your local `./supabase` directory:
<StepHikeCompact>
<StepHikeCompact.Step step={1}>
<StepHikeCompact.Details title="Initialize Supabase locally" fullWidth>
If you don't have a `./supabase` directory, you can create one:
```markdown
supabase init
```
</StepHikeCompact.Details>
</StepHikeCompact.Step>
<StepHikeCompact.Step step={2}>
<StepHikeCompact.Details title="Pull your database migration" fullWidth>
Pull your database changes using `supabase db pull`. To get your database connection string, go to your project dashboard, click [Connect](https://supabase.com/dashboard/project/_?showConnect=true) and look for the Session pooler connection string.
```markdown
supabase db pull --db-url <db_connection_string>
# Your Database connection string will look like this:
# postgres://postgres.xxxx:password@xxxx.pooler.supabase.com:5432/postgres
```
<Admonition type="note">
If you're in an [IPv6 environment](https://github.com/orgs/supabase/discussions/27034) or have the IPv4 Add-On, you can use the direct connection string instead of Supavisor in Session mode.
</Admonition>
</StepHikeCompact.Details>
</StepHikeCompact.Step>
<StepHikeCompact.Step step={3}>
<StepHikeCompact.Details title="Commit the `supabase` directory to Git" fullWidth>
Commit the `supabase` directory to Git, and push your changes to your remote repository.
```bash
git add supabase
git commit -m "Initial migration"
git push
```
</StepHikeCompact.Details>
</StepHikeCompact.Step>
</StepHikeCompact>
## Syncing GitHub branches
Enable the **Automatic branching** option in your GitHub Integration configuration to automatically sync GitHub branches with Supabase branches.
@@ -26,7 +26,7 @@ To check the error message, see the Supabase workflow run for your branch under
If you enable [network restrictions](/docs/guides/platform/network-restrictions) on your project, the branching cluster will be blocked from connecting to your project by default. This often results in database connection failures when migrating your production project after merging a development branch.
The workaround is to explicitly allow the IPv6 CIDR range of the branching cluster in your project's [database settings](https://supabase.com/dashboard/project/_/settings/database) page: `2600:1f18:2b7d:f600::/56`
The workaround is to explicitly allow the IPv6 CIDR range of the branching cluster in your project's [Database Settings](https://supabase.com/dashboard/project/_/database/settings) page: `2600:1f18:2b7d:f600::/56`
<Image
alt="Network restrictions to allow connections from branching cluster"
@@ -115,7 +115,7 @@ Deployed edge functions are pre-configured to use SSL for connections to the Sup
If you want to use SSL connections during local development, follow these steps:
1. Download the SSL certificate from [Database settings](https://supabase.com/dashboard/project/_/settings/database)
1. Download the SSL certificate from [Database Settings](https://supabase.com/dashboard/project/_/database/settings)
2. Add to your [local .env file](https://supabase.com/docs/guides/functions/secrets), add these two variables:
```bash
@@ -21,7 +21,7 @@ Combining Kysely with Deno Postgres gives you a convenient developer experience
Find the example on [GitHub](https://github.com/supabase/supabase/tree/master/examples/edge-functions/supabase/functions/kysely-postgres)
Get your database connection credentials from your [Supabase Dashboard](https://supabase.com/dashboard/project/_/settings/database) and store them in an `.env` file:
Get your database connection credentials from your [Supabase Dashboard](https://supabase.com/dashboard/project/_/database/settings) and store them in an `.env` file:
```bash .env
DB_HOSTNAME=
@@ -241,7 +241,7 @@ We recommend the following best practices to mitigate security risks when using
## MCP for local Supabase instances
The Supabase MCP server connects directly to the cloud platform to access your database. If you are running a local instance of Supabase, you can instead use the [Postgres MCP server](https://github.com/modelcontextprotocol/servers/tree/main/src/postgres) to connect to your local database. This MCP server runs all queries as read-only transactions.
The Supabase MCP server connects directly to the cloud platform to access your database. If you are running a local instance of Supabase, you can instead use the [Postgres MCP server](https://github.com/modelcontextprotocol/servers-archived/tree/main/src/postgres) to connect to your local database. This MCP server runs all queries as read-only transactions.
### Step 1: Find your database connection string
@@ -51,7 +51,7 @@ hideToc: true
When your project is up and running, navigate to your project dashboard and click on [Connect](https://supabase.com/dashboard/project/_?showConnect=true).
Look for the Session Pooler connection string and copy the string. You will need to replace the Password with your saved database password. You can reset your database password in your [database settings](https://supabase.com/dashboard/project/_/settings/database) if you do not have it.
Look for the Session Pooler connection string and copy the string. You will need to replace the Password with your saved database password. You can reset your database password in your [Database Settings](https://supabase.com/dashboard/project/_/database/settings) if you do not have it.
<Admonition type="note">
@@ -27,11 +27,11 @@ hideToc: true
<StepHikeCompact.Step step={2}>
<StepHikeCompact.Details title="Gather Database Connection Strings">
Go to the [database settings page](https://supabase.com/dashboard/project/_/settings/database). In this quickstart, we are going to connect via the connection pooler. If your network supports IPv6, you can connect to the database directly without using the connection pooler.
Go to the [Database Settings page](https://supabase.com/dashboard/project/_/database/settings). In this quickstart, we are going to connect via the connection pooler. If your network supports IPv6, you can connect to the database directly without using the connection pooler.
We will use the pooler both in `Transaction` and `Session` mode. `Transaction` mode is used for application queries and `Session` mode is used for running migrations with Prisma.
To do this, set the connection mode to `Transaction` in the [database settings page](https://supabase.com/dashboard/project/_/settings/database) and copy the connection string and append `?pgbouncer=true&&connection_limit=1`. `pgbouncer=true` disables Prisma from generating prepared statements. This is required since our connection pooler does not support prepared statements in transaction mode yet. The `connection_limit=1` parameter is only required if you are using Prisma from a serverless environment. This is the Transaction mode connection string.
To do this, set the connection mode to `Transaction` in the [Database Settings page](https://supabase.com/dashboard/project/_/database/settings) and copy the connection string and append `?pgbouncer=true&&connection_limit=1`. `pgbouncer=true` disables Prisma from generating prepared statements. This is required since our connection pooler does not support prepared statements in transaction mode yet. The `connection_limit=1` parameter is only required if you are using Prisma from a serverless environment. This is the Transaction mode connection string.
To get the Session mode connection pooler string, change the port of the connection string from the dashboard to 5432.
@@ -33,7 +33,7 @@ hideToc: true
When your project is up and running, navigate to your project dashboard and click on [Connect](https://supabase.com/dashboard/project/_?showConnect=true).
Look for the Session Pooler connection string and copy the string. You will need to replace the Password with your saved database password. You can reset your database password in your [database settings](https://supabase.com/dashboard/project/_/settings/database) if you do not have it.
Look for the Session Pooler connection string and copy the string. You will need to replace the Password with your saved database password. You can reset your database password in your [Database Settings](https://supabase.com/dashboard/project/_/database/settings) if you do not have it.
<Admonition type="note">
@@ -33,8 +33,9 @@ Within your app's UI, redirect the user to [`https://api.supabase.com/v1/oauth/a
- `redirect_uri`: The URL where Supabase will redirect the user to after providing consent.
- `response_type`: Set this to `code`.
- `state`: Information about the state of your app. Note that `redirect_uri` and `state` together cannot exceed 4kB in size.
- (Recommended) PKCE: We strongly recommend using the PKCE flow for increased security. Generate a random value before taking the user to the authorize endpoint. This value is called code verifier. Hash it with SHA256 and include it as the `code_challenge` parameter, while setting `code_challenge_method` to `S256`. In the next step, you would need to provide the code verifier to get the first access and refresh token.
- [deprecated] `scope`: Scopes are configured when you create your OAuth app. Read the [docs](/docs/guides/platform/oauth-apps/oauth-scopes) for more details.
- `organization_slug`: The slug of the organization you want to connect to. This is optional, but if provided, it will pre-select the organization for the user.
- [Recommended] PKCE: We strongly recommend using the PKCE flow for increased security. Generate a random value before taking the user to the authorize endpoint. This value is called code verifier. Hash it with SHA256 and include it as the `code_challenge` parameter, while setting `code_challenge_method` to `S256`. In the next step, you would need to provide the code verifier to get the first access and refresh token.
- [Deprecated] `scope`: Scopes are configured when you create your OAuth app. Read the [docs](/docs/guides/platform/oauth-apps/oauth-scopes) for more details.
```ts
router.get('/connect-supabase/login', async (ctx) => {
+1 -38
View File
@@ -171,44 +171,7 @@ For a detailed breakdown of how charges are calculated, refer to [Manage Point-i
## Restore to a new project
Supabase provides a convenient way to restore data from an existing project into a completely new one. Whether you're using physical backups or Point-in-Time recovery (PITR), this feature allows you to duplicate project data with ease, perform testing safely, or recover data for analysis. Access to this feature is exclusive to users on paid plans and requires that physical backups are enabled for the source project.
<Admonition type="note">
PITR is an additional add-on available for organizations on a paid plan with physical backups enabled.
</Admonition>
To begin, switch to the source project—the project containing the data you wish to restore—and go to the [database backups](https://supabase.com/dashboard/project/_/database/backups/restore-to-new-project) page. Select the **Restore to a New Project** tab.
A list of available backups is displayed. Select the backup you want to use and click the "Restore" button. For projects with PITR enabled, use the date and time selector to specify the exact point in time from which you wish to restore data.
Once you’ve made your choice, Supabase takes care of the rest. A new project is automatically created, replicating key configurations from the original, including the compute instance size, disk attributes, SSL enforcement settings, and network restrictions. The data will remain in the same region as the source project to ensure compliance with data residency requirements. The entire process is fully automated.
<Admonition type="note">
The time required to complete the restoration can vary depending largely on the volume of data involved. If you have a large amount of data you can opt for higher performing disk attributes on the source project _before_ starting a clone operation. These disk attributes will be replicated to the new project. This incurs additional costs which will be displayed before starting.
</Admonition>
There are a few important restrictions to be aware of with the "Restore to a New Project" process:
- Projects that are created through the restoration process cannot themselves be used as a source for further clones at this time.
- The feature is only accessible to paid plan users with physical backups enabled, ensuring that the necessary resources and infrastructure are available for the restore process.
Before starting the restoration, you’ll be presented with an overview of the costs associated with creating the new project. The new project will incur additional monthly expenses based on the mirrored resources from the source project. It’s important to review these costs carefully before proceeding.
Once the restoration is complete, the new project will be available in your dashboard and will include all data, tables, schemas, and selected settings from the chosen backup source. It is recommended to thoroughly review the new project and perform any necessary tests to ensure everything has been restored as expected.
New projects are completely independent of their source, and as such can be modified and used as desired.
<Admonition type="note">
As the entire database is copied to the new project, this will include all extensions that were enabled at the source. If the source project included extensions that are configured to carry out external operations—for example pg_net, pg_cron, wrappers—these should be disabled once the copy process has completed to avoid any unwanted actions from taking place.
</Admonition>
Restoring to a new project is an excellent way to manage environments more effectively. You can use this feature to create staging environments for testing, experiment with changes without risk to production data, or swiftly recover from unexpected data loss scenarios.
See the [Duplicate Project docs](/docs/guides/platform/clone-project).
## Troubleshooting
@@ -0,0 +1,45 @@
---
title: Duplicate project
subtitle: How to clone your existing Supabase project
---
You can clone your Supabase project by restoring your data from an existing project into a completely new one. Note that this only duplicates your database, not your project configuration.
Whether you're using physical backups or Point-in-Time recovery (PITR), this feature allows you to duplicate project data with ease, perform testing safely, or recover data for analysis. Access to this feature is exclusive to users on paid plans and requires that physical backups are enabled for the source project.
<Admonition type="note">
PITR is an additional add-on available for organizations on a paid plan with physical backups enabled.
</Admonition>
To begin, switch to the source project—the project containing the data you wish to restore—and go to the [database backups](https://supabase.com/dashboard/project/_/database/backups/restore-to-new-project) page. Select the **Restore to a New Project** tab.
A list of available backups is displayed. Select the backup you want to use and click the "Restore" button. For projects with PITR enabled, use the date and time selector to specify the exact point in time from which you wish to restore data.
Once you’ve made your choice, Supabase takes care of the rest. A new project is automatically created, replicating key configurations from the original, including the compute instance size, disk attributes, SSL enforcement settings, and network restrictions. The data will remain in the same region as the source project to ensure compliance with data residency requirements. The entire process is fully automated.
<Admonition type="note">
The time required to complete the restoration can vary depending largely on the volume of data involved. If you have a large amount of data you can opt for higher performing disk attributes on the source project _before_ starting a clone operation. These disk attributes will be replicated to the new project. This incurs additional costs which will be displayed before starting.
</Admonition>
There are a few important restrictions to be aware of with the "Restore to a New Project" process:
- Projects that are created through the restoration process cannot themselves be used as a source for further clones at this time.
- The feature is only accessible to paid plan users with physical backups enabled, ensuring that the necessary resources and infrastructure are available for the restore process.
Before starting the restoration, you’ll be presented with an overview of the costs associated with creating the new project. The new project will incur additional monthly expenses based on the mirrored resources from the source project. It’s important to review these costs carefully before proceeding.
Once the restoration is complete, the new project will be available in your dashboard and will include all data, tables, schemas, and selected settings from the chosen backup source. It is recommended to thoroughly review the new project and perform any necessary tests to ensure everything has been restored as expected.
New projects are completely independent of their source, and as such can be modified and used as desired.
<Admonition type="note">
As the entire database is copied to the new project, this will include all extensions that were enabled at the source. If the source project included extensions that are configured to carry out external operations—for example pg_net, pg_cron, wrappers—these should be disabled once the copy process has completed to avoid any unwanted actions from taking place.
</Admonition>
Restoring to a new project is an excellent way to manage environments more effectively. You can use this feature to create staging environments for testing, experiment with changes without risk to production data, or swiftly recover from unexpected data loss scenarios.
@@ -8,7 +8,7 @@ Disk metrics refer to the storage usage reported by Postgres. These metrics are
- _Database size_: Displays the actual size of the data within your Postgres database. This can be found on the [Database Reports page](https://supabase.com/dashboard/project/_/reports/database).
- _Disk size_: Shows the overall disk space usage, which includes both the database size and additional files required for Postgres to function like the Write Ahead Log (WAL) and other system log files. You can view this on the [Database Settings page](https://supabase.com/dashboard/project/_/settings/database).
- _Disk size_: Shows the overall disk space usage, which includes both the database size and additional files required for Postgres to function like the Write Ahead Log (WAL) and other system log files. You can view this on the [Database Settings page](https://supabase.com/dashboard/project/_/database/settings).
## Database size
@@ -94,11 +94,11 @@ The automatic resize operation will add an additional 50% capped to a maximum of
</Admonition>
Disk size can also be manually expanded on the [Database settings page](https://supabase.com/dashboard/project/_/settings/database). The maximum disk size for the Pro/Team Plan is 60 TB. If you need more than this, [contact us](https://forms.supabase.com/enterprise) to learn more about the Enterprise Plan.
Disk size can also be manually expanded on the [Database Settings page](https://supabase.com/dashboard/project/_/database/settings). The maximum disk size for the Pro/Team Plan is 60 TB. If you need more than this, [contact us](https://forms.supabase.com/enterprise) to learn more about the Enterprise Plan.
<Admonition type="note">
You may want to import a lot of data into your database which requires multiple disk expansions. for example, uploading more than 1.5x the current size of your database storage will put your database into [read-only mode](#read-only-mode). If so, it is highly recommended you increase the disk size manually on the [Database settings page](https://supabase.com/dashboard/project/_/settings/database).
You may want to import a lot of data into your database which requires multiple disk expansions. for example, uploading more than 1.5x the current size of your database storage will put your database into [read-only mode](#read-only-mode). If so, it is highly recommended you increase the disk size manually on the [Database Settings page](https://supabase.com/dashboard/project/_/database/settings).
Due to restrictions on the underlying cloud provider, disk expansions can occur only once every six hours. During the six hour cool down window, the disk cannot be resized again.
@@ -22,7 +22,7 @@ Supabase's core is Postgres, enabling the use of row-level security and providin
## Retrieve your Supabase host [#retrieve-supabase-host]
1. If you're new to Supabase, [create a project](https://database.new). Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/settings/database).
1. If you're new to Supabase, [create a project](https://database.new). Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/database/settings).
1. On your project dashboard, click [Connect](https://supabase.com/dashboard/project/_?showConnect=true)
1. Under the Session pooler, click on the View parameters under the connect string. Note your Host (`$SUPABASE_HOST`).
@@ -36,7 +36,7 @@ Alternatively, use the [Heroku to Supabase migration tool](https://migrate.supab
1. If you're new to Supabase, [create a project](https://supabase.com/dashboard).
1. Get your project's Session pooler connection string from your project dashboard by clicking [Connect](https://supabase.com/dashboard/project/_?showConnect=true).
1. Replace [YOUR-PASSWORD] in the connection string with your database password. You can reset your database password on the [Database settings page](https://supabase.com/dashboard/project/_/settings/database) if you do not have it.
1. Replace [YOUR-PASSWORD] in the connection string with your database password. You can reset your database password on the [Database Settings page](https://supabase.com/dashboard/project/_/database/settings) if you do not have it.
## Export your Heroku database to a file [#export-heroku-database]
@@ -20,7 +20,7 @@ Before you begin the migration, you need to collect essential information about
## Retrieve your Supabase host [#retrieve-supabase-host]
1. If you're new to Supabase, [create a project](https://supabase.com/dashboard).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/settings/database).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/database/settings).
1. On your project dashboard, click [Connect](https://supabase.com/dashboard/project/_?showConnect=true)
1. Under the Session pooler, click on the View parameters under the connect string. Note your Host (`$SUPABASE_HOST`).
@@ -21,7 +21,7 @@ Before you begin the migration, you need to collect essential information about
## Retrieve your Supabase host [#retrieve-supabase-host]
1. If you're new to Supabase, [create a project](https://supabase.com/dashboard).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/settings/database).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/database/settings).
1. On your project dashboard, click [Connect](https://supabase.com/dashboard/project/_?showConnect=true)
1. Under the Session pooler, click on the View parameters under the connect string. Note your Host (`$SUPABASE_HOST`).
@@ -32,7 +32,7 @@ export OLD_DB_URL="postgresql://neondb_owner:xxxxxxxxxxxxxxx-random-word-yyyyyyy
## Retrieve your Supabase connection string [#retrieve-supabase-connection-string]
1. If you're new to Supabase, [create a project](https://supabase.com/dashboard).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/settings/database).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/database/settings).
1. On your project dashboard, click [Connect](https://supabase.com/dashboard/project/_?showConnect=true)
1. Under the Session pooler, click the **Copy** button to the right of your connection string to copy it to the clipboard.
@@ -23,7 +23,7 @@ Example:
## Retrieve your Supabase connection string [#retrieve-supabase-connection-string]
1. If you're new to Supabase, [create a project](https://supabase.com/dashboard).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/settings/database).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/database/settings).
1. On your project dashboard, click [Connect](https://supabase.com/dashboard/project/_?showConnect=true)
1. Under Session pooler, Copy the connection string and replace the password placeholder with your database password.
@@ -27,7 +27,7 @@ Example:
## Retrieve your Supabase connection string [#retrieve-supabase-connection-string]
1. If you're new to Supabase, [create a project](https://supabase.com/dashboard).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/settings/database).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/database/settings).
1. On your project dashboard, click [Connect](https://supabase.com/dashboard/project/_?showConnect=true)
1. Under Session pooler, Copy the connection string and replace the password placeholder with your database password.
@@ -39,7 +39,7 @@ export OLD_DB_URL="postgres://default:xxxxxxxxxxxx@yy-yyyyy-yyyyyy-yyyyyyy.us-we
## Retrieve your Supabase connection string [#retrieve-supabase-connection-string]
1. If you're new to Supabase, [create a project](https://supabase.com/dashboard).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/settings/database).
Make a note of your password, you will need this later. If you forget it, you can [reset it here](https://supabase.com/dashboard/project/_/database/settings).
1. On your project dashboard, click [Connect](https://supabase.com/dashboard/project/_?showConnect=true)
1. Under the Session pooler, click the **Copy** button to the right of your connection string to copy it to the clipboard.
@@ -4,7 +4,7 @@ subtitle: Learn how to migrate from one Supabase project to another
---
If you are on a Paid Plan and have physical backups enabled, you should instead use the [Restore
to another project feature](/docs/guides/platform/backups#restore-to-a-new-project)
to another project feature](/docs/guides/platform/clone-project).
## Database migration guides
@@ -44,7 +44,7 @@ breadcrumb: 'Migrations'
<StepHikeCompact.Step step={4}>
<StepHikeCompact.Details title="Get the database password" fullWidth>
Reset the password in the [Database Settings](/dashboard/project/_/settings/database).
Reset the password in the [Database Settings](/dashboard/project/_/database/settings).
Replace ```[YOUR-PASSWORD]``` in the connection string with the database password.
@@ -91,7 +91,7 @@ Here are some things that are not stored directly in your database and will requ
It can take a few minutes for the database password reset to take effect. Especially if multiple password resets are done.
</Admonition>
Reset the password in the [Database Settings](https://supabase.com/dashboard/project/_/settings/database).
Reset the password in the [Database Settings](https://supabase.com/dashboard/project/_/database/settings).
Replace ```[YOUR-PASSWORD]``` in the connection string with the database password.
@@ -6,17 +6,17 @@ description: "Apply network restrictions for your project's database."
<Admonition type="note">
If you can't find the Network Restrictions section at the bottom of your [Database Settings](/dashboard/project/_/settings/database), update your version of Postgres in the [Infrastructure Settings](/dashboard/project/_/settings/infrastructure).
If you can't find the Network Restrictions section at the bottom of your [Database Settings](/dashboard/project/_/database/settings), update your version of Postgres in the [Infrastructure Settings](/dashboard/project/_/settings/infrastructure).
</Admonition>
Each Supabase project comes with configurable restrictions on the IP ranges that are allowed to connect to Postgres and its pooler ("your database"). These restrictions are enforced before traffic reaches your database. If a connection is not restricted by IP, it still needs to authenticate successfully with valid database credentials.
If direct connections to your database [resolve to a IPv6 address](https://supabase.com/dashboard/project/_/settings/database), you need to add both IPv4 and IPv6 CIDRs to the list of allowed CIDRs. Network Restrictions will be applied to all database connection routes, whether pooled or direct. You will need to add both the IPv4 and IPv6 networks you want to allow. There are two exceptions: If you have been granted an extension on the IPv6 migration OR if you have purchased the [IPv4 add-on](https://supabase.com/dashboard/project/_/settings/addons), you need only add IPv4 CIDRs.
If direct connections to your database [resolve to a IPv6 address](https://supabase.com/dashboard/project/_/database/settings), you need to add both IPv4 and IPv6 CIDRs to the list of allowed CIDRs. Network Restrictions will be applied to all database connection routes, whether pooled or direct. You will need to add both the IPv4 and IPv6 networks you want to allow. There are two exceptions: If you have been granted an extension on the IPv6 migration OR if you have purchased the [IPv4 add-on](https://supabase.com/dashboard/project/_/settings/addons), you need only add IPv4 CIDRs.
## To get started via the Dashboard:
Network restrictions can be configured in the [Database Settings](https://supabase.com/dashboard/project/_/settings/database) page. Ensure that you have [Owner or Admin permissions](/docs/guides/platform/access-control#manage-team-members) for the project that you are enabling network restrictions.
Network restrictions can be configured in the [Database Settings](https://supabase.com/dashboard/project/_/database/settings) page. Ensure that you have [Owner or Admin permissions](/docs/guides/platform/access-control#manage-team-members) for the project that you are enabling network restrictions.
## To get started via the Management API:
@@ -104,7 +104,7 @@ Read Replicas offer the following features:
Each Read Replica has its own dedicated database and API endpoints.
- Find the database endpoint on the [Database Settings page](/dashboard/project/_/settings/database) under **Connection Info**
- Find the database endpoint on the [Database Settings page](/dashboard/project/_/database/settings) under **Connection Info**
- Find the API endpoint on the [API Settings page](/dashboard/project/_/settings/api) under **Project URL**
Read Replicas only support `GET` requests from the [REST API](/docs/guides/api). If you are calling a read-only Postgres function through the REST API, make sure to set the `get: true` [option](/docs/reference/javascript/rpc?queryGroups=example&example=call-a-read-only-postgres-function).
@@ -115,7 +115,7 @@ If you're using an [IPv4 add-on](/docs/guides/platform/ipv4-address#read-replica
### Dedicated connection pool
A connection pool through Supavisor is also available for each Read Replica. Find the connection string on the [Database Settings page](/dashboard/project/_/settings/database) under **Connection String**.
A connection pool through Supavisor is also available for each Read Replica. Find the connection string on the [Database Settings page](/dashboard/project/_/database/settings) under **Connection String**.
### API load balancer
@@ -16,7 +16,7 @@ Projects need to be at least on Postgres 13.3.0 to enable SSL enforcement. You c
## Manage SSL enforcement via the dashboard
SSL enforcement can be configured via the "Enforce SSL on incoming connections" setting under the SSL Configuration section in [Database Settings page](https://supabase.com/dashboard/project/_/settings/database) of the dashboard.
SSL enforcement can be configured via the "Enforce SSL on incoming connections" setting under the SSL Configuration section in [Database Settings page](https://supabase.com/dashboard/project/_/database/settings) of the dashboard.
## Manage SSL enforcement via the Management API
@@ -98,7 +98,7 @@ supabase ssl-enforcement --project-ref {ref} update --disable-db-ssl-enforcement
Postgres supports [multiple SSL modes](https://www.postgresql.org/docs/current/libpq-ssl.html#LIBPQ-SSL-PROTECTION) on the client side. These modes provide different levels of protection. Depending on your needs, it is important to verify that the SSL mode in use is performing the required level of enforcement and verification of SSL connections.
The strongest mode offered by Postgres is `verify-full` and this is the mode you most likely want to use when SSL enforcement is enabled. To use `verify-full` you will need to download the Supabase CA certificate for your database. The certificate is available through the dashboard under the SSL Configuration section in the [Database Settings page](/dashboard/project/_/settings/database).
The strongest mode offered by Postgres is `verify-full` and this is the mode you most likely want to use when SSL enforcement is enabled. To use `verify-full` you will need to download the Supabase CA certificate for your database. The certificate is available through the dashboard under the SSL Configuration section in the [Database Settings page](/dashboard/project/_/database/settings).
Once the CA certificate has been downloaded, add it to the certificate authority list used by Postgres.
@@ -92,7 +92,7 @@ Go to your Supabase project's [API Settings](https://supabase.com/dashboard/proj
### Receiving Broadcast messages
You can provide a callback for the `broadcast` channel to receive message. This example will receive any `broadcast` messages that are sent to `test-channel`:
You can provide a callback for the `broadcast` channel to receive messages. This example will receive any `broadcast` messages that are sent to `test-channel`:
<Tabs
scrollable
@@ -469,7 +469,7 @@ You can pass configuration options while initializing the Supabase Client.
myChannel.subscribe((status) => {
if (status !== 'SUBSCRIBED') { return }
channelC.send({
myChannel.send({
type: 'broadcast',
event: 'test-my-messages',
payload: { message: 'talking to myself' },
@@ -57,7 +57,7 @@ roomOne.send({
Other clients can receive the message in real-time by subscribing to the Channel with topic `room-one`. These clients continue to receive messages as long as they are subscribed and connected to the same Channel topic.
You can also use [Broadcast using the REST API](/docs/guides/realtime/broad cast#broadcast-using-the-rest-api) and [Broadcast using the Database](/docs/guides/realtime/broadcast#broadcast-using-the-database) to send messages to a Channel which allows you to do more advanced use-cases.
You can also use [Broadcast using the REST API](https://supabase.com/docs/guides/realtime/broadcast#broadcast-using-the-rest-api) and [Broadcast using the Database](/docs/guides/realtime/broadcast#broadcast-using-the-database) to send messages to a Channel which allows you to do more advanced use-cases.
An example use-case is sharing a user's cursor position with other clients in an online game.
@@ -27,7 +27,7 @@ To connect to an Analytics Bucket, you will need
- An Iceberg client (Spark, PyIceberg, etc) which supports the REST Catalog interface.
- S3 credentials to authenticate your Iceberg client with the underlying S3 Bucket.
To create S3 Credentials go to [**Project Settings > Storage**](https://supabase.com/dashboard/project/_/settings/storage), for more information, see the [S3 Authentication Guide](https://supabase.com/docs/guides/storage/s3/authentication). We will support other authentication methods in the future.
To create S3 Credentials go to [**Project Settings > Storage**](https://supabase.com/dashboard/project/_/storage/settings), for more information, see the [S3 Authentication Guide](https://supabase.com/docs/guides/storage/s3/authentication). We will support other authentication methods in the future.
- The project reference and Service key for your Supabase project.
You can find your Service key in the Supabase Dashboard under [**Project Settings > API**.](https://supabase.com/dashboard/project/_/settings/api-keys)
@@ -26,40 +26,40 @@ The error codes are returned in the following format:
Here is the full list of error codes and their descriptions:
| `ErrorCode` | Description | `StatusCode` | Resolution |
| --------------------------- | --------------------------------------------------------------- | ------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `NoSuchBucket` | The specified bucket does not exist. | 404 | Verify the bucket name and ensure it exists in the system, if it exists you don't have permissions to access it. |
| `NoSuchKey` | The specified key does not exist. | 404 | Check the key name and ensure it exists in the specified bucket, if it exists you don't have permissions to access it. |
| `NoSuchUpload` | The specified upload does not exist. | 404 | The upload ID provided might not exists or the Upload was previously aborted |
| `InvalidJWT` | The provided JWT (JSON Web Token) is invalid. | 401 | The JWT provided might be expired or malformed, provide a valid JWT |
| `InvalidRequest` | The request is not properly formed. | 400 | Review the request parameters and structure, ensure they meet the API's requirements, the error message will provide more details |
| `TenantNotFound` | The specified tenant does not exist. | 404 | The Storage service had issues while provisioning, [Contact Support](https://supabase.com/dashboard/support/new) |
| `EntityTooLarge` | The entity being uploaded is too large. | 413 | Verify the max-file-limit is equal or higher to the resource you are trying to upload, you can change this value on the [Project Setting](https://supabase.com/dashboard/project/_/settings/storage) |
| `InternalError` | An internal server error occurred. | 500 | Investigate server logs to identify the cause of the internal error. If you think it's a Storage error [Contact Support](https://supabase.com/dashboard/support/new) |
| `ResourceAlreadyExists` | The specified resource already exists. | 409 | Use a different name or identifier for the resource to avoid conflicts. Use `x-upsert:true` header to overwrite the resource. |
| `InvalidBucketName` | The specified bucket name is invalid. | 400 | Ensure the bucket name follows the naming conventions and does not contain invalid characters. |
| `InvalidKey` | The specified key is invalid. | 400 | Verify the key name and ensure it follows the naming conventions. |
| `InvalidRange` | The specified range is not valid. | 416 | Make sure that range provided is within the file size boundary and follow the [HTTP Range spec](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Range) |
| `InvalidMimeType` | The specified MIME type is not valid. | 400 | Provide a valid MIME type, ensure using the standard MIME type format |
| `InvalidUploadId` | The specified upload ID is invalid. | 400 | The upload ID provided is invalid or missing. Make sure to provide a active upload ID |
| `KeyAlreadyExists` | The specified key already exists. | 409 | Use a different key name to avoid conflicts with existing keys. Use `x-upsert:true` header to overwrite the resource. |
| `BucketAlreadyExists` | The specified bucket already exists. | 409 | Choose a unique name for the bucket that does not conflict with existing buckets. |
| `DatabaseTimeout` | Timeout occurred while accessing the database. | 504 | Investigate database performance and increase the default pool size. If this error still occurs, upgrade your instance |
| `InvalidSignature` | The signature provided does not match the calculated signature. | 403 | Check that you are providing the correct signature format, for more information refer to [SignatureV4](https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-authenticating-requests.html) |
| `SignatureDoesNotMatch` | The request signature does not match the calculated signature. | 403 | Check your credentials, access key id / access secret key / region that are all correct, refer to [S3 Authentication](/docs/guides/storage/s3/authentication). |
| `AccessDenied` | Access to the specified resource is denied. | 403 | Check that you have the correct RLS policy to allow access to this resource |
| `ResourceLocked` | The specified resource is locked. | 423 | This resource cannot be altered while there is a lock. Wait and try the request again |
| `DatabaseError` | An error occurred while accessing the database. | 500 | Investigate database logs and system configuration to identify and address the database error. |
| `MissingContentLength` | The Content-Length header is missing. | 411 | Ensure the Content-Length header is included in the request with the correct value. |
| `MissingParameter` | A required parameter is missing in the request. | 400 | Provide all required parameters in the request to fulfill the API's requirements. The message field will contain more details |
| `InvalidUploadSignature` | The provided upload signature is invalid. | 403 | The `MultiPartUpload` record was altered while the upload was ongoing, the signature do not match. Do not alter the upload record |
| `LockTimeout` | Timeout occurred while waiting for a lock. | 423 | The lock couldn't be acquired within the specified timeout. Wait and try the request again |
| `S3Error` | An error occurred related to Amazon S3. | - | Refer to Amazon S3 documentation or [Contact Support](https://supabase.com/dashboard/support/new) for assistance with resolving the S3 error. |
| `S3InvalidAccessKeyId` | The provided AWS access key ID is invalid. | 403 | Verify the AWS access key ID provided and ensure it is correct and active. |
| `S3MaximumCredentialsLimit` | The maximum number of credentials has been reached. | 400 | The maximum limit of credentials is reached. |
| `InvalidChecksum` | The checksum of the entity does not match. | 400 | Recalculate the checksum of the entity and ensure it matches the one provided in the request. |
| `MissingPart` | A part of the entity is missing. | 400 | Ensure all parts of the entity are included in the request before completing the operation. |
| `SlowDown` | The request rate is too high and has been throttled. | 503 | Reduce the request rate or implement exponential backoff and retry mechanisms to handle throttling. |
| `ErrorCode` | Description | `StatusCode` | Resolution |
| --------------------------- | --------------------------------------------------------------- | ------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `NoSuchBucket` | The specified bucket does not exist. | 404 | Verify the bucket name and ensure it exists in the system, if it exists you don't have permissions to access it. |
| `NoSuchKey` | The specified key does not exist. | 404 | Check the key name and ensure it exists in the specified bucket, if it exists you don't have permissions to access it. |
| `NoSuchUpload` | The specified upload does not exist. | 404 | The upload ID provided might not exists or the Upload was previously aborted |
| `InvalidJWT` | The provided JWT (JSON Web Token) is invalid. | 401 | The JWT provided might be expired or malformed, provide a valid JWT |
| `InvalidRequest` | The request is not properly formed. | 400 | Review the request parameters and structure, ensure they meet the API's requirements, the error message will provide more details |
| `TenantNotFound` | The specified tenant does not exist. | 404 | The Storage service had issues while provisioning, [Contact Support](https://supabase.com/dashboard/support/new) |
| `EntityTooLarge` | The entity being uploaded is too large. | 413 | Verify the max-file-limit is equal or higher to the resource you are trying to upload, you can change this value on the [Project Settings](https://supabase.com/dashboard/project/_/storage/settings) |
| `InternalError` | An internal server error occurred. | 500 | Investigate server logs to identify the cause of the internal error. If you think it's a Storage error [Contact Support](https://supabase.com/dashboard/support/new) |
| `ResourceAlreadyExists` | The specified resource already exists. | 409 | Use a different name or identifier for the resource to avoid conflicts. Use `x-upsert:true` header to overwrite the resource. |
| `InvalidBucketName` | The specified bucket name is invalid. | 400 | Ensure the bucket name follows the naming conventions and does not contain invalid characters. |
| `InvalidKey` | The specified key is invalid. | 400 | Verify the key name and ensure it follows the naming conventions. |
| `InvalidRange` | The specified range is not valid. | 416 | Make sure that range provided is within the file size boundary and follow the [HTTP Range spec](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Range) |
| `InvalidMimeType` | The specified MIME type is not valid. | 400 | Provide a valid MIME type, ensure using the standard MIME type format |
| `InvalidUploadId` | The specified upload ID is invalid. | 400 | The upload ID provided is invalid or missing. Make sure to provide a active upload ID |
| `KeyAlreadyExists` | The specified key already exists. | 409 | Use a different key name to avoid conflicts with existing keys. Use `x-upsert:true` header to overwrite the resource. |
| `BucketAlreadyExists` | The specified bucket already exists. | 409 | Choose a unique name for the bucket that does not conflict with existing buckets. |
| `DatabaseTimeout` | Timeout occurred while accessing the database. | 504 | Investigate database performance and increase the default pool size. If this error still occurs, upgrade your instance |
| `InvalidSignature` | The signature provided does not match the calculated signature. | 403 | Check that you are providing the correct signature format, for more information refer to [SignatureV4](https://docs.aws.amazon.com/AmazonS3/latest/API/sig-v4-authenticating-requests.html) |
| `SignatureDoesNotMatch` | The request signature does not match the calculated signature. | 403 | Check your credentials, access key id / access secret key / region that are all correct, refer to [S3 Authentication](/docs/guides/storage/s3/authentication). |
| `AccessDenied` | Access to the specified resource is denied. | 403 | Check that you have the correct RLS policy to allow access to this resource |
| `ResourceLocked` | The specified resource is locked. | 423 | This resource cannot be altered while there is a lock. Wait and try the request again |
| `DatabaseError` | An error occurred while accessing the database. | 500 | Investigate database logs and system configuration to identify and address the database error. |
| `MissingContentLength` | The Content-Length header is missing. | 411 | Ensure the Content-Length header is included in the request with the correct value. |
| `MissingParameter` | A required parameter is missing in the request. | 400 | Provide all required parameters in the request to fulfill the API's requirements. The message field will contain more details |
| `InvalidUploadSignature` | The provided upload signature is invalid. | 403 | The `MultiPartUpload` record was altered while the upload was ongoing, the signature do not match. Do not alter the upload record |
| `LockTimeout` | Timeout occurred while waiting for a lock. | 423 | The lock couldn't be acquired within the specified timeout. Wait and try the request again |
| `S3Error` | An error occurred related to Amazon S3. | - | Refer to Amazon S3 documentation or [Contact Support](https://supabase.com/dashboard/support/new) for assistance with resolving the S3 error. |
| `S3InvalidAccessKeyId` | The provided AWS access key ID is invalid. | 403 | Verify the AWS access key ID provided and ensure it is correct and active. |
| `S3MaximumCredentialsLimit` | The maximum number of credentials has been reached. | 400 | The maximum limit of credentials is reached. |
| `InvalidChecksum` | The checksum of the entity does not match. | 400 | Recalculate the checksum of the entity and ensure it matches the one provided in the request. |
| `MissingPart` | A part of the entity is missing. | 400 | Ensure all parts of the entity are included in the request before completing the operation. |
| `SlowDown` | The request rate is too high and has been throttled. | 503 | Reduce the request rate or implement exponential backoff and retry mechanisms to handle throttling. |
## Legacy error codes
@@ -8,7 +8,7 @@ sidebar_label: 'S3'
You have two options to authenticate with Supabase Storage S3:
- Using the generated S3 access keys from your [project settings](/dashboard/project/_/settings/storage) (Intended exclusively for server-side use)
- Using the generated S3 access keys from your [project settings](/dashboard/project/_/storage/settings) (Intended exclusively for server-side use)
- Using a Session Token, which will allow you to authenticate with a user JWT token and provide limited access via Row Level Security (RLS).
## S3 access keys
@@ -19,7 +19,7 @@ S3 access keys provide full access to all S3 operations across all buckets and b
</Admonition>
To authenticate with S3, generate a pair of credentials (Access Key ID and Secret Access Key), copy the endpoint and region from the [project settings page](/dashboard/project/_/settings/storage).
To authenticate with S3, generate a pair of credentials (Access Key ID and Secret Access Key), copy the endpoint and region from the [project settings page](/dashboard/project/_/storage/settings).
This is all the information you need to connect to Supabase Storage using any S3-compatible service.
@@ -8,7 +8,7 @@ sidebar_label: 'Limits'
## Global file size
You can set the max file size across all your buckets by setting this global value in the dashboard [here](https://supabase.com/dashboard/project/_/settings/storage). For Free projects, the limit can't exceed 50 MB. On the Pro Plan and up, you can set this value to up to 500 GB. If you need more than 500 GB, [contact us](https://supabase.com/dashboard/support/new).
You can set the max file size across all your buckets by setting this global value in the dashboard [here](https://supabase.com/dashboard/project/_/storage/settings). For Free projects, the limit can't exceed 50 MB. On the Pro Plan and up, you can set this value to up to 500 GB. If you need more than 500 GB, [contact us](https://supabase.com/dashboard/support/new).
| Plan | Max File Size Limit |
| ---------- | ------------------- |
@@ -57,6 +57,9 @@ Instead of `https://project-id.supabase.co` use `https://project-id.storage.supa
objectName: fileName,
contentType: 'image/png',
cacheControl: 3600,
metadata: JSON.stringify({ // custom metadata passed to the user_metadata column
yourCustomMetadata: true,
}),
},
chunkSize: 6 * 1024 * 1024, // NOTE: it must be set to 6MB (for now) do not change it
onError: function (error) {
@@ -159,6 +162,7 @@ Instead of `https://project-id.supabase.co` use `https://project-id.storage.supa
"objectName",
"contentType",
"cacheControl",
"metadata",
], // Metadata fields allowed for the upload
onError: (error) => console.error("Upload error:", error), // Error handling for uploads
}).on("file-added", (file) => {
@@ -168,6 +172,9 @@ Instead of `https://project-id.supabase.co` use `https://project-id.storage.supa
bucketName, // Bucket specified by the user of the hook
objectName: file.name, // Use file name as object name
contentType: file.type, // Set content type based on file MIME type
metadata: JSON.stringify({ // custom metadata passed to the user_metadata column
yourCustomMetadata: true,
}),
};
});
};
@@ -7,4 +7,4 @@ keywords = [ "password", "reset" ]
database_id = "6e4a515c-5e70-4b92-808c-f076d47d4e35"
---
You can reset your database password from the [database settings page](https://supabase.com/dashboard/project/_/settings/database) on the project dashboard.
You can reset your database password from the [Database Settings page](https://supabase.com/dashboard/project/_/database/settings) on the project dashboard.
@@ -18,16 +18,16 @@ The subdomain will vary depending on the region a project is deployed in. The pr
- How to update the size of the connection pool to the database:
You can set the `Max Client Connections` field in your database settings here:
[https://supabase.com/dashboard/project/\_/settings/database](https://supabase.com/dashboard/project/_/settings/database)
[https://supabase.com/dashboard/project/\_/database/settings](https://supabase.com/dashboard/project/_/database/settings)
- How to change the client connection limit:
You can set the `Default Pool Size` field in your database settings:
[https://supabase.com/dashboard/project/\_/settings/database](https://supabase.com/dashboard/project/_/settings/database)
[https://supabase.com/dashboard/project/\_/database/settings](https://supabase.com/dashboard/project/_/database/settings)
- How to use `session` mode:
With Supavisor you can automatically use `session` mode by using the connection string with port `5432` in it.
You can also set the pooler port 6543 to use `session` mode in the database settings:
[https://supabase.com/dashboard/project/\_/settings/database](https://supabase.com/dashboard/project/_/settings/database)
[https://supabase.com/dashboard/project/\_/database/settings](https://supabase.com/dashboard/project/_/database/settings)
@@ -82,7 +82,7 @@ If you believe a connection should be killed, you can do so by running the follo
The Supavisor Pooler is an intermediary between your clients (application servers) and the database. In transaction mode (port 6543), it can enable Postgres to share single connections with many clients, only allowing access when a query is pending. This prevents idle clients from hogging a direct connection and allows for more throughput.
In cases where you see significantly more pooler connections than direct connections, if you can, you should consider increasing how many direct connections the pooler is allowed to manage in the [Dashboard's Database Settings](/dashboard/project/_/settings/database):
In cases where you see significantly more pooler connections than direct connections, if you can, you should consider increasing how many direct connections the pooler is allowed to manage in the [Dashboard's Database Settings](/dashboard/project/_/database/settings):
![image](https://github.com/supabase/supabase/assets/91111415/8e0cc80a-4d46-44b5-915b-8d7549f352d3).
@@ -22,7 +22,7 @@ All Supabase databases provide a direct connection string that maps to an IPv6 a
Here are your options if your server platform doesn't support IPv6:
- Use the Supavisor Connection String (available in the [Dashboard](https://supabase.com/dashboard/project/_/settings/database)).
- Use the Supavisor Connection String (available in the [Dashboard](https://supabase.com/dashboard/project/_/database/settings)).
- Use the [Supabase Client libraries](https://supabase.com/docs/guides/api/rest/client-libs), which are IPv4 compatible.
- Enable the [dedicated IPv4 Add-On](https://supabase.com/dashboard/project/_/settings/addons) (available to Pro and above organizations)
@@ -129,7 +129,7 @@ No, it doesn't. Let's break it down:
### **How to change pool size**
In the [Dashboard's Database Settings](https://supabase.com/dashboard/project/_/settings/database), you can configure Supavisor's "Pool Size":
In the [Dashboard's Database Settings](https://supabase.com/dashboard/project/_/database/settings), you can configure Supavisor's "Pool Size":
<img
width="673"
@@ -11,7 +11,7 @@ You can view the max permissible upload size for your plan in the [docs](https:/
## There are two ways to control the max upload sizes:
The first way is through the [global storage settings](https://supabase.com/dashboard/project/_/settings/storage):
The first way is through the [global storage settings](https://supabase.com/dashboard/project/_/storage/settings):
<img
width="920"
File diff suppressed because it is too large. Load diff
+3
View File
@@ -4,8 +4,11 @@ export const API_URL = (
: process.env.NEXT_PUBLIC_API_URL!
)?.replace(/\/platform$/, '')
export const BASE_PATH = process.env.NEXT_PUBLIC_BASE_PATH || '/docs'
export const IS_CI = process.env.CI === 'true'
export const IS_DEV = process.env.NODE_ENV === 'development'
export const IS_PLATFORM = process.env.NEXT_PUBLIC_IS_PLATFORM === 'true'
export const IS_PRODUCTION = process.env.NEXT_PUBLIC_VERCEL_ENV === 'production'
export const LOGFLARE_INGESTION_API_KEY = process.env.LOGFLARE_INGESTION_API_KEY
export const LOGFLARE_SOURCE_TOKEN = process.env.LOGFLARE_SOURCE_TOKEN
export const MISC_URL = process.env.NEXT_PUBLIC_MISC_URL ?? ''
export const PROD_URL = `https://supabase.com${BASE_PATH}`
+34
View File
@@ -0,0 +1,34 @@
import { IS_CI, IS_DEV, LOGFLARE_INGESTION_API_KEY, LOGFLARE_SOURCE_TOKEN } from './constants'
export const LOGGING_CODES = {
CONTENT_API_REQUEST_RECEIVED: 'content_api_request_received',
} as const
const LOGFLARE_ENDPOINT = `https://api.logflare.app/api/logs?source=${LOGFLARE_SOURCE_TOKEN}`
interface LogflareMessage {
message: string
metadata?: Record<string, unknown>
}
export function sendToLogflare(message: string, metadata?: Record<string, unknown>) {
// Skip logging in CI and development environments
if (IS_CI || IS_DEV) return
const logMessage: LogflareMessage = {
message,
}
if (metadata) {
logMessage.metadata = metadata
}
fetch(LOGFLARE_ENDPOINT, {
method: 'POST',
headers: {
Authorization: `Bearer ${LOGFLARE_INGESTION_API_KEY}`,
'Content-Type': 'application/json',
},
body: JSON.stringify(logMessage),
})
}
Binary file not shown.

Before

Width:  |  Height:  |  Size: 491 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 458 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 424 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 448 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 453 KiB

+20 -20
View File
@@ -367,6 +367,13 @@
"in": "query",
"description": "Organization slug",
"schema": { "pattern": "^[\\w-]+$", "type": "string" }
},
{
"name": "resource",
"required": false,
"in": "query",
"description": "Resource indicator for MCP (Model Context Protocol) clients",
"schema": { "enum": ["https://api.supabase.io/mcp"], "type": "string" }
}
],
"responses": { "204": { "description": "" } },
@@ -4395,7 +4402,12 @@
"code": { "type": "string" },
"code_verifier": { "type": "string" },
"redirect_uri": { "type": "string" },
"refresh_token": { "type": "string" }
"refresh_token": { "type": "string" },
"resource": {
"type": "string",
"enum": ["https://api.supabase.io/mcp"],
"description": "Resource indicator for MCP (Model Context Protocol) clients"
}
},
"additionalProperties": false
},
@@ -4532,12 +4544,7 @@
"name": { "type": "string" },
"description": { "type": "string", "nullable": true },
"hash": { "type": "string", "nullable": true },
"secret_jwt_template": {
"type": "object",
"properties": { "role": { "type": "string", "minLength": 1 } },
"required": ["role"],
"nullable": true
},
"secret_jwt_template": { "type": "object", "additionalProperties": {}, "nullable": true },
"inserted_at": { "type": "string", "format": "date-time", "nullable": true },
"updated_at": { "type": "string", "format": "date-time", "nullable": true }
},
@@ -4559,12 +4566,7 @@
"pattern": "^[a-z_][a-z0-9_]+$"
},
"description": { "type": "string", "nullable": true },
"secret_jwt_template": {
"type": "object",
"properties": { "role": { "type": "string", "minLength": 1 } },
"required": ["role"],
"nullable": true
}
"secret_jwt_template": { "type": "object", "additionalProperties": {}, "nullable": true }
},
"required": ["type", "name"]
},
@@ -4578,12 +4580,7 @@
"pattern": "^[a-z_][a-z0-9_]+$"
},
"description": { "type": "string", "nullable": true },
"secret_jwt_template": {
"type": "object",
"properties": { "role": { "type": "string", "minLength": 1 } },
"required": ["role"],
"nullable": true
}
"secret_jwt_template": { "type": "object", "additionalProperties": {}, "nullable": true }
}
},
"CreateBranchBody": {
@@ -4953,7 +4950,10 @@
"items": {
"type": "object",
"properties": {
"postgres_version": { "type": "string", "enum": ["15", "17", "17-oriole"] },
"postgres_version": {
"type": "string",
"enum": ["13", "14", "15", "17", "17-oriole"]
},
"release_channel": {
"type": "string",
"enum": ["internal", "alpha", "beta", "ga", "withdrawn", "preview"]
+35 -1
View File
@@ -1,7 +1,7 @@
clispec: '001'
info:
id: cli
version: 2.31.4
version: 2.33.9
title: Supabase CLI
language: sh
source: https://github.com/supabase/cli
@@ -2250,6 +2250,7 @@ commands:
links: []
subcommands:
- supabase-gen-keys
- supabase-gen-signing-key
- supabase-gen-types
flags: []
- id: supabase-gen-types
@@ -2310,6 +2311,35 @@ commands:
- id: public
name: public
type: '[ internal | public ]'
- id: supabase-gen-signing-key
title: supabase gen signing-key
summary: Generate a JWT signing key
description: |
Securely generate a private JWT signing key for use in the CLI or to import in the dashboard.
Supported algorithms:
ES256 - ECDSA with P-256 curve and SHA-256 (recommended)
RS256 - RSA with SHA-256
tags: []
links: []
usage: supabase gen signing-key [flags]
subcommands: []
flags:
- id: algorithm
name: --algorithm <[ RS256 | ES256 ]>
description: Algorithm for signing key generation.
default_value: ES256
accepted_values:
- id: RS256
name: RS256
type: '[ RS256 | ES256 ]'
- id: ES256
name: ES256
type: '[ RS256 | ES256 ]'
- id: append
name: --append
description: Append new key to existing keys file instead of overwriting.
default_value: 'false'
- id: supabase-gen-keys
title: supabase gen keys
summary: Generate keys for preview branch
@@ -3572,6 +3602,10 @@ commands:
- id: xlarge
name: xlarge
type: string
- id: with-data
name: --with-data
description: Whether to clone production data to the branch database.
default_value: 'false'
- id: experimental
name: --experimental
description: enable experimental features
File diff suppressed because it is too large. Load diff
@@ -22,7 +22,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 45,
"line": 46,
"character": 2
}
],
@@ -41,7 +41,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 46,
"line": 47,
"character": 2
}
],
@@ -60,7 +60,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 47,
"line": 48,
"character": 2
}
],
@@ -79,7 +79,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 48,
"line": 49,
"character": 2
}
],
@@ -98,7 +98,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 49,
"line": 50,
"character": 2
}
],
@@ -117,7 +117,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 50,
"line": 51,
"character": 2
}
],
@@ -136,7 +136,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 51,
"line": 52,
"character": 2
}
],
@@ -155,7 +155,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 52,
"line": 53,
"character": 2
}
],
@@ -174,7 +174,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 53,
"line": 54,
"character": 2
}
],
@@ -193,7 +193,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 54,
"line": 55,
"character": 2
}
],
@@ -212,7 +212,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 55,
"line": 56,
"character": 2
}
],
@@ -231,7 +231,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 56,
"line": 57,
"character": 2
}
],
@@ -250,7 +250,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 57,
"line": 58,
"character": 2
}
],
@@ -269,7 +269,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 58,
"line": 59,
"character": 2
}
],
@@ -288,7 +288,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 59,
"line": 60,
"character": 2
}
],
@@ -309,7 +309,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 44,
"line": 45,
"character": 12
}
]
@@ -1006,7 +1006,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 19,
"line": 20,
"character": 2
}
],
@@ -1080,7 +1080,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 18,
"line": 19,
"character": 2
}
],
@@ -1105,7 +1105,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 17,
"line": 18,
"character": 13
}
],
@@ -1151,7 +1151,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 27,
"line": 28,
"character": 2
}
],
@@ -1202,7 +1202,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 18,
"line": 19,
"character": 2
}
],
@@ -1232,7 +1232,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 26,
"line": 27,
"character": 13
}
],
@@ -1260,7 +1260,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 39,
"line": 40,
"character": 2
}
],
@@ -1311,7 +1311,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 18,
"line": 19,
"character": 2
}
],
@@ -1341,7 +1341,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 38,
"line": 39,
"character": 13
}
],
@@ -1369,7 +1369,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 33,
"line": 34,
"character": 2
}
],
@@ -1420,7 +1420,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 18,
"line": 19,
"character": 2
}
],
@@ -1450,7 +1450,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 32,
"line": 33,
"character": 13
}
],
@@ -1471,7 +1471,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 62,
"line": 63,
"character": 12
}
],
@@ -1498,7 +1498,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 78,
"line": 79,
"character": 2
}
],
@@ -1580,7 +1580,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 66,
"line": 67,
"character": 2
}
],
@@ -1595,7 +1595,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 66,
"line": 67,
"character": 12
}
],
@@ -1639,7 +1639,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 70,
"line": 71,
"character": 2
}
],
@@ -1683,7 +1683,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 74,
"line": 75,
"character": 2
}
],
@@ -1704,7 +1704,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 62,
"line": 63,
"character": 36
}
]
@@ -1720,7 +1720,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 15,
"line": 16,
"character": 12
}
],
@@ -22,7 +22,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 45,
"line": 46,
"character": 2
}
],
@@ -41,7 +41,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 46,
"line": 47,
"character": 2
}
],
@@ -60,7 +60,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 47,
"line": 48,
"character": 2
}
],
@@ -79,7 +79,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 48,
"line": 49,
"character": 2
}
],
@@ -98,7 +98,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 49,
"line": 50,
"character": 2
}
],
@@ -117,7 +117,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 50,
"line": 51,
"character": 2
}
],
@@ -136,7 +136,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 51,
"line": 52,
"character": 2
}
],
@@ -155,7 +155,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 52,
"line": 53,
"character": 2
}
],
@@ -174,7 +174,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 53,
"line": 54,
"character": 2
}
],
@@ -193,7 +193,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 54,
"line": 55,
"character": 2
}
],
@@ -212,7 +212,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 55,
"line": 56,
"character": 2
}
],
@@ -231,7 +231,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 56,
"line": 57,
"character": 2
}
],
@@ -250,7 +250,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 57,
"line": 58,
"character": 2
}
],
@@ -269,7 +269,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 58,
"line": 59,
"character": 2
}
],
@@ -288,7 +288,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 59,
"line": 60,
"character": 2
}
],
@@ -309,7 +309,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 44,
"line": 45,
"character": 12
}
]
@@ -591,7 +591,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 45,
"line": 46,
"character": 2
}
],
@@ -610,7 +610,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 46,
"line": 47,
"character": 2
}
],
@@ -629,7 +629,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 47,
"line": 48,
"character": 2
}
],
@@ -648,7 +648,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 48,
"line": 49,
"character": 2
}
],
@@ -667,7 +667,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 49,
"line": 50,
"character": 2
}
],
@@ -686,7 +686,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 50,
"line": 51,
"character": 2
}
],
@@ -705,7 +705,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 51,
"line": 52,
"character": 2
}
],
@@ -724,7 +724,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 52,
"line": 53,
"character": 2
}
],
@@ -743,7 +743,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 53,
"line": 54,
"character": 2
}
],
@@ -762,7 +762,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 54,
"line": 55,
"character": 2
}
],
@@ -781,7 +781,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 55,
"line": 56,
"character": 2
}
],
@@ -800,7 +800,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 56,
"line": 57,
"character": 2
}
],
@@ -819,7 +819,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 57,
"line": 58,
"character": 2
}
],
@@ -838,7 +838,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 58,
"line": 59,
"character": 2
}
],
@@ -857,7 +857,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 59,
"line": 60,
"character": 2
}
],
@@ -880,7 +880,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 44,
"line": 45,
"character": 12
}
]
@@ -1131,7 +1131,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 45,
"line": 46,
"character": 2
}
],
@@ -1150,7 +1150,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 46,
"line": 47,
"character": 2
}
],
@@ -1169,7 +1169,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 47,
"line": 48,
"character": 2
}
],
@@ -1188,7 +1188,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 48,
"line": 49,
"character": 2
}
],
@@ -1207,7 +1207,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 49,
"line": 50,
"character": 2
}
],
@@ -1226,7 +1226,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 50,
"line": 51,
"character": 2
}
],
@@ -1245,7 +1245,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 51,
"line": 52,
"character": 2
}
],
@@ -1264,7 +1264,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 52,
"line": 53,
"character": 2
}
],
@@ -1283,7 +1283,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 53,
"line": 54,
"character": 2
}
],
@@ -1302,7 +1302,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 54,
"line": 55,
"character": 2
}
],
@@ -1321,7 +1321,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 55,
"line": 56,
"character": 2
}
],
@@ -1340,7 +1340,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 56,
"line": 57,
"character": 2
}
],
@@ -1359,7 +1359,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 57,
"line": 58,
"character": 2
}
],
@@ -1378,7 +1378,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 58,
"line": 59,
"character": 2
}
],
@@ -1397,7 +1397,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 59,
"line": 60,
"character": 2
}
],
@@ -1418,7 +1418,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 44,
"line": 45,
"character": 12
}
]
@@ -1518,7 +1518,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 62,
"line": 63,
"character": 12
}
],
@@ -1545,7 +1545,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 78,
"line": 79,
"character": 2
}
],
@@ -1627,7 +1627,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 66,
"line": 67,
"character": 2
}
],
@@ -1642,7 +1642,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 66,
"line": 67,
"character": 12
}
],
@@ -1686,7 +1686,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 70,
"line": 71,
"character": 2
}
],
@@ -1730,7 +1730,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 74,
"line": 75,
"character": 2
}
],
@@ -1754,7 +1754,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 45,
"line": 46,
"character": 2
}
],
@@ -1773,7 +1773,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 46,
"line": 47,
"character": 2
}
],
@@ -1792,7 +1792,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 47,
"line": 48,
"character": 2
}
],
@@ -1811,7 +1811,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 48,
"line": 49,
"character": 2
}
],
@@ -1830,7 +1830,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 49,
"line": 50,
"character": 2
}
],
@@ -1849,7 +1849,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 50,
"line": 51,
"character": 2
}
],
@@ -1868,7 +1868,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 51,
"line": 52,
"character": 2
}
],
@@ -1887,7 +1887,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 52,
"line": 53,
"character": 2
}
],
@@ -1906,7 +1906,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 53,
"line": 54,
"character": 2
}
],
@@ -1925,7 +1925,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 54,
"line": 55,
"character": 2
}
],
@@ -1944,7 +1944,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 55,
"line": 56,
"character": 2
}
],
@@ -1963,7 +1963,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 56,
"line": 57,
"character": 2
}
],
@@ -1982,7 +1982,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 57,
"line": 58,
"character": 2
}
],
@@ -2001,7 +2001,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 58,
"line": 59,
"character": 2
}
],
@@ -2020,7 +2020,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 59,
"line": 60,
"character": 2
}
],
@@ -2043,7 +2043,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 44,
"line": 45,
"character": 12
}
]
@@ -2061,7 +2061,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 62,
"line": 63,
"character": 36
}
]
@@ -2183,7 +2183,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 19,
"line": 20,
"character": 2
}
],
@@ -2257,7 +2257,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 18,
"line": 19,
"character": 2
}
],
@@ -2282,7 +2282,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 17,
"line": 18,
"character": 13
}
],
@@ -2328,7 +2328,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 27,
"line": 28,
"character": 2
}
],
@@ -2379,7 +2379,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 18,
"line": 19,
"character": 2
}
],
@@ -2409,7 +2409,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 26,
"line": 27,
"character": 13
}
],
@@ -2437,7 +2437,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 39,
"line": 40,
"character": 2
}
],
@@ -2488,7 +2488,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 18,
"line": 19,
"character": 2
}
],
@@ -2518,7 +2518,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 38,
"line": 39,
"character": 13
}
],
@@ -2546,7 +2546,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 33,
"line": 34,
"character": 2
}
],
@@ -2597,7 +2597,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 18,
"line": 19,
"character": 2
}
],
@@ -2627,7 +2627,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 32,
"line": 33,
"character": 13
}
],
@@ -2648,7 +2648,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 62,
"line": 63,
"character": 12
}
],
@@ -2675,7 +2675,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 78,
"line": 79,
"character": 2
}
],
@@ -2757,7 +2757,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 66,
"line": 67,
"character": 2
}
],
@@ -2772,7 +2772,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 66,
"line": 67,
"character": 12
}
],
@@ -2816,7 +2816,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 70,
"line": 71,
"character": 2
}
],
@@ -2860,7 +2860,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 74,
"line": 75,
"character": 2
}
],
@@ -2884,7 +2884,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 45,
"line": 46,
"character": 2
}
],
@@ -2903,7 +2903,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 46,
"line": 47,
"character": 2
}
],
@@ -2922,7 +2922,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 47,
"line": 48,
"character": 2
}
],
@@ -2941,7 +2941,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 48,
"line": 49,
"character": 2
}
],
@@ -2960,7 +2960,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 49,
"line": 50,
"character": 2
}
],
@@ -2979,7 +2979,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 50,
"line": 51,
"character": 2
}
],
@@ -2998,7 +2998,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 51,
"line": 52,
"character": 2
}
],
@@ -3017,7 +3017,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 52,
"line": 53,
"character": 2
}
],
@@ -3036,7 +3036,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 53,
"line": 54,
"character": 2
}
],
@@ -3055,7 +3055,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 54,
"line": 55,
"character": 2
}
],
@@ -3074,7 +3074,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 55,
"line": 56,
"character": 2
}
],
@@ -3093,7 +3093,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 56,
"line": 57,
"character": 2
}
],
@@ -3112,7 +3112,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 57,
"line": 58,
"character": 2
}
],
@@ -3131,7 +3131,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 58,
"line": 59,
"character": 2
}
],
@@ -3150,7 +3150,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 59,
"line": 60,
"character": 2
}
],
@@ -3171,7 +3171,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 44,
"line": 45,
"character": 12
}
]
@@ -3189,7 +3189,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 62,
"line": 63,
"character": 36
}
]
@@ -3205,7 +3205,7 @@
"sources": [
{
"fileName": "src/types.ts",
"line": 15,
"line": 16,
"character": 12
}
],
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
File diff suppressed because it is too large. Load diff
@@ -386,8 +386,10 @@
}
],
"type": {
"type": "intrinsic",
"name": "string"
"type": "reference",
"qualifiedName": "URL",
"package": "typescript",
"name": "URL"
}
},
{
@@ -518,8 +520,10 @@
}
],
"type": {
"type": "intrinsic",
"name": "string"
"type": "reference",
"qualifiedName": "URL",
"package": "typescript",
"name": "URL"
}
},
{
@@ -590,8 +594,10 @@
}
],
"type": {
"type": "intrinsic",
"name": "string"
"type": "reference",
"qualifiedName": "URL",
"package": "typescript",
"name": "URL"
}
},
{
@@ -669,8 +675,10 @@
}
],
"type": {
"type": "intrinsic",
"name": "string"
"type": "reference",
"qualifiedName": "URL",
"package": "typescript",
"name": "URL"
}
},
{
@@ -708,7 +716,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 139,
"line": 141,
"character": 6
}
],
@@ -740,7 +748,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 149,
"line": 151,
"character": 6
}
],
@@ -774,7 +782,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 269,
"line": 271,
"character": 16
}
],
@@ -820,7 +828,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 329,
"line": 331,
"character": 10
}
],
@@ -897,7 +905,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 315,
"line": 317,
"character": 10
}
],
@@ -943,7 +951,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 279,
"line": 281,
"character": 10
}
],
@@ -1094,7 +1102,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 322,
"line": 324,
"character": 10
}
],
@@ -1127,7 +1135,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 241,
"line": 243,
"character": 2
}
],
@@ -1192,7 +1200,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 154,
"line": 156,
"character": 2
}
],
@@ -1414,7 +1422,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 248,
"line": 250,
"character": 2
}
],
@@ -1449,7 +1457,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 265,
"line": 267,
"character": 2
}
],
@@ -1503,7 +1511,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 258,
"line": 260,
"character": 2
}
],
@@ -1572,7 +1580,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 212,
"line": 214,
"character": 2
}
],
@@ -1682,7 +1690,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 218,
"line": 220,
"character": 6
}
],
@@ -1718,7 +1726,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 217,
"line": 219,
"character": 6
}
],
@@ -1741,7 +1749,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 216,
"line": 218,
"character": 6
}
],
@@ -1887,7 +1895,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 178,
"line": 180,
"character": 2
}
],
@@ -3265,6 +3273,46 @@
}
]
},
{
"id": 56,
"name": "ensureTrailingSlash",
"kind": 64,
"kindString": "Function",
"flags": {},
"sources": [
{
"fileName": "src/lib/helpers.ts",
"line": 12,
"character": 16
}
],
"signatures": [
{
"id": 57,
"name": "ensureTrailingSlash",
"kind": 4096,
"kindString": "Call signature",
"flags": {},
"parameters": [
{
"id": 58,
"name": "url",
"kind": 32768,
"kindString": "Parameter",
"flags": {},
"type": {
"type": "intrinsic",
"name": "string"
}
}
],
"type": {
"type": "intrinsic",
"name": "string"
}
}
]
},
{
"id": 65,
"name": "isBrowser",
@@ -3292,46 +3340,6 @@
}
]
},
{
"id": 56,
"name": "stripTrailingSlash",
"kind": 64,
"kindString": "Function",
"flags": {},
"sources": [
{
"fileName": "src/lib/helpers.ts",
"line": 12,
"character": 16
}
],
"signatures": [
{
"id": 57,
"name": "stripTrailingSlash",
"kind": 4096,
"kindString": "Call signature",
"flags": {},
"parameters": [
{
"id": 58,
"name": "url",
"kind": 32768,
"kindString": "Parameter",
"flags": {},
"type": {
"type": "intrinsic",
"name": "string"
}
}
],
"type": {
"type": "intrinsic",
"name": "string"
}
}
]
},
{
"id": 54,
"name": "uuid",
@@ -3364,7 +3372,7 @@
{
"title": "Functions",
"kind": 64,
"children": [59, 65, 56, 54]
"children": [59, 56, 65, 54]
}
],
"sources": [
@@ -971,8 +971,10 @@
}
],
"type": {
"type": "intrinsic",
"name": "string"
"type": "reference",
"qualifiedName": "URL",
"package": "typescript",
"name": "URL"
}
},
{
@@ -1103,8 +1105,10 @@
}
],
"type": {
"type": "intrinsic",
"name": "string"
"type": "reference",
"qualifiedName": "URL",
"package": "typescript",
"name": "URL"
}
},
{
@@ -1175,8 +1179,10 @@
}
],
"type": {
"type": "intrinsic",
"name": "string"
"type": "reference",
"qualifiedName": "URL",
"package": "typescript",
"name": "URL"
}
},
{
@@ -1254,8 +1260,10 @@
}
],
"type": {
"type": "intrinsic",
"name": "string"
"type": "reference",
"qualifiedName": "URL",
"package": "typescript",
"name": "URL"
}
},
{
@@ -1293,7 +1301,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 139,
"line": 141,
"character": 6
}
],
@@ -1325,7 +1333,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 149,
"line": 151,
"character": 6
}
],
@@ -1359,7 +1367,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 269,
"line": 271,
"character": 16
}
],
@@ -1405,7 +1413,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 329,
"line": 331,
"character": 10
}
],
@@ -1482,7 +1490,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 315,
"line": 317,
"character": 10
}
],
@@ -1528,7 +1536,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 279,
"line": 281,
"character": 10
}
],
@@ -1699,7 +1707,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 322,
"line": 324,
"character": 10
}
],
@@ -1732,7 +1740,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 241,
"line": 243,
"character": 2
}
],
@@ -1797,7 +1805,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 154,
"line": 156,
"character": 2
}
],
@@ -2021,7 +2029,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 248,
"line": 250,
"character": 2
}
],
@@ -2056,7 +2064,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 265,
"line": 267,
"character": 2
}
],
@@ -2110,7 +2118,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 258,
"line": 260,
"character": 2
}
],
@@ -2179,7 +2187,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 212,
"line": 214,
"character": 2
}
],
@@ -2290,7 +2298,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 218,
"line": 220,
"character": 6
}
],
@@ -2326,7 +2334,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 217,
"line": 219,
"character": 6
}
],
@@ -2349,7 +2357,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 216,
"line": 218,
"character": 6
}
],
@@ -2495,7 +2503,7 @@
"sources": [
{
"fileName": "src/SupabaseClient.ts",
"line": 178,
"line": 180,
"character": 2
}
],
@@ -5629,6 +5637,46 @@
}
]
},
{
"id": 56,
"name": "ensureTrailingSlash",
"kind": 64,
"kindString": "Function",
"flags": {},
"sources": [
{
"fileName": "src/lib/helpers.ts",
"line": 12,
"character": 16
}
],
"signatures": [
{
"id": 57,
"name": "ensureTrailingSlash",
"kind": 4096,
"kindString": "Call signature",
"flags": {},
"parameters": [
{
"id": 58,
"name": "url",
"kind": 32768,
"kindString": "Parameter",
"flags": {},
"type": {
"type": "intrinsic",
"name": "string"
}
}
],
"type": {
"type": "intrinsic",
"name": "string"
}
}
]
},
{
"id": 65,
"name": "isBrowser",
@@ -5656,46 +5704,6 @@
}
]
},
{
"id": 56,
"name": "stripTrailingSlash",
"kind": 64,
"kindString": "Function",
"flags": {},
"sources": [
{
"fileName": "src/lib/helpers.ts",
"line": 12,
"character": 16
}
],
"signatures": [
{
"id": 57,
"name": "stripTrailingSlash",
"kind": 4096,
"kindString": "Call signature",
"flags": {},
"parameters": [
{
"id": 58,
"name": "url",
"kind": 32768,
"kindString": "Parameter",
"flags": {},
"type": {
"type": "intrinsic",
"name": "string"
}
}
],
"type": {
"type": "intrinsic",
"name": "string"
}
}
]
},
{
"id": 54,
"name": "uuid",
@@ -5728,7 +5736,7 @@
{
"title": "Functions",
"kind": 64,
"children": [59, 65, 56, 54]
"children": [59, 56, 65, 54]
}
],
"sources": [
+552 -1
View File
@@ -129,6 +129,7 @@
"name": { "type": "string", "examples": ["avatars"] },
"id": { "type": "string", "examples": ["avatars"] },
"public": { "type": "boolean", "examples": [false] },
"type": { "type": "string", "enum": ["STANDARD", "ANALYTICS"] },
"file_size_limit": {
"anyOf": [
{ "type": "integer", "examples": [1000], "nullable": true, "minimum": 0 },
@@ -185,6 +186,39 @@
"summary": "Gets all buckets",
"tags": ["bucket"],
"parameters": [
{
"schema": { "type": "integer", "minimum": 1 },
"example": 10,
"in": "query",
"name": "limit",
"required": false
},
{
"schema": { "type": "integer", "minimum": 0 },
"example": 0,
"in": "query",
"name": "offset",
"required": false
},
{
"schema": { "type": "string", "enum": ["id", "name", "created_at", "updated_at"] },
"in": "query",
"name": "sortColumn",
"required": false
},
{
"schema": { "type": "string", "enum": ["asc", "desc"] },
"in": "query",
"name": "sortOrder",
"required": false
},
{
"schema": { "type": "string" },
"example": "my-bucket",
"in": "query",
"name": "search",
"required": false
},
{
"schema": { "type": "string" },
"example": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZS1kZW1vIiwicm9sZSI6ImFub24ifQ.625_WdcF3KHqz5amU0x2X5WWHP-OEs_4qj0ssLNHzTs",
@@ -207,7 +241,9 @@
"id": { "type": "string" },
"name": { "type": "string" },
"owner": { "type": "string" },
"owner_id": { "type": "string" },
"public": { "type": "boolean" },
"type": { "type": "string", "enum": ["STANDARD", "ANALYTICS"] },
"file_size_limit": { "type": ["null", "integer"] },
"allowed_mime_types": {
"type": ["null", "array"],
@@ -236,6 +272,7 @@
"example": [
{
"id": "avatars",
"type": "STANDARD",
"name": "avatars",
"owner": "4d56e902-f0a0-4662-8448-a4d9e643c142",
"public": false,
@@ -288,7 +325,12 @@
"description": "Successful response",
"type": "object",
"properties": {
"message": { "type": "string", "examples": ["Successfully emptied"] }
"message": {
"type": "string",
"examples": [
"Empty bucket has been queued. Completion may take up to an hour."
]
}
}
}
}
@@ -337,7 +379,9 @@
"id": { "type": "string" },
"name": { "type": "string" },
"owner": { "type": "string" },
"owner_id": { "type": "string" },
"public": { "type": "boolean" },
"type": { "type": "string", "enum": ["STANDARD", "ANALYTICS"] },
"file_size_limit": { "type": ["null", "integer"] },
"allowed_mime_types": {
"type": ["null", "array"],
@@ -743,7 +787,9 @@
"id": { "type": "string" },
"name": { "type": "string" },
"owner": { "type": "string" },
"owner_id": { "type": "string" },
"public": { "type": "boolean" },
"type": { "type": "string", "enum": ["STANDARD", "ANALYTICS"] },
"file_size_limit": { "type": ["null", "integer"] },
"allowed_mime_types": {
"type": ["null", "array"],
@@ -1324,7 +1370,9 @@
"id": { "type": "string" },
"name": { "type": "string" },
"owner": { "type": "string" },
"owner_id": { "type": "string" },
"public": { "type": "boolean" },
"type": { "type": "string", "enum": ["STANDARD", "ANALYTICS"] },
"file_size_limit": { "type": ["null", "integer"] },
"allowed_mime_types": {
"type": ["null", "array"],
@@ -1525,7 +1573,9 @@
"id": { "type": "string" },
"name": { "type": "string" },
"owner": { "type": "string" },
"owner_id": { "type": "string" },
"public": { "type": "boolean" },
"type": { "type": "string", "enum": ["STANDARD", "ANALYTICS"] },
"file_size_limit": { "type": ["null", "integer"] },
"allowed_mime_types": {
"type": ["null", "array"],
@@ -1838,11 +1888,512 @@
"/s3/": {
"get": { "tags": ["s3"], "responses": { "200": { "description": "Default Response" } } }
},
"/cdn/{bucketName}/{wildcard}": {
"delete": {
"summary": "Purge cache for an object",
"tags": ["object"],
"parameters": [
{
"schema": { "type": "string" },
"example": "avatars",
"in": "path",
"name": "bucketName",
"required": true
},
{
"schema": { "type": "string" },
"example": "folder/cat.png",
"in": "path",
"name": "*",
"required": true
},
{
"schema": { "type": "string" },
"example": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZS1kZW1vIiwicm9sZSI6ImFub24ifQ.625_WdcF3KHqz5amU0x2X5WWHP-OEs_4qj0ssLNHzTs",
"in": "header",
"name": "authorization",
"required": true
}
],
"responses": {
"200": {
"description": "Successful response",
"content": {
"application/json": {
"schema": {
"description": "Successful response",
"type": "object",
"properties": { "message": { "type": "string", "examples": ["success"] } }
}
}
}
},
"4XX": {
"description": "Error response",
"content": {
"application/json": {
"schema": { "description": "Error response", "$ref": "#/components/schemas/def-1" }
}
}
}
}
}
},
"/health/": {
"get": {
"summary": "healthcheck",
"responses": { "200": { "description": "Default Response" } }
}
},
"/iceberg/v1/config": {
"get": {
"summary": "Get Iceberg catalog configuration",
"tags": ["iceberg"],
"parameters": [
{
"schema": { "type": "string" },
"example": "my-warehouse",
"in": "query",
"name": "warehouse",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
}
},
"/iceberg/v1/{prefix}/namespaces": {
"post": {
"summary": "Create a namespace",
"tags": ["iceberg"],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": { "namespace": { "type": "string", "examples": ["namespace"] } },
"required": ["namespace"]
}
}
},
"required": true
},
"parameters": [
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
},
"get": {
"summary": "List namespaces",
"tags": ["iceberg"],
"parameters": [
{ "schema": { "type": "string" }, "in": "query", "name": "pageToken", "required": false },
{ "schema": { "type": "number" }, "in": "query", "name": "pageSize", "required": false },
{ "schema": { "type": "string" }, "in": "query", "name": "parent", "required": false },
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
}
},
"/iceberg/v1/{prefix}/namespaces/{namespace}": {
"get": {
"summary": "Load a namespace",
"tags": ["iceberg"],
"parameters": [
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": { "type": "string" },
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
},
"delete": {
"summary": "Create a namespace",
"tags": ["iceberg"],
"parameters": [
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": { "type": "string" },
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
}
},
"/iceberg/v1/{prefix}/namespaces/{namespace}/tables": {
"post": {
"summary": "Create a table in the given namespace",
"tags": ["iceberg"],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"required": ["name", "schema"],
"properties": {
"name": { "type": "string" },
"location": { "type": "string", "format": "uri", "nullable": true },
"schema": {
"allOf": [
{
"type": "object",
"required": ["type", "fields"],
"properties": {
"type": { "type": "string", "enum": ["struct"] },
"fields": {
"type": "array",
"items": {
"type": "object",
"required": ["id", "name", "type", "required"],
"properties": {
"id": { "type": "integer" },
"name": { "type": "string" },
"type": {
"oneOf": [
{ "type": "string" },
{
"type": "object",
"required": ["type", "fields"],
"properties": {
"type": { "type": "string", "enum": ["struct"] },
"fields": {
"type": "array",
"items": {
"$comment": "recurse nested StructField definitions here"
}
}
}
},
{
"type": "object",
"required": [
"type",
"element-id",
"element",
"element-required"
],
"properties": {
"type": { "type": "string", "enum": ["list"] },
"element-id": { "type": "integer" },
"element": { "$comment": "Type object (recurse)" },
"element-required": { "type": "boolean" }
}
},
{
"type": "object",
"required": [
"type",
"key-id",
"key",
"value-id",
"value",
"value-required"
],
"properties": {
"type": { "type": "string", "enum": ["map"] },
"key-id": { "type": "integer" },
"key": { "$comment": "Type object (recurse)" },
"value-id": { "type": "integer" },
"value": { "$comment": "Type object (recurse)" },
"value-required": { "type": "boolean" }
}
}
]
},
"required": { "type": "boolean" },
"doc": { "type": "string" }
}
}
}
}
},
{
"type": "object",
"properties": {
"schema-id": { "type": "integer", "readOnly": true },
"identifier-field-ids": {
"type": "array",
"items": { "type": "integer" }
}
}
}
]
},
"spec": {
"type": "object",
"required": ["fields"],
"properties": {
"spec-id": { "type": "integer", "readOnly": true },
"fields": {
"type": "array",
"items": {
"type": "object",
"required": ["source-id", "transform", "name"],
"properties": {
"field-id": { "type": "integer" },
"source-id": { "type": "integer" },
"name": { "type": "string" },
"transform": { "type": "string" }
}
}
}
}
},
"properties": { "type": "object", "additionalProperties": { "type": "string" } },
"stage-create": { "type": "boolean", "default": false },
"write-order": {
"type": "object",
"nullable": true,
"required": ["fields"],
"properties": {
"order-id": { "type": "integer", "readOnly": true },
"fields": {
"type": "array",
"items": {
"type": "object",
"required": ["source-id", "transform", "direction", "null-order"],
"properties": {
"source-id": { "type": "integer" },
"transform": { "type": "string" },
"direction": { "type": "string", "enum": ["asc", "desc"] },
"null-order": {
"type": "string",
"enum": ["nulls-first", "nulls-last"]
}
}
}
}
}
}
}
}
}
},
"required": true
},
"parameters": [
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "namespace",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
},
"get": {
"summary": "Create a namespace",
"tags": ["iceberg"],
"parameters": [
{ "schema": { "type": "string" }, "in": "query", "name": "pageToken", "required": false },
{ "schema": { "type": "number" }, "in": "query", "name": "pageSize", "required": false },
{ "schema": { "type": "string" }, "in": "query", "name": "parent", "required": false },
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": { "type": "string" },
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
}
},
"/iceberg/v1/{prefix}/namespaces/{namespace}/tables/{table}": {
"get": {
"summary": "Load an Iceberg Table",
"tags": ["iceberg"],
"parameters": [
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": { "type": "string" },
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
},
{
"schema": { "type": "string" },
"example": "table",
"in": "path",
"name": "table",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
},
"post": {
"summary": "Commit updates to multiple tables in an atomic operation",
"tags": ["iceberg"],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"description": "Commit updates to multiple tables in an atomic operation",
"properties": {
"requirements": {
"type": "array",
"description": "Assertions to validate before applying updates",
"items": {
"type": "object",
"description": "A requirement assertion",
"properties": {
"name": {
"type": "string",
"description": "Name of the requirement (e.g. assert-ref-snapshot-id)",
"examples": ["assert-ref-snapshot-id"]
},
"args": {
"type": "object",
"description": "Arguments for the requirement",
"additionalProperties": true
}
}
}
},
"updates": {
"type": "array",
"description": "Metadata updates to apply to the table",
"items": {
"type": "object",
"description": "A single update operation",
"properties": {
"name": {
"type": "string",
"description": "Name of the update operation (e.g. add-column)",
"examples": ["add-column"]
},
"args": {
"type": "object",
"description": "Arguments for the update operation",
"additionalProperties": true
}
}
}
}
},
"required": ["updates", "requirements"]
}
}
},
"required": true
},
"parameters": [
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": { "type": "string" },
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
},
{
"schema": { "type": "string" },
"example": "table",
"in": "path",
"name": "table",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
},
"delete": {
"summary": "Drop a Table",
"tags": ["iceberg"],
"parameters": [
{
"schema": {
"type": "string",
"enum": ["true", "false", "True", "False"],
"default": "false"
},
"in": "query",
"name": "purgeRequested",
"required": false,
"description": "If true, the table will be permanently deleted"
},
{
"schema": { "type": "string" },
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": { "type": "string" },
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
},
{
"schema": { "type": "string" },
"example": "table",
"in": "path",
"name": "table",
"required": true
}
],
"responses": { "200": { "description": "Default Response" } }
}
}
},
"tags": [
+10 -2
View File
@@ -1095,7 +1095,15 @@ functions:
title: 'verifyOtp()'
$ref: '@supabase/auth-js.GoTrueClient.verifyOtp'
notes: |
- The `verifyOtp` method takes in different verification types. If a phone number is used, the type can either be `sms` or `phone_change`. If an email address is used, the type can be one of the following: `email`, `recovery`, `invite` or `email_change` (`signup` and `magiclink` types are deprecated).
- The `verifyOtp` method takes in different verification types.
- If a phone number is used, the type can either be:
1. `sms` – Used when verifying a one-time password (OTP) sent via SMS during sign-up or sign-in.
2. `phone_change` – Used when verifying an OTP sent to a new phone number during a phone number update process.
- If an email address is used, the type can be one of the following (note: `signup` and `magiclink` types are deprecated):
1. `email` – Used when verifying an OTP sent to the user's email during sign-up or sign-in.
2. `recovery` – Used when verifying an OTP sent for account recovery, typically after a password reset request.
3. `invite` – Used when verifying an OTP sent as part of an invitation to join a project or organization.
4. `email_change` – Used when verifying an OTP sent to a new email address during an email update process.
- The verification type used should be determined based on the corresponding auth method called before `verifyOtp` to sign up / sign-in a user.
- The `TokenHash` is contained in the [email templates](/docs/guides/auth/auth-email-templates) and can be used to sign in. You may wish to use the hash with Magic Links for the PKCE flow for Server Side Auth. See [this guide](/docs/guides/auth/server-side/email-based-auth-with-pkce-flow-for-ssr) for more details.
examples:
@@ -1653,7 +1661,7 @@ functions:
- Resends a signup confirmation, email change or phone change email to the user.
- Passwordless sign-ins can be resent by calling the `signInWithOtp()` method again.
- Password recovery emails can be resent by calling the `resetPasswordForEmail()` method again.
- This method will only resend an email or phone OTP to the user if there was an initial signup, email change or phone change request being made.
- This method will only resend an email or phone OTP to the user if there was an initial signup, email change or phone change request being made(note: For existing users signing in with OTP, you should use `signInWithOtp()` again to resend the OTP).
- You can specify a redirect url when you resend an email link using the `emailRedirectTo` option.
examples:
- id: resend-email-signup-confirmation
@@ -1039,6 +1039,16 @@
"pattern": "^[\\w-]+$",
"type": "string"
}
},
{
"name": "resource",
"required": false,
"in": "query",
"description": "Resource indicator for MCP (Model Context Protocol) clients",
"schema": {
"enum": ["https://api.supabase.io/mcp"],
"type": "string"
}
}
],
"responses": {
@@ -1088,6 +1098,11 @@
},
"refresh_token": {
"type": "string"
},
"resource": {
"type": "string",
"enum": ["https://api.supabase.io/mcp"],
"description": "Resource indicator for MCP (Model Context Protocol) clients"
}
},
"additionalProperties": false
@@ -1624,13 +1639,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
},
"inserted_at": {
@@ -1710,13 +1719,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
}
},
@@ -1763,13 +1766,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
},
"inserted_at": {
@@ -1956,13 +1953,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
}
}
@@ -2008,13 +1999,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
},
"inserted_at": {
@@ -2117,13 +2102,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
},
"inserted_at": {
@@ -2243,13 +2222,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
},
"inserted_at": {
@@ -4962,7 +4935,7 @@
"properties": {
"postgres_version": {
"type": "string",
"enum": ["15", "17", "17-oriole"]
"enum": ["13", "14", "15", "17", "17-oriole"]
},
"release_channel": {
"type": "string",
@@ -14663,6 +14636,11 @@
},
"refresh_token": {
"type": "string"
},
"resource": {
"type": "string",
"enum": ["https://api.supabase.io/mcp"],
"description": "Resource indicator for MCP (Model Context Protocol) clients"
}
},
"additionalProperties": false
@@ -14919,13 +14897,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
},
"inserted_at": {
@@ -14969,13 +14941,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
}
},
@@ -14996,13 +14962,7 @@
},
"secret_jwt_template": {
"type": "object",
"properties": {
"role": {
"type": "string",
"minLength": 1
}
},
"required": ["role"],
"additionalProperties": {},
"nullable": true
}
}
@@ -15581,7 +15541,7 @@
"properties": {
"postgres_version": {
"type": "string",
"enum": ["15", "17", "17-oriole"]
"enum": ["13", "14", "15", "17", "17-oriole"]
},
"release_channel": {
"type": "string",
@@ -197,6 +197,10 @@
"type": "boolean",
"examples": [false]
},
"type": {
"type": "string",
"enum": ["STANDARD", "ANALYTICS"]
},
"file_size_limit": {
"anyOf": [
{
@@ -287,6 +291,53 @@
"summary": "Gets all buckets",
"tags": ["bucket"],
"parameters": [
{
"schema": {
"type": "integer",
"minimum": 1
},
"example": 10,
"in": "query",
"name": "limit",
"required": false
},
{
"schema": {
"type": "integer",
"minimum": 0
},
"example": 0,
"in": "query",
"name": "offset",
"required": false
},
{
"schema": {
"type": "string",
"enum": ["id", "name", "created_at", "updated_at"]
},
"in": "query",
"name": "sortColumn",
"required": false
},
{
"schema": {
"type": "string",
"enum": ["asc", "desc"]
},
"in": "query",
"name": "sortOrder",
"required": false
},
{
"schema": {
"type": "string"
},
"example": "my-bucket",
"in": "query",
"name": "search",
"required": false
},
{
"schema": {
"type": "string"
@@ -317,9 +368,16 @@
"owner": {
"type": "string"
},
"owner_id": {
"type": "string"
},
"public": {
"type": "boolean"
},
"type": {
"type": "string",
"enum": ["STANDARD", "ANALYTICS"]
},
"file_size_limit": {
"type": ["null", "integer"]
},
@@ -356,6 +414,7 @@
"example": [
{
"id": "avatars",
"type": "STANDARD",
"name": "avatars",
"owner": "4d56e902-f0a0-4662-8448-a4d9e643c142",
"public": false,
@@ -430,7 +489,9 @@
"properties": {
"message": {
"type": "string",
"examples": ["Successfully emptied"]
"examples": [
"Empty bucket has been queued. Completion may take up to an hour."
]
}
}
}
@@ -506,9 +567,16 @@
"owner": {
"type": "string"
},
"owner_id": {
"type": "string"
},
"public": {
"type": "boolean"
},
"type": {
"type": "string",
"enum": ["STANDARD", "ANALYTICS"]
},
"file_size_limit": {
"type": ["null", "integer"]
},
@@ -1165,9 +1233,16 @@
"owner": {
"type": "string"
},
"owner_id": {
"type": "string"
},
"public": {
"type": "boolean"
},
"type": {
"type": "string",
"enum": ["STANDARD", "ANALYTICS"]
},
"file_size_limit": {
"type": ["null", "integer"]
},
@@ -2088,9 +2163,16 @@
"owner": {
"type": "string"
},
"owner_id": {
"type": "string"
},
"public": {
"type": "boolean"
},
"type": {
"type": "string",
"enum": ["STANDARD", "ANALYTICS"]
},
"file_size_limit": {
"type": ["null", "integer"]
},
@@ -2448,9 +2530,16 @@
"owner": {
"type": "string"
},
"owner_id": {
"type": "string"
},
"public": {
"type": "boolean"
},
"type": {
"type": "string",
"enum": ["STANDARD", "ANALYTICS"]
},
"file_size_limit": {
"type": ["null", "integer"]
},
@@ -3019,6 +3108,84 @@
}
}
},
"/cdn/{bucketName}/{wildcard}": {
"delete": {
"summary": "Purge cache for an object",
"tags": ["object"],
"parameters": [
{
"schema": {
"type": "string"
},
"example": "avatars",
"in": "path",
"name": "bucketName",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "folder/cat.png",
"in": "path",
"name": "*",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZS1kZW1vIiwicm9sZSI6ImFub24ifQ.625_WdcF3KHqz5amU0x2X5WWHP-OEs_4qj0ssLNHzTs",
"in": "header",
"name": "authorization",
"required": true
}
],
"responses": {
"200": {
"description": "Successful response",
"content": {
"application/json": {
"schema": {
"description": "Successful response",
"type": "object",
"properties": {
"message": {
"type": "string",
"examples": ["success"]
}
}
}
}
}
},
"4XX": {
"description": "Error response",
"content": {
"application/json": {
"schema": {
"description": "Error response",
"type": "object",
"properties": {
"statusCode": {
"type": "string"
},
"error": {
"type": "string"
},
"message": {
"type": "string"
}
},
"required": ["statusCode", "error", "message"],
"title": "errorSchema"
}
}
}
}
}
}
},
"/health/": {
"get": {
"summary": "healthcheck",
@@ -3028,6 +3195,661 @@
}
}
}
},
"/iceberg/v1/config": {
"get": {
"summary": "Get Iceberg catalog configuration",
"tags": ["iceberg"],
"parameters": [
{
"schema": {
"type": "string"
},
"example": "my-warehouse",
"in": "query",
"name": "warehouse",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/iceberg/v1/{prefix}/namespaces": {
"post": {
"summary": "Create a namespace",
"tags": ["iceberg"],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"namespace": {
"type": "string",
"examples": ["namespace"]
}
},
"required": ["namespace"]
}
}
},
"required": true
},
"parameters": [
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
},
"get": {
"summary": "List namespaces",
"tags": ["iceberg"],
"parameters": [
{
"schema": {
"type": "string"
},
"in": "query",
"name": "pageToken",
"required": false
},
{
"schema": {
"type": "number"
},
"in": "query",
"name": "pageSize",
"required": false
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "parent",
"required": false
},
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/iceberg/v1/{prefix}/namespaces/{namespace}": {
"get": {
"summary": "Load a namespace",
"tags": ["iceberg"],
"parameters": [
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
},
"delete": {
"summary": "Create a namespace",
"tags": ["iceberg"],
"parameters": [
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/iceberg/v1/{prefix}/namespaces/{namespace}/tables": {
"post": {
"summary": "Create a table in the given namespace",
"tags": ["iceberg"],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"required": ["name", "schema"],
"properties": {
"name": {
"type": "string"
},
"location": {
"type": "string",
"format": "uri",
"nullable": true
},
"schema": {
"allOf": [
{
"type": "object",
"required": ["type", "fields"],
"properties": {
"type": {
"type": "string",
"enum": ["struct"]
},
"fields": {
"type": "array",
"items": {
"type": "object",
"required": ["id", "name", "type", "required"],
"properties": {
"id": {
"type": "integer"
},
"name": {
"type": "string"
},
"type": {
"oneOf": [
{
"type": "string"
},
{
"type": "object",
"required": ["type", "fields"],
"properties": {
"type": {
"type": "string",
"enum": ["struct"]
},
"fields": {
"type": "array",
"items": {
"$comment": "recurse nested StructField definitions here"
}
}
}
},
{
"type": "object",
"required": [
"type",
"element-id",
"element",
"element-required"
],
"properties": {
"type": {
"type": "string",
"enum": ["list"]
},
"element-id": {
"type": "integer"
},
"element": {
"$comment": "Type object (recurse)"
},
"element-required": {
"type": "boolean"
}
}
},
{
"type": "object",
"required": [
"type",
"key-id",
"key",
"value-id",
"value",
"value-required"
],
"properties": {
"type": {
"type": "string",
"enum": ["map"]
},
"key-id": {
"type": "integer"
},
"key": {
"$comment": "Type object (recurse)"
},
"value-id": {
"type": "integer"
},
"value": {
"$comment": "Type object (recurse)"
},
"value-required": {
"type": "boolean"
}
}
}
]
},
"required": {
"type": "boolean"
},
"doc": {
"type": "string"
}
}
}
}
}
},
{
"type": "object",
"properties": {
"schema-id": {
"type": "integer",
"readOnly": true
},
"identifier-field-ids": {
"type": "array",
"items": {
"type": "integer"
}
}
}
}
]
},
"spec": {
"type": "object",
"required": ["fields"],
"properties": {
"spec-id": {
"type": "integer",
"readOnly": true
},
"fields": {
"type": "array",
"items": {
"type": "object",
"required": ["source-id", "transform", "name"],
"properties": {
"field-id": {
"type": "integer"
},
"source-id": {
"type": "integer"
},
"name": {
"type": "string"
},
"transform": {
"type": "string"
}
}
}
}
}
},
"properties": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"stage-create": {
"type": "boolean",
"default": false
},
"write-order": {
"type": "object",
"nullable": true,
"required": ["fields"],
"properties": {
"order-id": {
"type": "integer",
"readOnly": true
},
"fields": {
"type": "array",
"items": {
"type": "object",
"required": ["source-id", "transform", "direction", "null-order"],
"properties": {
"source-id": {
"type": "integer"
},
"transform": {
"type": "string"
},
"direction": {
"type": "string",
"enum": ["asc", "desc"]
},
"null-order": {
"type": "string",
"enum": ["nulls-first", "nulls-last"]
}
}
}
}
}
}
}
}
}
},
"required": true
},
"parameters": [
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "namespace",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
},
"get": {
"summary": "Create a namespace",
"tags": ["iceberg"],
"parameters": [
{
"schema": {
"type": "string"
},
"in": "query",
"name": "pageToken",
"required": false
},
{
"schema": {
"type": "number"
},
"in": "query",
"name": "pageSize",
"required": false
},
{
"schema": {
"type": "string"
},
"in": "query",
"name": "parent",
"required": false
},
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
},
"/iceberg/v1/{prefix}/namespaces/{namespace}/tables/{table}": {
"get": {
"summary": "Load an Iceberg Table",
"tags": ["iceberg"],
"parameters": [
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "table",
"in": "path",
"name": "table",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
},
"post": {
"summary": "Commit updates to multiple tables in an atomic operation",
"tags": ["iceberg"],
"requestBody": {
"content": {
"application/json": {
"schema": {
"type": "object",
"description": "Commit updates to multiple tables in an atomic operation",
"properties": {
"requirements": {
"type": "array",
"description": "Assertions to validate before applying updates",
"items": {
"type": "object",
"description": "A requirement assertion",
"properties": {
"name": {
"type": "string",
"description": "Name of the requirement (e.g. assert-ref-snapshot-id)",
"examples": ["assert-ref-snapshot-id"]
},
"args": {
"type": "object",
"description": "Arguments for the requirement",
"additionalProperties": true
}
}
}
},
"updates": {
"type": "array",
"description": "Metadata updates to apply to the table",
"items": {
"type": "object",
"description": "A single update operation",
"properties": {
"name": {
"type": "string",
"description": "Name of the update operation (e.g. add-column)",
"examples": ["add-column"]
},
"args": {
"type": "object",
"description": "Arguments for the update operation",
"additionalProperties": true
}
}
}
}
},
"required": ["updates", "requirements"]
}
}
},
"required": true
},
"parameters": [
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "table",
"in": "path",
"name": "table",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
},
"delete": {
"summary": "Drop a Table",
"tags": ["iceberg"],
"parameters": [
{
"schema": {
"type": "string",
"enum": ["true", "false", "True", "False"],
"default": "false"
},
"in": "query",
"name": "purgeRequested",
"required": false,
"description": "If true, the table will be permanently deleted"
},
{
"schema": {
"type": "string"
},
"example": "prefix",
"in": "path",
"name": "prefix",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "namespace",
"in": "path",
"name": "namespace",
"required": true
},
{
"schema": {
"type": "string"
},
"example": "table",
"in": "path",
"name": "table",
"required": true
}
],
"responses": {
"200": {
"description": "Default Response"
}
}
}
}
},
"components": {
+4
View File
@@ -40,12 +40,16 @@
"ASSET_CDN_S3_ENDPOINT",
"AWS_ACCESS_KEY_ID",
"AWS_SECRET_ACCESS_KEY",
"CI",
"DOCS_GITHUB_APP_ID",
"DOCS_GITHUB_APP_INSTALLATION_ID",
"DOCS_GITHUB_APP_PRIVATE_KEY",
"DOCS_REVALIDATION_KEYS",
"DOCS_REVALIDATION_OVERRIDE_KEYS",
"GITHUB_ACTIONS",
"FORCE_ASSET_CDN",
"LOGFLARE_INGESTION_API_KEY",
"LOGFLARE_SOURCE_TOKEN",
"OPENAI_API_KEY",
"SITE_NAME",
"SUPABASE_SECRET_KEY"
@@ -109,7 +109,7 @@ export const FilterPopoverPrimitive = ({
))}
{localFilters.length == 0 && (
<div className="space-y-1 px-3">
<h5 className="text-sm text-foreground-light">No filters applied to this view</h5>
<h5 className="text-foreground-light">No filters applied to this view</h5>
<p className="text-xs text-foreground-lighter">
Add a column below to filter the view
</p>
@@ -185,7 +185,7 @@ export const SortPopoverPrimitive = ({
))}
{localSorts.length === 0 && (
<div className="space-y-1 px-3">
<h5 className="text-sm text-foreground-light">No sorts applied to this view</h5>
<h5 className="text-foreground-light">No sorts applied to this view</h5>
<p className="text-xs text-foreground-lighter">Add a column below to sort the view</p>
</div>
)}
@@ -1,53 +1,8 @@
import { Alert_Shadcn_, AlertDescription_Shadcn_, AlertTitle_Shadcn_, Badge, Toggle } from 'ui'
import { ButtonTooltip } from 'components/ui/ButtonTooltip'
import { X } from 'lucide-react'
import { Toggle } from 'ui'
import { toast } from 'sonner'
import { useConsentState } from 'common'
import Panel from 'components/ui/Panel'
import { useSendResetMutation } from 'data/telemetry/send-reset-mutation'
import { useLocalStorageQuery } from 'hooks/misc/useLocalStorage'
import { LOCAL_STORAGE_KEYS } from 'common/constants/local-storage'
export const TermsUpdateBanner = () => {
const [termsUpdateAcknowledged, setTermsUpdateAcknowledged] = useLocalStorageQuery(
LOCAL_STORAGE_KEYS.TERMS_OF_SERVICE_ACKNOWLEDGED,
false
)
if (termsUpdateAcknowledged) return null
return (
<Alert_Shadcn_ className="mb-4 relative">
<AlertTitle_Shadcn_>
<Badge variant="default" className="mr-2">
NOTICE
</Badge>
Terms of Service Update – Effective Aug 1, 2025
</AlertTitle_Shadcn_>
<AlertDescription_Shadcn_>
We’ve updated our{' '}
<a href="https://supabase.com/terms" target="_blank" className="text hover:text-brand">
Terms of Service
</a>
. The new terms take effect on August 1, 2025 and reflect changes to support our evolving
business, legal requirements, and a new arbitration-based dispute resolution process.
Questions? Contact{' '}
<a href="mailto:legal@supabase.io" target="_blank" className="text hover:text-brand">
our team
</a>
.
</AlertDescription_Shadcn_>
<ButtonTooltip
type="text"
icon={<X />}
className="absolute top-2 right-2 px-1"
onClick={() => setTermsUpdateAcknowledged(true)}
tooltip={{ content: { side: 'bottom', text: 'Dismiss' } }}
/>
</Alert_Shadcn_>
)
}
export const AnalyticsSettings = () => {
const { hasAccepted, acceptAll, denyAll, categories } = useConsentState()
@@ -36,7 +36,7 @@ export const ProviderForm = ({ config, provider, isActive }: ProviderFormProps)
const [open, setOpen] = useState(false)
const { mutate: updateAuthConfig, isLoading: isUpdatingConfig } = useAuthConfigUpdateMutation()
const doubleNegativeKeys = ['MAILER_AUTOCONFIRM', 'SMS_AUTOCONFIRM']
const doubleNegativeKeys = ['SMS_AUTOCONFIRM']
const canUpdateConfig: boolean = useCheckPermissions(
PermissionAction.UPDATE,
'custom_config_gotrue'
@@ -19,11 +19,6 @@ const PROVIDER_EMAIL = {
description: 'This will enable Email based signup and login for your application',
type: 'boolean',
},
MAILER_AUTOCONFIRM: {
title: 'Confirm email',
description: `Users will need to confirm their email address before signing in for the first time.`,
type: 'boolean',
},
MAILER_SECURE_EMAIL_CHANGE_ENABLED: {
title: 'Secure email change',
description: `Users will be required to confirm any email change on both the old email address and new email address.
@@ -35,6 +35,7 @@ const schema = object({
DISABLE_SIGNUP: boolean().required(),
EXTERNAL_ANONYMOUS_USERS_ENABLED: boolean().required(),
SECURITY_MANUAL_LINKING_ENABLED: boolean().required(),
MAILER_AUTOCONFIRM: boolean().required(),
SITE_URL: string().required('Must have a Site URL'),
})
@@ -52,6 +53,7 @@ const BasicAuthSettingsForm = () => {
DISABLE_SIGNUP: true,
EXTERNAL_ANONYMOUS_USERS_ENABLED: false,
SECURITY_MANUAL_LINKING_ENABLED: false,
MAILER_AUTOCONFIRM: true,
SITE_URL: '',
},
})
@@ -61,7 +63,9 @@ const BasicAuthSettingsForm = () => {
form.reset({
DISABLE_SIGNUP: !authConfig.DISABLE_SIGNUP,
EXTERNAL_ANONYMOUS_USERS_ENABLED: authConfig.EXTERNAL_ANONYMOUS_USERS_ENABLED,
SECURITY_MANUAL_LINKING_ENABLED: authConfig.SECURITY_MANUAL_LINKING_ENABLED || false,
SECURITY_MANUAL_LINKING_ENABLED: authConfig.SECURITY_MANUAL_LINKING_ENABLED,
// The backend uses false to represent that email confirmation is required
MAILER_AUTOCONFIRM: !authConfig.MAILER_AUTOCONFIRM,
SITE_URL: authConfig.SITE_URL,
})
}
@@ -75,6 +79,9 @@ const BasicAuthSettingsForm = () => {
payload.PASSWORD_REQUIRED_CHARACTERS = ''
}
// The backend uses false to represent that email confirmation is required
payload.MAILER_AUTOCONFIRM = !values.MAILER_AUTOCONFIRM
updateAuthConfig(
{ projectRef: projectRef!, config: payload },
{
@@ -250,6 +257,27 @@ const BasicAuthSettingsForm = () => {
</Alert_Shadcn_>
)}
</CardContent>
<CardContent>
<FormField_Shadcn_
control={form.control}
name="MAILER_AUTOCONFIRM"
render={({ field }) => (
<FormItemLayout
layout="flex-row-reverse"
label="Confirm email"
description="Users will need to confirm their email address before signing in for the first time"
>
<FormControl_Shadcn_>
<Switch
checked={field.value}
onCheckedChange={field.onChange}
disabled={!canUpdateConfig}
/>
</FormControl_Shadcn_>
</FormItemLayout>
)}
/>
</CardContent>
<CardFooter className="justify-end space-x-2">
{form.formState.isDirty && (
<Button type="default" onClick={() => form.reset()}>
@@ -25,7 +25,7 @@ export const SpamValidation = ({ validationResult }: SpamValidationProps) => {
)}
</div>
<div className="flex flex-col gap-2">
<h5 className="text-sm">
<h5>
{hasSpamWarning
? 'Email has a high probability of being marked as spam - review issues below to improve deliverability.'
: 'Email content is unlikely to be marked as spam'}
@@ -10,7 +10,7 @@ import {
PolicyTableRow,
PolicyTableRowProps,
} from 'components/interfaces/Auth/Policies/PolicyTableRow'
import ProtectedSchemaWarning from 'components/interfaces/Database/ProtectedSchemaWarning'
import { ProtectedSchemaWarning } from 'components/interfaces/Database/ProtectedSchemaWarning'
import { useProjectContext } from 'components/layouts/ProjectLayout/ProjectContext'
import NoSearchResults from 'components/to-be-cleaned/NoSearchResults'
import ProductEmptyState from 'components/to-be-cleaned/ProductEmptyState'
Loaded 100 of 336 files, more files were not shown because too many files have changed in this diff. Show more