mirror of
https://github.com/supabase/supabase.git
synced 2026-12-04 15:39:13 +00:00
create-pull-request/patch
22196
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
cea3232469 |
Joshenlim/fe 5166 refactor pagelayout for auth api pages (#53716)
## Context Just some housekeeping to move off old layout components - this PR targets Auth and Settings pages, specifically - Auth -> Emails - Auth -> Providers - Settings -> API Keys - Settings -> JWT Keys - Settings -> Log Drains - Settings -> Read Replica/id The only visual change is just that navigation tabs take the full width of the viewport now Just need to make sure that these pages still render fine |
||
|
|
7e92210d31 |
Replace useUrlState with useQueryState, and deprecate (#53726)
## Context We've got a `useUrlState` hook that was written a long time ago, which is now deprecated and can be replaced with nuqs' `useQueryState` - so this PR cleans that up and deletes the hook. ## To test Just 2 surfaces in the dashboard that's affected - Project -> Settings -> Addons - [ ] Verify that opening/closing the addon panels toggle the panel URL param accordingly - Table Editor filters and sorts - [ ] Verify that landing on the editor with `?create=table` URL param opens the new table panel + removes the URL param - [ ] Verify that filter and sorts still work + including refreshing the browser should land back on the same state - [ ] Verify that renaming a column while there's a filter/sort applied for that column will also update the URL param |
||
|
|
4557c40bd1 |
docs: match the Laravel quickstart to the current project skeleton (#53796)
## Problem The Laravel quickstart has drifted from what `composer create-project laravel/laravel` generates today. Closes #53795. - Steps 2 and 4 link to the Laravel `12.x` docs. Laravel 13 is current. - Step 6 shows `'sslmode' => 'require'` hardcoded, but the generated `config/database.php` has read `sslmode` from `DB_SSLMODE` since [laravel/laravel#6727](https://github.com/laravel/laravel/pull/6727). - Step 5 says Laravel takes `sslmode` as a config option "rather than a URL parameter". A `?sslmode=` query on `DB_URL` works and overrides the config value. - The Laravel "Copy prompt" text never sets `sslmode`. ## Solution - Link to the unversioned Laravel docs so the links follow the current release. - Set `DB_SSLMODE=require` in the step 5 `.env` block and show the generated `sslmode` line unchanged in step 6. Step 6 is now a one-line `search_path` edit. - Remove the inaccurate sentence, and the paragraph that repeated the `prefer` and `require` guidance already given by the `quickstart_connection_string.mdx` partial. - Add `DB_SSLMODE=require` to the Laravel AI prompt. Tested on a fresh Laravel 13.43 app (PHP 8.5, Breeze 2.4.2) against Postgres 18 with SSL on: with the revised steps, `php artisan migrate` created all tables in the `laravel` schema, `pg_stat_ssl` showed the connection encrypted, and register and sign in worked. I tested against a local Postgres, not through the Supabase pooler. `prettier --check` passes on both files. I did not run the full docs build locally. ## Review instructions 1. Open the Laravel quickstart in the docs preview. 2. Check that the two Laravel docs links in steps 2 and 4 open the installation and authentication pages. 3. Run `composer create-project laravel/laravel example-app` and compare the `pgsql` block in `config/database.php` with step 6. Only `search_path` differs. 4. Click the AI prompt button and check that step 3 mentions `DB_SSLMODE=require`. ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) Checked against the style guide (voice, `WORD_LIST.md`, timeless documentation). |
||
|
|
70a9f46bad |
chore(docs) - add "change a region" to the regions page (#53032)
## Problem Missing from the regions page, but present at the bottom of https://supabase.com/docs/guides/platform/migrating-within-supabase#transfer-project-to-a-different-organization ## Solution Add to regions page. Most competitors have this as well: - https://planetscale.com/docs/plans/regions#changing-branch-and-database-regions - https://neon.com/docs/import/region-migration ## Preview links https://docs-git-docs-change-regions-supabase.vercel.app/docs/guides/platform/regions#change-a-region --------- Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> Co-authored-by: hallidayo <22655069+Hallidayo@users.noreply.github.com> |
||
|
|
d921af7a13 |
Rename Circuit to Annsa on the State of Startups page (#53246)
Replace Circuit with Annsa and update its link to https://annsa.ai in the State of Startups 2026 participant list. Keep the list in alphabetical order. I'm the founder. We took part in the survey as Circuit and have since renamed the company to Annsa. The old address, https://withcircuit.com, already redirects to https://annsa.ai. ## I have read the [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) file. YES ## What kind of change does this PR introduce? Content correction. ## What is the current behavior? The participant list displays Circuit and links to https://withcircuit.com. ## What is the new behavior? The participant list displays Annsa and links to https://annsa.ai. ## Additional context Same kind of change as #50583. It is a one-line data change in `apps/www/data/surveys/state-of-startups-participants.ts`. Prettier passes on the file with the repo's settings and the file type-checks. The Vercel check for zone-www-dot-com needs a team member to authorize the preview. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-authored-by: Claude Fable 5.2 <noreply@anthropic.com> Co-authored-by: hallidayo <22655069+Hallidayo@users.noreply.github.com> Co-authored-by: Nik Richers <nrichers@gmail.com> |
||
|
|
2d50251127 |
docs: fix serverless typo in connection pooling diagrams (#53418)
## Problem The light and dark connection pooling diagrams spell “serverless” as “severless” in both client labels. ## Solution Correct all four labels to “SERVERLESS” in the two existing PNG assets. Preserve the original lettering, colors, layout, and 1851 × 907 dimensions. ## Self-review Visually checked both images and compared decoded pixels against the originals. All changed pixels are confined to the client labels; the rest of each diagram is unchanged. `git diff --check` passes. No code or documentation references changed, so build and unit tests were not run. Co-authored-by: Nik Richers <nrichers@gmail.com> |
||
|
|
5c26d14813 |
docs(realtime): use public.rooms_users consistently in authorization examples (#53624)
## Problem The Realtime Authorization guide creates `public.rooms_users`, but two paragraphs call it `public.room_users`, and the six example policies on `realtime.messages` use the bare name `rooms_users`. Someone copying from the page sees two table names and has to guess which one is right. ## Solution - Fix the name in the two paragraphs (`room_users` to `rooms_users`). - Write `public.rooms_users` in the six example policies, the same name the `create table` at the top of the page uses. Qualifying the table is also one of the first things suggested when debugging a private-channel policy in supabase/realtime#1111, so the examples now match that advice. Docs only, no behavior change. This PR was prepared with AI assistance and reviewed before opening. Co-authored-by: Nik Richers <nrichers@gmail.com> |
||
|
|
f1e56e127f |
fix(docs): broadcast Realtime DELETE events to the record topic (#53579)
Closes #53584 ## Problem Two Realtime guides attach `realtime.broadcast_changes` triggers that fire on `DELETE`: - `apps/docs/content/guides/realtime/broadcast.mdx` — `your_table_changes`, used by a trigger declared `AFTER INSERT OR UPDATE OR DELETE` - `apps/docs/content/guides/realtime/getting_started.mdx` — `broadcast_message_changes`, used by a trigger declared `AFTER INSERT OR UPDATE OR DELETE` Both build the broadcast topic from the new row only: ```sql 'topic:' || NEW.id::text 'room:' || NEW.room_id::text || ':messages' ``` On `DELETE`, `NEW` is `NULL`, so the concatenation produces a `NULL` topic. `realtime.broadcast_changes` passes that to `realtime.send`, which inserts into `realtime.messages`. In `supabase/realtime`, `realtime.messages.topic` is `text not null`, and `realtime.send` wraps its insert in an exception handler that downgrades the failure to a warning: ```sql EXCEPTION WHEN OTHERS THEN RAISE WARNING 'WarnSendingBroadcastMessage: %', SQLERRM; ``` So the trigger succeeds, logs only a warning, and no `DELETE` message reaches subscribers. The sibling guide already handles this correctly: `subscribing-to-database-changes.mdx` uses `coalesce(NEW.id, OLD.id)`. ## Fix Use `coalesce(NEW.id, OLD.id)` in `broadcast.mdx` and `coalesce(NEW.room_id, OLD.room_id)` in `getting_started.mdx`, matching `subscribing-to-database-changes.mdx` so all three guides teach the same pattern. The `realtime.send` example in `getting_started.mdx` is unchanged because its trigger is `AFTER INSERT` only, where `NEW` is always present. One caveat: `coalesce` falls back to `OLD` whenever `NEW` is null, including an `UPDATE` that clears a nullable `room_id`. That broadcasts to the former room, where the `CASE` form would emit a null topic and send nothing. The example reads as if a message always belongs to a room; for a schema where `room_id` can be cleared, use `CASE WHEN TG_OP = 'DELETE' THEN OLD.room_id ELSE NEW.room_id END`. ## Verification I tested the exact edited SQL blocks against `supabase/postgres:17.6.1.143`, using the real `realtime.broadcast_changes` and `realtime.send` definitions from `supabase/realtime` and a `realtime.messages` table that keeps the production `topic text not null` constraint. Before the fix, running `INSERT`, `UPDATE`, then `DELETE` on the `getting_started.mdx` snippet: ```text WARNING: WarnSendingBroadcastMessage: syntax error at or near "NULL" event | topic | op --------+-----------------+-------- INSERT | room:7:messages | INSERT UPDATE | room:7:messages | UPDATE (2 rows) ``` After the fix, running insert, update body, update `room_id` to `NULL`, move to room 9, then delete: ```text event | topic | op | new_room | old_room --------+-----------------+--------+----------+---------- INSERT | room:7:messages | INSERT | 7 | UPDATE | room:7:messages | UPDATE | 7 | 7 UPDATE | room:7:messages | UPDATE | | 7 UPDATE | room:9:messages | UPDATE | 9 | DELETE | room:9:messages | DELETE | | 9 (5 rows) ``` The `room_id` to `NULL` update follows the caveat above; `INSERT`, a normal `UPDATE`, a room move, and `DELETE` all use the expected topic. The `broadcast.mdx` snippet produces `INSERT`/`UPDATE`/`DELETE` messages with `topic:<id>`. Prettier passes on both files. ## Authorship and review This PR is written by me. AI assisted with drafting and with setting up the test harness, but I reviewed and audited every change myself and I stand behind it. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: Nik Richers <nrichers@gmail.com> |
||
|
|
a74afc61cd |
docs(hypopg): fix function names in the functions list (#53514)
## Problem Three entries in the [HypoPG functions list](https://supabase.com/docs/guides/database/extensions/hypopg#functions) name functions that don't exist, so copying them fails with `function ... does not exist`: - `hypo_create_index(text)` is `hypopg_create_index(text)` (the example on the same page already uses it) - `hypopg_get_index_def(oid)` is `hypopg_get_indexdef(oid)` - `hypopg_get_relation_size(oid)` is `hypopg_relation_size(oid)` Source: [`hypopg--1.4.5.sql`](https://github.com/HypoPG/hypopg/blob/REL1_STABLE/hypopg--1.4.5.sql) and the upstream [usage docs](https://hypopg.readthedocs.io/en/rel1_stable/usage.html#manipulate-hypothetical-indexes). ## Solution Use the real function names. ## Review instructions 1. Compare the list with the `CREATE FUNCTION` statements in the linked `hypopg--1.4.5.sql`. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) Co-authored-by: Nik Richers <nrichers@gmail.com> |
||
|
|
4ead4b092e | chore(www): bump MCP server card to 0.18.0 (#53690) | ||
|
|
9964968b53 |
docs(auth): explain that supabase-js refreshes the session automatically (#53698)
## Problem The User sessions guide explains what refreshing the session means, but not who does it. Readers building browser apps can't tell whether they need to write their own refresh logic for when the access token expires. Related to [FDBKIN-12783](https://linear.app/supabase/issue/FDBKIN-12783/provide-clear-documentation-and-examples-for-jwt-refresh-in-react) Closes [DOCS-1718](https://linear.app/supabase/issue/DOCS-1718/explain-that-supabase-js-refreshes-the-session-automatically-in-the) ## Solution The "What is a session?" section of `/guides/auth/sessions` now says, right after the refreshing-the-session sentence, that `supabase-js` refreshes the session on its own (`autoRefreshToken` defaults to `true`), so a browser app needs no refresh code. It notes that auto refresh pauses while the tab is hidden and checks the session again when the tab is visible. It shows a minimal `onAuthStateChange` listener for the `TOKEN_REFRESHED` event and points to `refreshSession()` for a forced refresh. Timing is described qualitatively, so the text stays true if the client's intervals change. ## Checks The facts come from `@supabase/auth-js` 2.117.3: the default `autoRefreshToken: true` in `GoTrueClient.ts`, the visibility handling in `_onVisibilityChanged`, and the tick and expiry-margin constants in `lib/constants.ts`. The code block on the page, with its hidden setup above `// ---cut---`, passes `tsc --strict` against `@supabase/supabase-js` 2.117.3. Also ran `pnpm turbo run typecheck --filter='...[origin/master]'`, `pnpm turbo run lint --filter='[origin/master]'` and Prettier on the changed file, and all passed. The reference link slugs `auth-onauthstatechange` and `auth-refreshsession` come from `apps/docs/spec/common-client-libs-sections.json`. A second reader reviewed the change against the style guide. ### How to verify 1. On the preview, `/docs/guides/auth/sessions` shows the new paragraphs under "What is a session?", directly after "This process is called refreshing the session." 2. The note says `supabase-js` refreshes the session automatically with `autoRefreshToken` defaulting to `true`, says auto refresh pauses while the tab is hidden, and names `TOKEN_REFRESHED` and `refreshSession()`. 3. The code block shows only the `onAuthStateChange` listener; the client setup is hidden. 4. The `onAuthStateChange` and `refreshSession()` links open their JavaScript reference entries. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
5fb0be08b1 |
docs: say where to reset the database password in the connection guide (#53697)
## Problem Step 4 of "Get your connection string" in the Postgres connection guide tells readers to put their database password in the connection string. It doesn't say that the dashboard stops showing the password after the project is created, or how to get a new one. Related to [FDBKIN-4770](https://linear.app/supabase/issue/FDBKIN-4770/improve-documentation-and-navigation-for-finding-the-database-password) Closes [DOCS-1717](https://linear.app/supabase/issue/DOCS-1717/say-where-to-reset-the-database-password-in-the-connection-guide) ## Solution A new paragraph, indented under step 4 of `/guides/database/connecting-to-postgres`, says that the dashboard doesn't show the database password after you create the project. It points readers to the **Reset database password** option in the Connect dialog and to the Database Settings section (`#database-password`), and warns that a reset breaks existing connections that use the old password. The wording matches the quickstart connection-string partial and the dashboard's own copy. Step 4's own text, including the percent-encoding guidance, is unchanged, and no other section changes. ## Checks I ran `pnpm turbo run typecheck --filter='...[origin/master]'`, `pnpm turbo run lint --filter='[origin/master]'`, and Prettier on the changed file. All of them pass. I checked the facts against the Studio code: the `database-password` section and its copy in `ResetDbPassword.tsx`, and the **Reset database password** button in the Connect sheet's connection step. The `docs` tests were skipped because they need Docker. On the preview, step 4 of "Get your connection string" should: - keep its original text, with a second paragraph that stays inside step 4 - say in that paragraph that the Supabase Dashboard doesn't show the database password after you create the project - name **Reset database password** and say that a reset breaks existing connections - link Database Settings to the dashboard's database settings page, at `#database-password` ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
57e5db42e2 |
docs(auth): explain how to verify JWTs without reaching the JWKS endpoint (#53696)
## Problem The signing keys guide explains how to verify asymmetric JWTs with the JWKS discovery endpoint and its caches. It doesn't help readers whose backend can't make outbound requests to that endpoint. Related to [FDBKIN-21659](https://linear.app/supabase/issue/FDBKIN-21659/improve-guidance-on-verifying-ecc-jwts-in-environments-with-network) Closes [DOCS-1716](https://linear.app/supabase/issue/DOCS-1716/explain-how-to-verify-jwts-when-the-backend-cant-reach-the-jwks) ## Solution A note at the end of "Public key discovery and caching" on `/guides/auth/signing-keys` explains how to copy the public keys into the app and load them at startup. It names the two ways to get the keys: request the discovery endpoint from a machine that can reach it, or copy each key's key set from the dashboard. Because copied keys are a cache that never expires, the note asks readers to copy every asymmetric key that isn't revoked (including a previously used key, which stays trusted after a rotation), to add a standby key before rotating to it, and to remove a revoked key by hand. Existing text in the section is unchanged. "Verifying a JWT from Supabase" on `/guides/auth/jwts` gets one sentence that links to the note, right after its advice not to cache the key set for longer, so readers who start from JWT verification find the option. Existing text on that page is unchanged. ## How to verify 1. On the docs preview, open `/docs/guides/auth/signing-keys`. 2. The note is the last content of "Public key discovery and caching", just before "Choosing the right signing algorithm". 3. The dashboard steps use the Studio labels **More options**, **View key details**, and **Public key set (JSON Web Key Set format)**, and the JWT signing keys link opens the dashboard's JWT settings. 4. The note says to add a standby key to the app before rotating to it and to remove a revoked key by hand. 5. On the docs preview, open `/docs/guides/auth/jwts`. In "Verifying a JWT from Supabase", the paragraph after "Make sure that you do not cache this data for longer" links to "Public key discovery and caching", and the link scrolls to that heading on the signing keys page. ## Checks Ran `pnpm turbo run lint` and `pnpm turbo run typecheck` filtered to the branch's changes, and Prettier on the changed files; all pass. UI labels and the single-key key set were checked against `apps/studio/components/interfaces/JwtSecrets/jwt-secret-keys-table/key-details-dialog.tsx` and `signing-key-row.tsx`. Key trust across rotation was checked against the key lifetime table on the same page. The link's anchor was checked against the heading slug that `getAnchor` in `packages/ui` generates. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
edece97bdc |
docs(auth): explain why the signup trigger must schema-qualify names (#53695)
## Problem The User Management guide shows a trigger that copies new users into `public.profiles`, but it doesn't say why the function sets `search_path = ''` and writes `public.profiles` in full. A reader who drops the schema from a table name breaks every sign-up, and the page doesn't connect that to the `Database error saving new user` response. Related to [FDBKIN-40810](https://linear.app/supabase/issue/FDBKIN-40810/document-best-practices-for-security-definer-triggers-on-authusers) Closes [DOCS-1715](https://linear.app/supabase/issue/DOCS-1715/explain-why-the-signup-trigger-must-schema-qualify-tables) ## Solution A caution admonition right after the trigger example on `/guides/auth/managing-user-data` tells readers to schema-qualify every non-built-in name in the function, such as `public.profiles`. It explains that the function sets `search_path = ''`, so Postgres can't find an unqualified name, the trigger fails, and every sign-up fails with `Database error saving new user`. The note leaves out the Auth role's own search path, because it doesn't apply once the function sets an empty one. For why the search path stays empty, it links to the "Security `definer` vs `invoker`" section of the database functions guide instead of repeating it. The SQL example and the rest of the page are unchanged. ## How to verify 1. On the preview, open `/docs/guides/auth/managing-user-data`. 2. Right after the `handle_new_user` / `on_auth_user_created` SQL example, a caution note says to schema-qualify names such as `public.profiles`, says the function's `search_path = ''` is why an unqualified name fails, and gives the `Database error saving new user` error. 3. The note's link opens the "Security `definer` vs `invoker`" section of `/docs/guides/database/functions`. 4. No other text on the page changed. ## Checks Ran `pnpm turbo run typecheck --filter='...[origin/master]'`, `pnpm turbo run lint --filter='[origin/master]'` (0 errors), and Prettier `--check` on the changed file. The error string was checked against `supabase/auth` `internal/api/signup.go` (`signupNewUser` returns `Database error saving new user` when the user insert fails). The docs tests were skipped because they need Docker. A second reader reviewed the change against the style guide. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
edcfad5bae |
Add Jack Secord to list of contributors (#53750)
## Problem Adding Jack Secord (new hire) to humans.txt ## Solution Provide a brief description of the change and the key choices you made when architecting the solution. Feel free to include screenshots if it includes visual changes. <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | WWW | [/blog/your-post](https://supabase.com/blog/your-post) | [/blog/your-post](https://zone-www-dot-com-git-branch-name-supabase.vercel.app/blog/your-post) | unique phrase from the change | | Docs | [/docs/guides/your-page](https://supabase.com/docs/guides/your-page) | [/docs/guides/your-page](https://docs-git-branch-name-supabase.vercel.app/docs/guides/your-page) | unique phrase from the change | | Studio | [/dashboard](https://supabase.com/dashboard) | [/dashboard](https://studio-git-branch-name-supabase.vercel.app/dashboard) | unique phrase from the change | | Design system | [/design-system](https://supabase.com/design-system) | [/design-system](https://design-system-git-branch-name-supabase.vercel.app/design-system) | unique phrase from the change | | UI library | [/library](https://supabase.com/library) | [/library](https://ui-library-git-branch-name-supabase.vercel.app/library) | unique phrase from the change | | Knowledge base | [/kb/guides/your-page](https://supabase.com/kb/guides/your-page) | [/kb/guides/your-page](https://kb-git-branch-name-supabase.vercel.app/kb/guides/your-page) | unique phrase from the change | --> <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions Provide a clear numbered procedure that the PR reviewer can walk through. 1. For example, `Open the live and preview links side-by-side.` 2. For example, `See the issue is fixed.` ## Checklist Check all before review: - [ ] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
fbd1e34128 |
docs(auth): note that the Kotlin Auth plugin can't be used with Firebase accessToken (#53692)
## Problem The Firebase Auth third-party guide shows Kotlin readers how to set `accessToken` on a supabase-kt client, but it doesn't say that the client then can't install the Auth plugin. A reader who adds `install(Auth)` gets an error when the client is created, and can't tell from the page that Supabase Auth sign-in methods aren't part of this setup. Related to [FDBKIN-7469](https://linear.app/supabase/issue/FDBKIN-7469/improve-documentation-for-using-firebase-jwts-with-supabase-auth) Closes [DOCS-1713](https://linear.app/supabase/issue/DOCS-1713) ## Solution The Kotlin (Android) and Kotlin (Multiplatform) tabs of the client setup section on `/docs/guides/auth/third-party/firebase-auth` now each end with the same short note: leave out the Auth plugin on a client that sets `accessToken`. A paragraph after the tabs covers every SDK: a client that sets `accessToken` can't use Supabase Auth methods, so users sign in and out with Firebase Auth on that client, and a second client without `accessToken` serves Supabase Auth when the app uses both. Each user's requests go through the client that matches how they signed in. The code samples and the TypeScript, Flutter, and Swift tabs are unchanged. ## Checks Ran `pnpm turbo run typecheck --filter='...[origin/master]'`, `pnpm turbo run lint --filter='[origin/master]'`, and Prettier on the changed file. All pass. The Kotlin note was checked against supabase-kt at commit `1ea6e8e`: the Auth plugin's `init` in `Auth/src/commonMain/kotlin/io/supabase/auth/AuthImpl.kt` (line 148) throws when the client has a custom access token provider. The paragraph after the tabs was checked against the `auth` accessor guards in supabase-js (`packages/core/supabase-js/src/SupabaseClient.ts`), supabase-flutter (`packages/supabase/lib/src/supabase_client.dart`), and supabase-swift (`Sources/Supabase/SupabaseClient.swift`, whose doc comment recommends a separate client without `accessToken` for Supabase Auth). The token each client sends was checked in the same files and in supabase-kt's `AccessToken.kt`: a client with `accessToken` sends that token, and a client without it sends its Supabase Auth session. The change adds no code, so there is nothing to run. Docs tests were skipped because they need Docker. ## How to verify 1. Open `/docs/guides/auth/third-party/firebase-auth` on the docs preview. 2. In the client setup tabs, select **Kotlin (Android)**: a note below the code sample says to leave out the Auth plugin (`install(Auth)`) on a client that sets `accessToken`. 3. Select **Kotlin (Multiplatform)**: the same note appears below its code sample. 4. Below the tabs, before "Add a new Third-Party Auth integration to your project", a paragraph says a client that sets `accessToken` can't use Supabase Auth methods, that users sign in and out with Firebase Auth on that client, that a second client without `accessToken` can use Supabase Auth, and that each user's requests go through the client that matches how they signed in. It shows whichever tab is selected. 5. The TypeScript, Flutter, and Swift tabs and all code samples match production. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> Co-authored-by: Alexis Aguilar <98043211+alexisintech@users.noreply.github.com> |
||
|
|
584b9588d9 |
docs: route JavaScript v2 reference contributors correctly (#51219)
## Problem The docs contributor guide presents the JavaScript v2 YAML file as the library-specific authoring example. JavaScript v2 uses the TypeDoc reference pipeline, so that example sends contributors to a file the active generator skips. Fixes #51208. ## Solution Explain the JavaScript v2 TypeDoc workflow and link to its reference-pipeline README. Identify SDK source comments, tracked `config.json` and partials, downloaded TypeDoc JSON, and generated reference output as separate parts of the workflow. Keep the legacy YAML guidance and change its example to the Python SDK, which still uses that pipeline. ## Review instructions 1. Read the Reference structure section in `apps/docs/CONTRIBUTING.md`. 2. Confirm that JavaScript v2 points to `apps/docs/spec/reference/README.md` and its tracked authoring paths. 3. Confirm that the legacy section no longer points contributors to `supabase_js_v2.yml`. ## Self-review - This is a docs-tooling change limited to contributor instructions. - The linked README, JavaScript v2 configuration file, and partials directory exist in the repository. - No generated files were edited. - The change does not add runnable documentation snippets, so the Docker-based docs sandbox is not applicable. ## Validation - `pnpm exec prettier --config prettier.config.mjs --check apps/docs/CONTRIBUTING.md` passed. - `pnpm --filter docs lint:ratchet` passed. - `git diff --check` passed. ## Checklist - [x] Read the repository contribution instructions. - [x] Read the docs authoring and review instructions. - [x] Checked the docs terminology list. - [x] Linked the related issue with `Fixes #51208`. --------- Co-authored-by: Alexis Aguilar <98043211+alexisintech@users.noreply.github.com> |
||
|
|
1773f3a222 |
docs: catch up the CLI reference sidebar (#53749)
Publish the generated sidebar for the CLI reference. The published command spec already matches stable CLI v3.2.0, so this PR leaves the YAML unchanged. The sidebar exposes five additional command pages and lists commands alphabetically within each category, with no nested command groups. The old `role-connections` URL permanently redirects to `role-stats`, and the inspect guide links to the new URL. [CLI-3176](https://linear.app/supabase/issue/CLI-3176) |
||
|
|
e6986b5296 |
feat(studio): OAuth apps consent screen should allow to select another org (#53744)
## Problem The OAuth apps consent screen does not allow users to change the selected org. If the calling app didn't provide the org slug, we select the first available org from the users orgs. ## Solution Add an organization selector: <img width="436" height="570" alt="image" src="https://github.com/user-attachments/assets/a5579f2c-ff54-4d02-9d4a-ac75ed245719" /> ## Review instructions Requirements: - have multiple orgs - have a published app that needs projects selection and at least one authorization already granted - have the oauth example app ready Tests: - authorizing the app again on the same org it was before should preselect the projects - you should be able to select another org and if you do, that should clear the selected projects and you should see only this org projects in the options - reselecting the initially granted org should reselect the projects it had in the existing grant |
||
|
|
1eb8684d60 |
docs: rewrite the project transfers guide (#53540)
## Problem Rewrite apps/docs/content/guides/platform/project-transfer.mdx so readers can answer their own transfer questions. Support sees a steady stream of tickets on project transfers, and most of the questions aren’t answered by the current page. Preview: https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer ## Solution The guide is seven pages. The four task pages follow the [how-to guide template](https://github.com/supabase/supabase/blob/master/apps/docs/style-guide/templates/how-to-guide.md), applied the way #53650 applies it. The other three have no template yet, so they follow the document types in `03-page-structure.md`. <img width="275" height="239" alt="CleanShot 2026-11-20 at 14 32 51" src="https://github.com/user-attachments/assets/bdbf7d39-df13-4418-a5c3-32a4ae1b9e3d" /> | Page | Type | What it holds | | ------------------------------------------------ | --------------- | --------------------------------------------------------------------------------------------------- | | `project-transfer.mdx` | How-to | Transfer a project with the Dashboard or the Management API, then verify it | | `project-transfer/transfer-ownership.mdx` | How-to | Move a project to another person's organization, or hand over the whole organization | | `project-transfer/vercel-marketplace.mdx` | How-to | Move projects out of an organization managed through the Vercel Marketplace | | `project-transfer/pause-project.mdx` | How-to | Pause a project from the Pro Plan or Team Plan by transferring it to a Free Plan organization first | | `project-transfer/requirements.mdx` | Reference | Every check a transfer runs, what blocks it, and partner-managed projects | | `project-transfer/what-changes.mdx` | Explainer | What stays the same, downtime, billing, access and tokens, notifications, what the Free Plan removes | | `project-transfer/troubleshooting.mdx` | Troubleshooting | Each Dashboard and API message with its cause and fix | Corrections to existing claims (downtime, log drains, target organization role, free project limit). New content - Requirements checklist, including SSO accounts, usage restrictions between Free Plan organizations, and overdue invoices - Dashboard steps and a Management API path (/v2/projects/{ref}/transfers and /previews) - What stays the same (data, ref, URL, keys, connection strings) and when apps need an update - Downtime per direction, billing, access tokens, timing, notifications, and audit log - What a move to the Free Plan removes, and how to pause a project from the Pro Plan or above - Handing a project or an organization to another person, lost access to the Owner account - Vercel Marketplace, AWS Marketplace, Stripe Projects, and a pointer for Lovable backends - Troubleshooting tables that quote each Dashboard message with its cause and fix - New updated screenshots The six pages under `project-transfer/` are new, so they have no live version. | Site | Live | Preview | Search for | | ---- | -------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------- | | Docs | [Project Transfers](https://supabase.com/docs/guides/platform/project-transfer) | [Transfer a project](https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer) | `Transfer a project` | | Docs | Not on `master` | [Project transfer requirements](https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer/requirements) | `Account requirements` | | Docs | Not on `master` | [Changes after a project transfer](https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer/what-changes) | `What stays the same` | | Docs | Not on `master` | [Transfer project ownership](https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer/transfer-ownership) | `Hand over the whole organization` | | Docs | Not on `master` | [Transfer a Vercel-managed project](https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer/vercel-marketplace) | `Vercel-managed organization` | | Docs | Not on `master` | [Pause a Pro or Team Plan project](https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer/pause-project) | `Pause the project` | | Docs | Not on `master` | [Troubleshoot a project transfer](https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer/troubleshooting) | `Role and membership messages` | ## Review instructions Provide a clear numbered procedure that the PR reviewer can walk through. **Note:** The changes were made based on all support tickets related to project transfers; all statements were cross-checked in the code and tested on a hosted project. 1. Please check if the structure of the pages meets docs standards. 2. Please confirm "Project transfers" is a valid title; let me know if it should be capitalized. 3. Please confirm if the table with error messages fits into this documentation under troubleshooting ([preview](https://docs-git-docs-project-transfer-rewrite-supabase.vercel.app/docs/guides/platform/project-transfer?queryGroups=method&method=dashboard#troubleshooting)). Done this way so that customers can find the full message in the search. ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
a55904adc0 |
docs: update cpu limits to per worker (#53625)
## Problem Edge Function CPU limits in docs are described as applying per request but this doesn't hold true for how functions have worked. ## Solution Update CPU limits to be described as per worker. <!-- ## Preview links If relevant, include links to changed pages for easy review access. Copy the preview base URL from the Vercel bot comment on this PR. Use the following table as an example template. | Site | Live | Preview | Search for | | -------------- | ------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------ | ----------------------------- | | Docs | [/docs/guides/functions/limits](https://supabase.com/docs/guides/functions/limits) | [/docs/guides/functions/limits](https://correct-edge-functions-limits-supabase.vercel.app/docs/guides/your-page) | Amount of actual time spent on the CPU per worker | --> ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
53f2bb416d |
feat(studio): saved views in sidebar (#53630)
## Problem Unified Logs had saved views behind a dropdown in the toolbar. The dropdown couldn't show more than a name per row, had no room for grouping, and gave new projects nothing to start from — an empty list until you built and saved a filter combination yourself. ## Solution Moved saved views into the filter sidebar as a second level, following the Explorer notebooks/chats pattern: a Saved views button in the sidebar header swaps the filters out for a Views panel, with a breadcrumb back to Logs. Key choices: - **`FilterSideBar` stays generic.** It takes `section`, `headerAction` and `onReset` slots; all saved-views specifics live in `LogsViewsPanel`. - **Presets are virtual, not seeded.** Three built-in views (Errors, Failed requests, Database health) render from a constant with `preset:` ids. No per-project write, so they work for read-only members and can't be deleted into oblivion. They can be duplicated into a real saved view, but not renamed, edited or deleted. - **One dialog for naming.** `ViewNameDialog` backs create, rename and duplicate. - **Clicking a modified view opens the update prompt** instead of re-applying it, which previously discarded unsaved filter edits with no warning. Also fixed two pre-existing alignment issues in the sidebar: filter options sat 4px left of their section heading, and the User filter — a hand-copied clone of the filter row markup — had drifted from the shared one. ## Review instructions 1. Enable the Unified Logs feature preview and the `logsSavedViews` flag, then open **Logs**. 2. Click the layers button in the sidebar header. The filters swap for the Views panel, with **Preset views** above **Saved views**. 3. Click **Errors**. The filter applies and the row highlights; the layers icon turns green. 4. Change a filter. The row reads **Modified** and the update prompt appears. Go back to Logs and return — the prompt is still available. 5. Open the ⋮ menu on a preset: only **Duplicate** is offered. Duplicate it and confirm it lands under Saved views with rename/delete available. 6. Click **+** in the Views header to save the current filters, then rename and delete it. 7. Hit the reset button in the header and confirm the active view clears along with the filters. |
||
|
|
73f1a60341 |
fix(studio): hide spend cap file size banner when Pro already allows 500 GB (#53633)
## What Storage settings showed "Reduced max upload file size limit due to spend cap" to every Pro org with spend cap on, telling them to disable it to get 500 GB uploads. The `storage.max_file_size` entitlement for Pro is already 500 GB regardless of spend cap, so the banner was wrong and confusing. - The banner now only shows when the entitlement returns a known value below 500 GB (it no longer relies on the 50 GB fallback). The check lives in `isFileSizeReducedBySpendCap` with unit tests. - When it does show, the banner states the current reduced limit (e.g. "Max upload file size limit reduced to 5 GB due to spend cap") instead of a generic message. Fixes FE-5063 |
||
|
|
95cf9a78a7 |
docs(cli): show config examples in TOML and JSONC (#53449)
## Problem The CLI reads `supabase/config.jsonc` (and `config.json`) since v3.1.0, but every docs page still shows `config.toml` only. There's also no page explaining the formats, how to switch, the `$schema` / `#:schema` declaration, or editor setup, and no reference pages for the new `supabase config convert` and `supabase config validate` commands. Linear: CLI-2871 ## Solution - **Dual-format examples from one source.** A new directive (`features/directives/ConfigFormats.ts`) picks up any ```` ```toml ```` fence with `name=supabase/config.toml` and renders it as `supabase/config.toml` / `supabase/config.jsonc` tabs. The JSONC is generated at build time with `convertCliConfigTomlToJsonc` from `@supabase/config`, the same converter `supabase config convert` uses, so authors only write TOML and the JSONC matches what the CLI would produce (comments included). Inside `<$CodeTabs>` the JSONC is added as an extra tab. - **The format choice sticks.** `ConfigCodeTabs` keeps the selected format in `localStorage`, so choosing JSONC switches every config example on the page and on later pages. - **Config reference.** The `usage` examples on `/guides/local-development/cli/config` use the same tabs (they were highlighted as Python before), and the intro mentions `config.jsonc`. The `remotes.<branch_name>` example now uses `[remotes.staging]`, since `<branch_name>` isn't a valid TOML key. - **New guide, "Config file formats"** (`/guides/local-development/cli/config-formats`): which file wins, minimum CLI version, `convert` and `validate`, schema declaration and versioning, and editor setup (VS Code trusted domains, Even Better TOML, Tombi, SchemaStore). - **CLI reference.** Adds `supabase-config-convert` and `supabase-config-validate` to the CLI reference nav. `cli_v1_commands.yaml` is the generated v3.2.0 reference, identical to the release bot's update in #53463, so the two PRs don't conflict. - **Content.** About 60 existing config examples across the guides, including the Branching configuration page, are tagged `name=supabase/config.toml`. Branching reads `config.json` and `config.jsonc` as well, and the Branching configuration page now says so. Non-Supabase TOML (`pyproject.toml`, `bunfig.toml`) and the v2-era `[inbucket]` before/after snippet stay TOML-only. - **Format-neutral prose.** Sentences that described the config as `config.toml` now say "your config file", naming `supabase/config.toml` and `supabase/config.jsonc` once per page. TOML section syntax in prose (`max_frequency` under `[auth.email]`) is written as key paths (`auth.email.max_frequency`), which read the same in both formats. Headings that named `config.toml` keep their old anchors. Sentences about what `supabase init` creates still say `config.toml`. - **Markdown export for agents.** `internals/generate-guides-markdown.ts` runs the same transform, so the `.md` pages served to AI agents include the JSONC example after each TOML one. - A test converts every tagged example under `content/`, so a broken TOML example fails tests instead of the build. New dependencies for `apps/docs`: `@supabase/config` (^1.8.0) and `effect` (the same `effect` version Studio pins). `config convert` and `config validate` ship in CLI v3.2.0, which is now stable. ## Review instructions 1. Open `/docs/guides/local-development/seeding-your-database` on the preview. Switch an example to `supabase/config.jsonc` and check the other examples on the page switch too. 2. Open `/docs/guides/local-development/cli/config` and check the usage examples open on JSONC. 3. Read `/docs/guides/local-development/cli/config-formats`. 4. Open `/docs/reference/cli/supabase-config-convert` and `/docs/reference/cli/supabase-config-validate`. ## Self-review Ran the `review-the-docs` local self-review (content, pipeline, and component checks) over the 54 changed pages. - No blockers. Fixed the nits it found: leftover TOML section syntax in prose (diff engines, declarative schemas, Branching, the common settings table on Local and hosted projects), a few long or ungrammatical sentences, and the conversion follow-up steps on Config file formats, now a list. - Links, custom anchors, nav wiring, and frontmatter check out. - The `.md` export on the preview shows each TOML example followed by its JSONC version. - `test-the-docs` deferred: the changed fences are config snippets, and `ConfigFormats.test.ts` already converts every tagged example. No procedural steps changed apart from the `config convert` and `config validate` commands on the new page. ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
aedd3d70db | docs(self-hosting): fix nginx template variable name in HTTPS proxy guide (#53740) | ||
|
|
8f73c10ce1 |
feat(studio): sample browser-translation DOM errors in Sentry (#53600)
## Problem Browser translation (e.g. Chrome Translate) and some extensions rewrite DOM text nodes, which makes React throw `insertBefore` / `removeChild` errors. We drop all of these via `ignoreErrors`, so we have no signal on how often they still happen after the dynamic-text ESLint rule (#52949). Linear: [FE-5008](https://linear.app/supabase/issue/FE-5008/sample-sentry-events-for-browser-translation-crashes-instead-of), from the investigation in [FE-5013](https://linear.app/supabase/issue/FE-5013/investigate-how-we-currently-hide-browser-translation-insertremove). ## Solution Stop ignoring these errors in Studio and send a 5% sample, tagged so they are easy to find in Sentry. - Move the insert/remove node messages from `BROWSER_NOISE_IGNORE_ERRORS` into a new `BROWSER_TRANSLATION_DOM_ERRORS` list in `packages/common/sentry.ts`. `docs` and `www` add it to `ignoreErrors`, so their behavior is unchanged. - In Studio's `beforeSend`, tag matching events with `browser_translation`, `page_translated` and `sample_rate`. The existing `shouldDropForSampleRate` applies the rate. - `page_translated` is best effort: it checks for the `translated-ltr` / `translated-rtl` class on `<html>` and Google Translate `<font>` wrappers. Firefox and Edge are less reliable, so `false` is not proof. - `filterSentryEvent` skips its 1% non-crash sampling for tagged events. Without this the rates would multiply and 5% would really be 0.05%. - The generic `parentNode` / `removeChild` null reads stay ignored. They have many unrelated causes, so tagging them as translation would mislead. Not in this PR: - The `text content does not match` and hydration ignores. They are related symptoms and should be a follow-up. - The user-facing fallback in `InsertBeforeRemoveChildErrorHandler`. ## Review instructions 1. Check that `docs` and `www` still ignore the five DOM messages, via `BROWSER_TRANSLATION_DOM_ERRORS` in their `instrumentation-client.ts`. 2. Run `pnpm exec vitest run lib/sentry-client-options.test.ts` from `apps/studio`, and `pnpm exec vitest run sentry.test.ts` from `packages/common`. 3. After merge, filter Sentry for `browser_translation:true` on the production Studio project and compare `page_translated` true against false. ## Before merging Sentry also has server-side inbound filters on the production Studio project. Someone with project access should confirm the `error-message` filter doesn't match these messages. If it does, the sampled events will be dropped on arrival. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill (not applicable) |
||
|
|
3334709840 | fix(self-hosted): stop cutting off Envoy responses after 30s (#51620) | ||
|
|
4448134b3b |
fix(studio): OAuth apps consent screen permission diff may show an empty Already granted section (#53729)
## Problem The OAuth apps consent screen may show an empty _Already granted_ section in the permissions diff <img width="802" height="474" alt="image" src="https://github.com/user-attachments/assets/f49bca9e-20da-4554-83dd-98b93b752a0a" /> ## Solution Hide it when empty ## Review instructions - Publish an oauth app with only the _Database Read_ permission - Use the oauth example to authorize it - Update the published app to add the _Database Write_ permission - Use the oauth example to authorize it again You shouldn't see an _Already granted_ button |
||
|
|
037ee2afad |
fix(studio): name the actual config file on the code configuration page (#53518)
## Problem
The Code configuration page (`ConfigDrift`) hard-codes `config.toml` in
its copy. The GitHub connection config endpoint (`GET
/platform/integrations/github/connections/{id}/config`) now also reads
`supabase/config.json` and `supabase/config.jsonc` and returns the file
it read in `path`, so a project with a JSON config sees wording about a
file it doesn't have.
Linear: CLI-2954
## Solution
- `useSelectedGitHubConfigDrift` returns `configFileName`, the basename
of the response's `path`.
- The drift page uses it in the column header, drift banner, decode
error title, overwrite warning and the Matching / Not tracked sections.
Where no file is known (the no-connection empty state) it says "config
file".
- `formatGitHubConfigDecodeMessage` takes the file name, falling back to
"The config file".
- The `config-toml` error source is renamed to `config-file`.
- Small copy fix in the warning: "redeploys … and overwrites changes
made here".
TOML projects see the same text as before, since `path` resolves to
`config.toml`.
## Review instructions
1. Open the Code configuration page for a project connected to a repo
with `supabase/config.toml` and confirm the copy is unchanged.
2. Repeat for a repo with only `supabase/config.jsonc` and confirm the
page names `config.jsonc` throughout.
3. `pnpm --filter studio exec vitest run
components/interfaces/ConfigDrift` covers both cases, including a JSONC
decode error.
## Checklist
- [x] I have read
[CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md)
- [x] If I wrote a new docs topic or edited an existing topic, I used
the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs
[style
guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide)
|
||
|
|
c484941fac |
docs: add Unity quickstart (#51898)
## Problem #51257 added Unity to the Connect panel, but the docs have no Unity quickstart to go with it. ## Solution New page at `quickstarts/unity.mdx`, built from `_template.mdx`. It uses the same setup as the Connect panel: NuGetForUnity for the install and a `SupabaseManager` script for the client. I also added the nav entry, the `ai-prompts.data.ts` entry, and two notes in `_template.mdx` on where Unity differs (the key goes in the script, IL2CPP code stripping). Tested on Unity 6.3 with the `Supabase` NuGet package 8.11.0, in the editor and in an IL2CPP Windows build. Not changed: the Connect link in the shared `api_settings` partial doesn't pass `using=unity`, so it opens the default .NET variant. ## Review instructions 1. Open the docs preview at `/docs/guides/getting-started/quickstarts/unity`. 2. Optional: follow the guide in a new Unity 6.3 project. The Console should print `violin`, `viola` and `cello`. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
ea5cd851ed |
fix(studio): OAuth apps consent screen should always select the org provided in URL (#53727)
## Problem The organization provided by its slug in the URL isn't selected unless a project ref was also provided. ## Solution Always select the org provided in URL ## Review instructions - Publish an oauth app - Use the oauth example and provide an org slug in the form - Check the consent screen selected this org Do check this with multiple different orgs to ensure you weren't lucky with the org array sorting |
||
|
|
6bdb443398 |
docs(guides): fix code fence languages in three guides (#53722)
## Problem
Three code blocks in the docs guides use the wrong language tag, so they
are highlighted and type-checked as JavaScript or TypeScript instead of
what they are:
- `guides/database/arrays.mdx`: a SQL query is tagged `js`
- `guides/database/import-data.mdx`: the `pgloader config.load` command
is tagged `jsx`
- `guides/ai/hybrid-search.mdx`: a cURL command is tagged `tsx`
The docs style guide says JavaScript and TypeScript blocks get type
hints and are formatted by Prettier, which does not apply to these
blocks.
## Solution
Retag the blocks: `sql` for the query and `bash` for the two shell
commands (`bash` is the most common shell tag in the guides).
For the SQL block I also lowercased the keywords, per the style guide's
"Prefer lowercase for SQL". Prettier's SQL plugin rewrites
`textarray[1]` to `textarray as [1]`, which is not valid Postgres, so
the block is preceded by `{/* prettier-ignore */}`, the same convention
already used in `guides/ai/engineering-for-scale.mdx` and
`guides/api/query-plans.mdx`.
Earlier PRs fixed the same kind of problem: #11870, #19033, #14856,
#11235.
## Review instructions
1. Open the diff: only the language tags change, plus the lowercase SQL
and the `prettier-ignore` comment in `arrays.mdx`.
2. Check the three pages in the preview: the SQL block in the SQL tab of
"Working with arrays", the `pgloader` step in "Import data into
Supabase", and the cURL block in "Hybrid search".
3. Run `pnpm test:prettier`. It passes for these files with the repo's
`prettier.config.mjs`.
## Checklist
- [x] I have read
[CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md)
- [ ] If I wrote a new docs topic or edited an existing topic, I used
the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs
[style
guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide).
(Not run: this edit only changes code fence languages, and I applied the
style guide's code block rules by hand.)
Co-authored-by: Santhosh-x23 <185920429+Santhosh-x23@users.noreply.github.com>
|
||
|
|
c3c049ea53 |
chore: remove public TIA PDF and point to Trust Center (#53687)
<!-- claude-slack-attribution --> _Requested by **Ivan Vasilov** · [Slack thread](https://supabase.slack.com/archives/C0161K73J1J/p1795121287621619)_ ## Problem **Before:** The Studio org Documents page linked directly to `https://supabase.com/downloads/docs/Supabase+TIA+250314.pdf`, and that PDF was served publicly from `apps/www/public/downloads/docs/`. Legal/Security wants people to get the latest TIA from the Trust Center instead, and the old PDF taken off the public site. **After:** The Studio TIA section links to https://trust.supabase.io, and the PDF is deleted from `apps/www`. The old PDF URL permanently redirects to the Trust Center, so existing links don't 404. This removes the public TIA PDF and repoints the dashboard to the Trust Center. ## Solution - Deleted only `apps/www/public/downloads/docs/Supabase+TIA+250314.pdf` (the other docs in that folder are untouched). - `TIA.tsx` in Studio: the button now links to `https://trust.supabase.io` (the same form already used in the legal FAQ), reads "View TIA in Trust Center", uses the external-link icon, and drops the `download` attribute. Description copy mentions the Trust Center. The existing `document_view_button_clicked` telemetry is unchanged. - `apps/www/lib/redirects.js`: added a permanent redirect for `/downloads/docs/Supabase\\+TIA\\+250314.pdf` to `https://trust.supabase.io`, following the existing DPA PDF redirect. This is easy to drop if you'd rather have a hard 404. No other references to the PDF exist in the repo (checked www, studio, docs, packages). The legal FAQ already links to the Trust Center. ## Important caveats - Deleting the file does **not** remove the blob from git history. `supabase/supabase` is public, so the PDF stays fetchable through the repo's history. If it must be truly gone, that needs a separate decision (history rewrite and/or contacting GitHub support). - A CDN/Vercel cache may serve the PDF briefly after deploy (and the redirect takes effect once deployed). ## Review instructions 1. In the Studio preview, open an org's Documents page and check the TIA section: the button opens https://trust.supabase.io in a new tab. 2. On the www preview, request `/downloads/docs/Supabase+TIA+250314.pdf` and confirm it redirects to the Trust Center. ## Testing Typecheck, lint and tests were not run: `pnpm install` is partially blocked in my environment (npm.jsr.io is egress-blocked) and prettier couldn't load its plugins. I only confirmed `redirects.js` loads in Node and the entry parses. I couldn't reach supabase.com, so the live URLs are unverified. --- _Generated by [Claude Code](https://claude.ai/code)_ Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
f9fd4a2a9f |
feat(www,docs,kb): show Do Not Sell or Share footer link to US visitors (#53490)
## Problem US visitors need a "Do Not Sell or Share My Personal Information" footer link, and no site reads the visitor's country ([GROWTH-1369](https://linear.app/supabase/issue/GROWTH-1369)). ## Solution - The www proxy copies the `x-vercel-ip-country` header into a `_sb_country` cookie, which the footers read client-side. Docs and kb route through www, so that covers all three. - US visitors and unknown countries see the opt-out label. Everyone else keeps "Privacy Settings". Both open the same modal. - The link sits on each footer's copyright line, and the label stays hidden until the cookie is read. - Out of scope: GPC ([GROWTH-1373](https://linear.app/supabase/issue/GROWTH-1373)) and modal copy ([GROWTH-1370](https://linear.app/supabase/issue/GROWTH-1370)). - Tests cover US, non-US, unknown countries, and the cookie write. Screenshots used a hand-set cookie. **www** | | Before | US | DE | |---|---|---|---| | 375px | <img src="https://github.com/user-attachments/assets/1bd8bcb8-6692-4fe9-90a0-5343b0364053" width="200"> | <img src="https://github.com/user-attachments/assets/0514a0bd-ad1c-4773-b889-de941f5466b5" width="200"> | <img src="https://github.com/user-attachments/assets/328ca1b4-9698-492e-8045-a15d884108f2" width="200"> | | 1440px | <img src="https://github.com/user-attachments/assets/3cb3e7d7-62ab-4d34-841c-23d50d7d1cd5" width="300"> | <img src="https://github.com/user-attachments/assets/caf75b29-7286-404a-b1ea-7dfa5022912c" width="300"> | <img src="https://github.com/user-attachments/assets/2c067209-39cd-4ad8-9987-4f8763d70660" width="300"> | **docs** | | Before | US | DE | |---|---|---|---| | 375px | <img src="https://github.com/user-attachments/assets/37248b4a-436b-4d2d-b2d3-3966117abf9e" width="200"> | <img src="https://github.com/user-attachments/assets/0b109a0d-7618-46f8-ade0-8ba17e390b56" width="200"> | <img src="https://github.com/user-attachments/assets/0047b2b8-7047-40df-8d9c-09f51e538fa4" width="200"> | | 1440px | <img src="https://github.com/user-attachments/assets/0a7d6a65-e964-43dc-911e-0ea033cb1e91" width="300"> | <img src="https://github.com/user-attachments/assets/27922348-661c-4246-b3fc-44ac054bd084" width="300"> | <img src="https://github.com/user-attachments/assets/30afb171-1023-43ff-b77e-89f341128377" width="300"> | **kb** | | Before | US | DE | |---|---|---|---| | 375px | <img src="https://github.com/user-attachments/assets/cd4fb8d1-8827-4b1a-8d13-c2a5d4f97378" width="200"> | <img src="https://github.com/user-attachments/assets/2706ae24-3df8-4149-9a51-75abb0456734" width="200"> | <img src="https://github.com/user-attachments/assets/7afb8731-b487-4e48-ae83-a3a6bde36bee" width="200"> | | 1440px | <img src="https://github.com/user-attachments/assets/3b2bdc17-fee7-4ec0-bd24-d35a0367a6ca" width="300"> | <img src="https://github.com/user-attachments/assets/479b03e6-6890-4714-bbbb-ab122f46e786" width="300"> | <img src="https://github.com/user-attachments/assets/252f4e0f-5bcc-4b43-aeda-784df9f000ca" width="300"> | ## Review instructions 1. From a US IP, click the footer link on the www preview. The modal opens. 2. From a non-US IP, see "Privacy Settings". ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [ ] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: Danny White <3104761+dnywh@users.noreply.github.com> |
||
|
|
6fda122771 |
chore(studio): show the TanStack devtools only with ?tanstack-devtools (#53708)
## What kind of change does this PR introduce? Chore (local developer experience) ## What is the current behavior? In local development, Studio renders the TanStack devtools floating trigger in the bottom-right corner on every page. It overlaps Studio's own dev toolbar trigger and gets in the way. ## What is the new behavior? The TanStack devtools (Router and Query panels) only show when Studio is loaded with `?tanstack-devtools` in the URL, using the library's built-in `requireUrlFlag` setting. Once loaded, they stay available while navigating within Studio, and a reload without the flag hides them again. Use a URL that doesn't redirect, for example `/org/<slug>?tanstack-devtools` or `/project/<ref>?tanstack-devtools`. The library reads the flag when the devtools mount, so a redirect that drops the query string can hide them. **If you've opened the devtools before**, the library has saved its settings to localStorage, and those override the `config` prop. Turn on **Require URL Flag** in the devtools Settings tab once, or delete the `tanstack_devtools_settings` localStorage key. ## How to verify - With no `tanstack_devtools_settings` in localStorage, run `pnpm dev:studio` and open `/org/<slug>`: no TanStack trigger appears. - Open `/org/<slug>?tanstack-devtools`: the trigger appears and opens the panel. Click through to another page: it's still there. - Reload without the flag: the trigger is gone. - Production and test builds are unchanged. --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
4ce89b7090 |
Remove unnecessary guard in CLI login (#53707)
## Context Resolves FE-5165 The CLI login screen could get stuck on the loading state and never navigate to the device code view. Was happening due to two guards that interact badly: - `startedForSessionIdRef` stops the effect from sending a second POST for the same `session_id`. - An `isActive` flag, set to `false` in the effect cleanup, made the POST handler ignore its result once the effect had been cleaned up. It's seemingly a race condition issue as in my case I only ran into this problem locally, but not on staging as `isActive` was getting flipped to `false` and hence the UI never navigates to show the device code Opting to remove the `isActive` guard and solely rely on `startedForSessionIdRef.current` since the latter should be able to handle this logic by itself ## To test This one can only be tested locally i reckon - [ ] Verify that you can login via CLI via `supabase login --profile supabase-local` |
||
|
|
21fa55ba0e |
Navigate away after deleting the open table when its tab was already pruned (#53710)
## Context Table Editor E2E tests for context menu is failing on `deleting the open table from its context menu closes its tab` Likely a race condition happening as the test does passes sometimes, but fails way too often. Fix is applied on `useCloseDeletedTableTab` to navigate away after deleting the open table when tab was already pruned |
||
|
|
c18904c171 |
kb: add how to use Drizzle with Supabase as just Postgres article (#53295)
## Problem There aren't much guides on how to use Supabase as just Postgres and use it with Drizzle. ## Solution Adds a simple tutorial article in the KB for how to create an app with Drizzle & TanStack, and use Supabase as just Postgres. ## Preview links https://kb-git-tylershukert-devrel-615-drizzle-supabase-1159ba-supabase.vercel.app/kb/guides/setup-drizzle-with-postgres-and-tanstack-start <!-- ## Additional context Optionally add any other context or screenshots. --> ## Review instructions Provide a clear numbered procedure that the PR reviewer can walk through. Make sure the tone and the content in general follow what we would want within KB. ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: kodster28 <kody.jackson@supabase.io> |
||
|
|
b1d59e0ee8 |
feat(www): pricing (#53320)
## Problem - pricing page shows checks in the bright brand green - pro button sits lower than the other plan buttons, and each price sits lower than its plan name - compute slider has no step marks, so a reader cannot see the sizes before a drag ## Solution - changes the plan cards so names, prices and buttons line up, and the pro card has the only green button - replaces the bright green check circles with tinted checks and drawn minus icons, so both icons pass contrast - adds step marks and a hover preview to the compute slider, so the badge and price show a size before the click - adds a tab above the micro row in the compute table, so readers see which size the plan credits cover - fixes the spend cap chart, which showed the bars of both states on toggle because css transitions changed the motion values | before | after | | --------------------------------------------------------------------------- | -------------------------------------------------------------------------- | | <img width="2880" height="23304" alt="pricing-before" src="https://github.com/user-attachments/assets/c42c7487-e0fb-4914-a210-844fe67015bd" /> | <img width="2880" height="22958" alt="pricing" src="https://github.com/user-attachments/assets/e2066006-f610-4c53-a5a7-94525966fefc" /> | ## Preview links | Site | Live | Preview | | ---- | ------------------------------------------------------------------------------------ | --- | | WWW | [/pricing](https://supabase.com/pricing) | [/pricing](https://zone-www-dot-com-git-antlio-feat-www-pricing-supabase.vercel.app/pricing) | ## Review instructions 1. visit [/pricing](https://zone-www-dot-com-git-antlio-feat-www-pricing-supabase.vercel.app/pricing) |
||
|
|
0ce2a96c53 |
feat(studio): show Warehouse workload on the integration overview (#53575)
## Problem The Warehouse integration overview shows replication status but gives no view of query activity. ## Solution Add last-hour query rate and p95 duration charts, with refresh and a link to Observability. Metrics failures appear beside the replication information. | Before | After | | --- | --- | | <img width="1292" height="1288" alt="CleanShot 2026-11-18 at 13 44 48@2x" src="https://github.com/user-attachments/assets/f06314bb-8322-448b-a86b-6821a3427a52" /> | <img width="1314" height="1930" alt="CleanShot 2026-11-18 at 13 45 10@2x" src="https://github.com/user-attachments/assets/0cbaab85-b7bb-445d-8547-3c772010a0d1" /> | | _No “Workload” section._ | _A new “Workload” section._ | Depends on #53574. ## Review instructions 1. Open the [Studio staging preview](https://studio-staging-git-dnywh-warehouse-overview-workload-supabase.vercel.app) with a staging project that has Warehouse configured. 2. Go to **Integrations > Warehouse > Overview**. Check the **Workload** charts below replication status. 3. Refresh the charts, then use **Observability** to open the full report. 4. Check a period without query activity. The empty message should name the last 60 minutes. --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
98b197509e |
feat(studio): show Warehouse worker activity (#53574)
## Problem The Warehouse report does not show worker starts or request performance. ## Solution Add worker starts, worker start time, requests by method and request duration below Capacity. Keep the API’s kind, result, method and status labels visible. Durations use milliseconds. | After | | --- | | <img width="1670" height="3362" alt="CleanShot 2026-11-18 at 13 41 47@2x" src="https://github.com/user-attachments/assets/90f6c5ec-dc4c-4828-ba40-7242fa4c1b71" /> | | _The new “Worker activity” section._ | ## Review instructions 1. Open the [Studio staging preview](https://studio-staging-git-dnywh-warehouse-report-workers-supabase.vercel.app) with a staging project that has Warehouse access, then go to **Observability > Warehouse**. 2. Check **Worker activity** below Capacity. Compare worker starts and start time, then requests by method and request duration. 3. Change the period and refresh. Check that the labels distinguish the returned worker kinds and request outcomes, and that missing measurements stay distinct from zero. --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
8409c5d98f |
feat(studio): show Warehouse capacity (#53573)
## Problem The Warehouse report does not show available worker capacity or why requests are rejected. ## Solution Add worker-slot usage alongside the slot limit, plus rejected requests split by reason. Labelled measurements keep separate lines and missing values stay visible as gaps. | After | | --- | | <img width="1694" height="1842" alt="CleanShot 2026-11-18 at 13 38 04@2x" src="https://github.com/user-attachments/assets/e480b83c-6c93-4b18-85e6-9a37caf304b0" /> | | _The new “Capacity” section._ | ## Review instructions 1. Open the [Studio staging preview](https://studio-staging-git-dnywh-warehouse-report-capacity-supabase.vercel.app) with a project that has Warehouse access, then go to **Observability > Warehouse**. 2. Under **Capacity**, compare **In use**, **Active grants** and **Pending grants** with **Limit**. 3. Check **Rejected requests** for labelled rejection reasons. Change the period and refresh to check both charts update. --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
2372aa0fc2 |
feat(studio): show Warehouse query latency (#53570)
## Problem The Warehouse report shows query activity and outcomes, but not how long queries spend waiting or running. ## Solution Add query-duration percentiles, worker-acquisition waits and successful-query duration. Durations are shown in milliseconds, with missing measurements kept distinct from zero. Latency loads separately so a failed request does not hide query activity. | After | | --- | | <img width="1678" height="1796" alt="CleanShot 2026-11-18 at 12 28 53@2x" src="https://github.com/user-attachments/assets/48c6545e-8f2d-40c4-aa3c-977dd2ae6479" /> | | _New latency section._ | ## Review instructions 1. Open the [Studio staging preview](https://studio-staging-git-dnywh-warehouse-report-latency-supabase.vercel.app) with a staging project that has Warehouse access ([example](https://studio-staging-git-dnywh-warehouse-report-latency-supabase.vercel.app/dashboard/project/yirnfrgkxmnqgexikhfc/observability/warehouse?its=2026-11-18T00%3A23%3A52.901Z&ite=2026-11-18T01%3A23%3A52.901Z&isHelper=true&helperText=Last+60+minutes)), then go to **Observability > Warehouse**. 2. Check **Query duration**, **Time waiting for a worker** and **Successful query duration** below the query charts. Hover the lines to compare timing measurements. 3. Change the date range and refresh. Both query activity and latency should update. 4. Check the selected period without measurements. Empty or unavailable data must remain distinct from measured zeroes. Shared ChartLine accessibility changes are separate in #53706. --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
df6eafef7c |
Joshenlim/fe 5116 support editduplicatedelete tables from (#53662)
## Context We previously introduced context menus to the table editor [here](https://github.com/supabase/supabase/pull/53506), but prevented edit, delete, and duplicate actions as those actions were coupled to the router. Hence this PR decouples that by making those actions target a table by a provided ID "More options" action now also shows on every row, just visibly shown only if its active or the user hovers over the row <img width="335" height="183" alt="image" src="https://github.com/user-attachments/assets/9897945d-37f4-4658-9420-29b948173208" /> ## To test Can test edit / delete / duplicate table on a table that you're not currently actively on, via both context menu and dropdown menu |
||
|
|
1479013fd8 |
docs(guides): rework five how-to pages to the how-to template (#53650)
Closes DOCS-1614 ## Problem This PR is to apply the template to top-five low-hanging fruit pages -- ones that nearly match the template already and do not need to break out new topics. This PR also tests the template to see that it is working as expected. ## Solution Apply the How-to Template to 5 how-to pages. ## Preview links | Site | Live | Preview | Search for | | --- | --- | --- | --- | | Docs | [/docs/guides/storage/analytics/creating-analytics-buckets](https://supabase.com/docs/guides/storage/analytics/creating-analytics-buckets) | [/docs/guides/storage/analytics/creating-analytics-buckets](https://docs-git-docs-howto-rework-easy-pages-supabase.vercel.app/docs/guides/storage/analytics/creating-analytics-buckets) | Create an analytics bucket | | Docs | [/docs/guides/functions/debugging-tools](https://supabase.com/docs/guides/functions/debugging-tools) | [/docs/guides/functions/debugging-tools](https://docs-git-docs-howto-rework-easy-pages-supabase.vercel.app/docs/guides/functions/debugging-tools) | Debug Edge Functions locally | | Docs | [/docs/guides/queues/consuming-messages-with-edge-functions](https://supabase.com/docs/guides/queues/consuming-messages-with-edge-functions) | [/docs/guides/queues/consuming-messages-with-edge-functions](https://docs-git-docs-howto-rework-easy-pages-supabase.vercel.app/docs/guides/queues/consuming-messages-with-edge-functions) | Consume queue messages | | Docs | [/docs/guides/database/postgres/setup-replication-external](https://supabase.com/docs/guides/database/postgres/setup-replication-external) | [/docs/guides/database/postgres/setup-replication-external](https://docs-git-docs-howto-rework-easy-pages-supabase.vercel.app/docs/guides/database/postgres/setup-replication-external) | Replicate to an external Postgres | | Docs | [/docs/guides/security/rotate-leaked-api-keys](https://supabase.com/docs/guides/security/rotate-leaked-api-keys) | [/docs/guides/security/rotate-leaked-api-keys](https://docs-git-docs-howto-rework-easy-pages-supabase.vercel.app/docs/guides/security/rotate-leaked-api-keys) | Rotate a leaked API key | ## Review instructions 1. Open the live and preview links for each page side by side. 2. Check that each page opens with a value statement and ends with Next steps. 3. Check that the code blocks and the Dashboard steps match the live page. 4. On the debugging page, check that the steps run in order across the two phases. 5. On the replication page, check that the code blocks and notes render under the right steps and the numbering runs 1 to 5. 6. On the rotate page, check that the "Retire the compromised key" link in Prerequisites still jumps to its heading. ## Checklist Check all before review: - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) |
||
|
|
656aa60b20 |
docs(database): explain which role a security_invoker view checks (#53641)
## Problem The "View security" section of the views guide explains `security_invoker` but not which role is checked when the view is queried through the Data API, or why a `security_invoker` view over `auth` tables fails with every API key. Related to [FDBKIN-21897](https://linear.app/supabase/issue/FDBKIN-21897) Closes [DOCS-1687](https://linear.app/supabase/issue/DOCS-1687) ## Solution Adds two paragraphs of body text after the SQL example in "View security" (`apps/docs/content/guides/database/views.mdx`). The existing paragraph and SQL are unchanged. - The first paragraph says that through the Data API, Postgres checks the role from the request's API key or JWT (`anon`, `authenticated`, or `service_role`). That role needs privileges, such as `select`, on every table the view reads, not only on the view. Postgres logs show `authenticator`, the role the Data API connects as, not the role the view checks. - The second paragraph says that by default, API roles have no privileges on tables in the `auth` schema, so a `security_invoker` view over `auth.users` fails with `permission denied for table users`, even with a secret key. It points readers to storing user data in a `public` table, with a link to the User management guide. It does not recommend granting `auth` tables to any role. Needs review: the text says "by default" for `auth` grants because older projects may carry extra grants. Checks run: `prettier --check` on the changed file and `pnpm turbo run lint --filter='[origin/master]'` pass on the latest commit. `pnpm turbo run typecheck --filter='...[origin/master]'` passed on the first commit; the second commit changes only MDX prose. Docs tests were skipped because they need a local Supabase stack (Docker). ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
58e0d8067d |
docs(rls): add an example for rows shared by two users (#53640)
## Problem The RLS guide shows policies for rows that belong to one user (`user_id`), but not for a row that two users share through two columns, such as the buyer and the seller of an order. Related to [FDBKIN-27655](https://linear.app/supabase/issue/FDBKIN-27655) Closes [DOCS-1686](https://linear.app/supabase/issue/DOCS-1686) ## Solution Adds a `### Share rows between users` section to the RLS guide, between "Write a policy for each operation" and "Specify roles in your policies". The section spans operations, so it sits beside the per-operation subsections, not among them. It has: - An `orders` table with `buyer_id` and `seller_id`. RLS is enabled, grants are revoked from `anon, authenticated`, and `select, update` are granted to `authenticated`, following the page's grant pattern. - A select policy and an update policy that both use `(select auth.uid()) in (buyer_id, seller_id)`. The update policy uses the same expression in `using` and `with check`, so the updated row must still include the user as buyer or seller. - A sentence on `insert` and `delete`: check only the user who can create or remove the row, because a delete policy that checks both columns lets one user remove the row for both. - A note that this needs no `security definer` function, with a link to "Use security definer functions" for checks against another table. - A note to index `buyer_id` and `seller_id` separately, with a link to "Add indexes". No existing section is changed. ### Verification - I ran the SQL in PGlite (Postgres 17) with an `authenticated` role, an `auth.uid()` that reads `request.jwt.claim.sub`, and an index on each of `buyer_id` and `seller_id`: - Buyer: selects 1 row and updates 1 row. Setting both IDs to a third user fails with `new row violates row-level security policy for table "orders"`. - Seller: same as the buyer. - Another user: selects 0 rows and updates 0 rows. - `explain select * from orders` with `enable_seqscan=off` shows a `BitmapOr` over both indexes, with `auth.uid()` in InitPlans. - `pnpm turbo run lint --filter='[origin/master]'` passes, with no findings on the changed file. - Prettier `--check` passes on the changed file. - The page compiles with `@mdx-js/mdx`. - `build:guides-markdown` could not run in the sandbox: it needs GitHub credentials for federated content. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
00c96d23f0 |
docs(auth): update Keycloak client settings to the current admin console (#53638)
## Problem The Keycloak social sign-in guide still describes the legacy Keycloak admin console: it tells readers to set "Access Type" to "confidential", a field that no longer exists. The current console configures this under **Capability config** with **Client authentication** and **Standard flow**. Related to [FDBKIN-4596](https://linear.app/supabase/issue/FDBKIN-4596) Closes [DOCS-1684](https://linear.app/supabase/issue/DOCS-1684) ## Solution In `apps/docs/content/guides/auth/social-sign-in/auth-keycloak.mdx`: - **Overview list:** the client uses **Client type** **OpenID Connect**, with **Client authentication** and **Standard flow** on under **Capability config**. The secret bullet now says **Client Secret** on the **Credentials** tab. - **One client procedure:** merged "Create a Keycloak client" and "Client settings" into one numbered procedure that follows the Create client screens: 1. **Clients** > **Create client** 2. Set **Client type** to **OpenID Connect** 3. Set **Client ID**, then **Next** 4. In **Capability config**, turn on **Client authentication** and leave **Standard flow** on, then **Next** 5. In **Login settings**, add the callback URL to **Valid redirect URIs** 6. **Save** Each step is an instruction. The labels match the Keycloak tab of the self-hosted OAuth guide. The "Client settings" heading is gone, and nothing in the repo links to its anchor. - **Client secret:** "Obtain the client secret" says to copy the **Client Secret** from the client's **Credentials** tab. - **Screenshots:** removed every screenshot of the legacy console from the page and deleted the files under `apps/docs/public/img/guides/auth-keycloak/`, which nothing else references: - `keycloak-create-realm.png` - `keycloak-add-client.png` - `keycloak-client-id.png` - `keycloak-redirect-uri.png` - `keycloak-client-secret.png` - `keycloak-openid-endpoint-config.png` No new screenshots are added. Supabase Auth's Keycloak provider uses a confidential Authorization Code flow (client secret plus code exchange). That flow needs Client authentication and Standard flow, so the guide does not ask readers to enable Direct access grants. Unchanged: the `docker run` command and the text of the realm section. Checks: `pnpm turbo run typecheck --filter='...[origin/master]'`, `pnpm turbo run lint --filter='[origin/master]'`, and Prettier on the changed MDX file all pass. The docs tests were skipped because they need Docker. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
39295dd584 |
docs(api): explain that default privilege changes leave existing tables exposed (#53639)
## Problem The Securing your API guide explains how to stop new objects in `public` from getting Data API grants. It doesn't say that this only changes the defaults for objects created later. Existing tables keep their grants and stay reachable through the Data API. Related to [FDBKIN-41883](https://linear.app/supabase/issue/FDBKIN-41883) Closes [DOCS-1685](https://linear.app/supabase/issue/DOCS-1685) ## Solution Adds text to `apps/docs/content/guides/api/securing-your-api.mdx` and rewrites no existing text: - **Default privileges:** a new paragraph says that changes to default privileges, including the platform default change, apply only to new objects, so existing tables keep their grants and stay reachable through the Data API. A per-table revoke follows it: `revoke all on table public.your_table from anon, authenticated, service_role;`. A sentence after it says that leaving out `service_role` keeps server-side access with a secret key. - **Revoke default privileges:** a new sentence says that existing tables, sequences, and functions keep their current grants. It links to the per-table revoke in `#default-privileges`. Sources for the behavior: - The Dashboard toggle's SQL (`buildDefaultPrivilegesSql` in `packages/pg-meta/src/sql/studio/database/privileges.ts`) runs only `alter default privileges … grant/revoke` statements. It runs no revoke on existing tables. - The Postgres docs for `ALTER DEFAULT PRIVILEGES` say it affects only objects created later. - `getting-started/api-keys.mdx` says that a secret key uses `service_role`, which bypasses RLS but still needs table grants. - Checked on PGlite (PostgreSQL 18.6). After `alter default privileges … revoke all on tables`, a table created earlier kept its `anon`, `authenticated`, and `service_role` grants, and a table created later had none. After the per-table revoke, `has_table_privilege('anon', 'public.old_t', 'select')` returned false. With `service_role` left out of the revoke, `service_role` still read an RLS-enabled table. With `service_role` included, it got `permission denied`. Checks run: `pnpm turbo run lint --filter='[origin/master]'` (0 errors), `pnpm turbo run typecheck --filter='...[origin/master]'`, Prettier `--check` on the changed file, and `pnpm -C apps/docs run check:removed-anchors`. `pnpm build:guides-markdown` didn't run locally: its federated-content step needs GitHub credentials. The docs tests weren't run because they need Docker. ## Checklist - [x] I have read [CONTRIBUTING.md](https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md) - [x] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](https://github.com/supabase/supabase/tree/master/apps/docs/style-guide) --------- Co-authored-by: supabase-vercel-tedd[bot] <336548405+supabase-vercel-tedd[bot]@users.noreply.github.com> |
||
|
|
3b12d2e167 |
feat(ui): switch component (#53379)
## Problem * the shared switch in `packages/ui` uses the radix primitive * the thumb does not react to hover or press, and only the track color shows the state * a click on a switch label toggles the switch, but the label keeps the default cursor ## Solution * replaces the radix switch with base ui, and keeps a native `<button>`, so labels and `role="switch"` work as before * changes the thumb to white and the resting track one step darker, so the off state shows on light pages * replaces the hover color change with a thumb stretch that grows more on press, so the thumb reacts to the pointer * adds a pointer cursor on labels next to an enabled switch, because a click on the label toggles it * removes the `PointerEvent` stand-in from the studio test setup, because it blocks base ui switch clicks in jsdom * changes the install step in the switch docs to `@base-ui/react`, so the manual install matches the component <!-- linear:table-colwidths:345,344 --> <table> <thead> <tr> <th></th> <th>preview</th> </tr> </thead> <tbody> <tr> <td>light</td> <td> https://github.com/user-attachments/assets/a7c33dda-3487-43b8-881b-344e28891650 </td> </tr> <tr> <td>dark</td> <td> https://github.com/user-attachments/assets/9718057b-f983-4099-8f7e-82521001b625 </td> </tr> </tbody> </table> ## Preview links | Site | Live | Preview | Search for | | -- | -- | -- | -- | | Design system | [/design-system/docs/components/switch](<https://supabase.com/design-system/docs/components/switch>) | [/design-system/docs/components/switch](<https://design-system-git-feat-switch-base-ui-supabase.vercel.app/design-system/docs/components/switch>) | Airplane Mode | | Studio | [/dashboard/project/\_/storage/files](<https://supabase.com/dashboard/project/_/storage/files>) | [/dashboard/project/\_/storage/files](<https://studio-git-feat-switch-base-ui-supabase.vercel.app/dashboard/project/_/storage/files>) | Public bucket | ## Review instructions 1. open [/design-system/docs/components/switch](<https://supabase.com/design-system/docs/components/switch>) and [/design-system/docs/components/switch](<https://design-system-git-feat-switch-base-ui-supabase.vercel.app/design-system/docs/components/switch>) side by side 2. hover and click the "airplane mode" label, and make sure that the cursor is a pointer and the switch toggles 3. change the theme to light and to dark, and make sure that the thumb stays white in the on and off states 4. scroll to the form example, and make sure that the disabled "security emails" switch does not toggle or stretch 5. open [/dashboard/project/\_/storage/files](<https://studio-git-feat-switch-base-ui-supabase.vercel.app/dashboard/project/_/storage/files>), click "new bucket" and turn on "public bucket", and make sure that the "public buckets are not protected" warning shows ## Checklist Check all before review: - [X] I have read [CONTRIBUTING.md](<https://github.com/supabase/supabase/blob/master/CONTRIBUTING.md>) - [X] If I wrote a new docs topic or edited an existing topic, I used the `/write-the-docs` or `/edit-the-docs` skill, which applies the docs [style guide](<https://github.com/supabase/supabase/tree/master/apps/docs/style-guide>) |