mirror of
https://github.com/supabase/supabase.git
synced 2026-12-04 07:29:16 +00:00
docs/tutorial-template
47
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
ccd691423b |
[FE-5114] (part 6) – refactor(studio): migrate platform storage routes (#54033)
## Problem Studio's `routes/api/platform/storage/**` routes still run legacy Next Pages Router handlers through `compat/next/api.ts`, and `buckets/$id/objects/download.ts` has no remaining callers. Part 6 of 7 for [FE-5114](https://linear.app/supabase/issue/FE-5114/rewrite-api-routes-as-native-tanstack-start-handlers-and-remove-the) migrates the 14 active storage routes to native TanStack Start handlers and removes the unused download route. ## Solution **Changed:** - Migrated 14 `buckets/**` and `vector-buckets/**` routes to `createApiHandlers` and `parseJsonBody` - Replaced the `parseAsInt`/`parseAsString`/`parseAsStringEnum` helpers in `buckets/index.ts` with a zod query schema that drops invalid values, keeping the conditional spreads so unset keys aren't sent to storage-js - Forwarded upstream `StorageError` status codes across all storage and vector-bucket routes via `storageErrorResponse` / `getStorageErrorStatus` (falling back to the route's default 400/500 when no valid HTTP status is present) - Guarded missing/invalid `SUPABASE_PUBLIC_URL` with a `500` error response in `objects/public-url`, `objects/sign`, and `objects/sign-multi` - Typed the `vector-buckets/$id/indexes` POST body from storage-js's `createIndex` options - Corrected stale `Allow` headers on `vector-buckets/$id` (`GET, DELETE`) and `vector-buckets/$id/indexes/$indexName` (`DELETE`) via `createApiHandlers` **Added:** - `lib/api/self-hosted/storage.ts` with `getStorageErrorStatus`, `storageErrorResponse`, `getStoragePublicOrigin`, `missingStoragePublicUrlResponse`, and `remapStoragePublicUrl` - Unit tests for `buckets/index` query parsing, `buckets/$id/objects/sign-multi` (`SUPABASE_PUBLIC_URL` guard, origin remapping, and upstream error status), and `vector-buckets` POST (exercising the real storage client through MSW) **Removed:** - Removed unused `routes/api/platform/storage/$ref/buckets/$id/objects/download.ts` and regenerated `routeTree.gen.ts` **Behavior changes vs master:** - `buckets` GET drops malformed `limit`/`offset`/sort values instead of `parseInt`-truncating them (e.g. `offset=1.5` is ignored rather than sent as `1`) - `vector-buckets` POST validates the body with zod and returns `400` when `bucketName` is missing or not a string - Storage routes forward the upstream HTTP status code from `StorageApiError` instead of hardcoding `400`/`500` - `objects/public-url`, `objects/sign`, and `objects/sign-multi` return a `500` JSON error when `SUPABASE_PUBLIC_URL` is unset or invalid instead of throwing an uncaught `TypeError` - Unused `buckets/$id/objects/download` route has been removed ## Review instructions 1. Run `pnpm --filter studio exec vitest run tests/routes/api/platform/storage/`. 2. On self-hosted Studio, create/list/empty/delete a storage bucket, upload/download/move/sign/delete an object, and check vector bucket operations. ## 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: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
37414c5a61 |
[FE-5114] (part 5) – refactor(studio): migrate platform project routes (#54032)
## Problem Studio's `routes/api/platform/projects/**` routes still run legacy Next Pages Router handlers through `compat/next/api.ts`, and `projects/$ref/config/index.ts` and `projects/$ref/billing/addons.ts` are unused in self-hosted mode. Part 5 of 7 for [FE-5114](https://linear.app/supabase/issue/FE-5114/rewrite-api-routes-as-native-tanstack-start-handlers-and-remove-the) migrates the 19 active project routes to native TanStack Start handlers and removes the 2 unused routes. ## Solution **Changed:** - Migrated 19 project routes — analytics (`endpoints/$name`, `log-drains`, `log-drains/$uuid`), API proxies (`api/graphql`, `api/rest`), content snippets & folders (`content/**`), and config/settings/databases/lints/keys/monitoring routes — to `createApiHandlers` - Preserved FE-5124 fixes on `log-drains/$uuid` (empty-body `204` on `DELETE`, `try`/`catch` + `!response.ok` → `500`); its `Allow: GET, PUT, DELETE` and the previously stale `Allow` on `log-drains` (`GET, POST`) now come from `createApiHandlers` - Forwarded upstream error status and JSON body (falling back to `500` / `{ error: { message } }`) in `api/graphql` and `api/rest` - Parsed the JSON body once in `content/index.ts` `PUT` so the `not found` create fallback does not attempt to re-read the request stream - `content/index.ts` and `content/folders/index.ts` read query params through `getSearchParamsRecord`, so repeated `ids` (and repeated GET params on `content/index`) return `400` as they did with Next's query parsing - `run-lints` forwards headers via `constructHeaders(Object.fromEntries(request.headers))` **Added:** - `getSearchParamsRecord` in `lib/api/apiHelpers.ts`: collects URL search params into a record, mapping repeated keys to arrays so zod string schemas reject them - `folderQueryParamsSchema` and `listFolderContents(request, folderId?)` in `lib/api/snippets.utils.ts`, shared by `content/folders/index` and `content/folders/$id` - `getLogflareConfig()` in `lib/api/self-hosted/logflare.ts`: reads the Logflare env vars at call time (same `500` naming the missing vars) and builds the request URLs and headers for `analytics/log-drains` and `analytics/log-drains/$uuid` - Unit tests for `getSearchParamsRecord`, `analytics/endpoints/$name`, `analytics/log-drains/$uuid`, `content/index`, `content/folders`, and `api/rest` (`HEAD` and upstream error forwarding) **Removed:** - Removed 2 unused routes (`routes/api/platform/projects/$ref/config/index.ts` and `routes/api/platform/projects/$ref/billing/addons.ts`) and regenerated `routeTree.gen.ts` **Behavior changes vs master:** - `analytics/endpoints/$name` GET strips `name` and `ref` from the forwarded query (parity with master, where they arrived as route params in `req.query`) - `content/folders` and `content/folders/$id` GET validate query params and return `400` for invalid or repeated values - `api/graphql` and `api/rest` forward upstream non-OK status codes and error bodies instead of always returning `500` - Unused `projects/$ref/config/index` and `projects/$ref/billing/addons` routes have been removed ## Review instructions 1. Run `pnpm --filter studio exec vitest run lib/api/apiHelpers.test.ts tests/routes/api/platform/projects/`. 2. On self-hosted Studio, create/update/delete a log drain, create/save/delete a SQL snippet and folder, and verify REST/GraphQL API docs load. ## 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: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
be32a941cd |
[FE-5114] (part 4) – refactor(studio): migrate platform auth and misc routes (#54031)
## Problem Studio's `routes/api/platform/auth/**` and platform misc/stub routes still run legacy Next Pages Router handlers through `compat/next/api.ts`, and 4 legacy database/props routes have no callers left. Part 4 of 7 for [FE-5114](https://linear.app/supabase/issue/FE-5114/rewrite-api-routes-as-native-tanstack-start-handlers-and-remove-the) migrates the 16 active routes to native TanStack Start handlers and removes the 4 unused ones. ## Solution **Changed:** - Migrated `platform/auth/$ref/{invite,magiclink,otp,recover}` to one-line `createAuthSenderHandlers` routes, and `users/index`, `users/$id/index`, and `users/$id/factors` to `createApiHandlers`, preserving the FE-5124 fixes (`Promise.all` MFA factor deletion, `code ?? 500` on auth senders, `Allow: PATCH, DELETE` on `users/$id`, now derived by `createApiHandlers`) - Migrated 9 platform misc/stub routes (`deployment-mode`, `integrations/{$slug,github/*}`, `organizations/{index,$slug/billing/subscription}`, `profile/index`, and `telemetry/event`) - Moved the `FETCH_TYPE_BYPASS_EXCEPTIONS` entries for the four sender routes in `eslint.config.cjs` to `lib/api/self-hosted/auth-senders.ts` **Added:** - `createAuthSenderHandlers(endpoint, field)` in `lib/api/self-hosted/auth-senders.ts`: shared POST handler for the self-hosted GoTrue `invite`, `magiclink`, `otp`, and `recover` endpoints (forwards only `email` or `phone`, uses `constructHeaders` with the service role key, and passes upstream errors through with `code ?? 500`) - Regression tests for `auth/$ref/users/$id/factors`, `auth/$ref/users/$id`, and all four auth sender routes **Removed:** - Removed 4 unused routes (`platform/database/$ref/pooling`, `platform/props/org/$slug`, `platform/props/project/$ref/index`, and `platform/props/project/$ref/api`) and regenerated `routeTree.gen.ts` ## Review instructions 1. Run `pnpm --filter studio exec vitest run tests/routes/api/platform/auth/`. 2. On self-hosted Studio, invite/ban/delete a user, remove MFA factors for a user, and confirm `GET /api/platform/auth/default/users/<id>` returns `405` with `Allow: PATCH, DELETE`. ## 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: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
5fb027c28f |
feat(studio): launch week + builder day sign-ins redirect (#54317)
## Problem - dashboard sign-in sends a user back with `router.push(returnTo)`, and the path stays under `/dashboard` - lw16 card app at `/launch-week` (#54315) signs in with `returnTo=/launch-week?claim=1` and the user lands on a 404 at `/dashboard/launch-week?claim=1` - `validateReturnTo` rejects full urls, and the Builder Day site at `/builderday` has the same problem ## Solution - adds `/dashboard/launch-week` and `/dashboard/builderday` pages that load the same path outside the dashboard + keep the query and the hash - adds a test that a query with another address does not change the destination ## Preview links | Site | Live | Preview | Search for | | ---- | ---- | ------- | ---------- | | Studio | [/dashboard/launch-week?claim=1](https://supabase.com/dashboard/launch-week?claim=1) | [/dashboard/launch-week?claim=1](https://studio-git-antlio-studio-launch-week-return-supabase.vercel.app/dashboard/launch-week?claim=1) | the address bar | | Studio | [/dashboard/builderday](https://supabase.com/dashboard/builderday) | [/dashboard/builderday](https://studio-git-antlio-studio-launch-week-return-supabase.vercel.app/dashboard/builderday) | the address bar | ## Review instructions 1. open the preview [/dashboard/launch-week?claim=1](https://studio-git-antlio-studio-launch-week-return-supabase.vercel.app/dashboard/launch-week?claim=1) and make sure that the address changes to `/launch-week?claim=1` outside `/dashboard` 2. open the preview [/dashboard/builderday](https://studio-git-antlio-studio-launch-week-return-supabase.vercel.app/dashboard/builderday) and make sure that the address changes to `/builderday` 3. sign out and open the preview [/dashboard/sign-in?returnTo=%2Flaunch-week%3Fclaim%3D1](https://studio-git-antlio-studio-launch-week-return-supabase.vercel.app/dashboard/sign-in?returnTo=%2Flaunch-week%3Fclaim%3D1) 4. sign in and make sure that the browser ends at `/launch-week?claim=1` 5. sign out, open the preview [/dashboard/sign-in?returnTo=%2Forganizations](https://studio-git-antlio-studio-launch-week-return-supabase.vercel.app/dashboard/sign-in?returnTo=%2Forganizations) and make sure that the sign-in still returns to `/dashboard/organizations` ## 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) --------- Co-authored-by: Dion Zeneli <101271736+Dionysos288@users.noreply.github.com> |
||
|
|
20a5212c42 |
[FE-5114] (part 3) – refactor(studio): migrate pg-meta and v1 routes (#54030)
## Problem Studio's `routes/api/platform/pg-meta/**` and `routes/api/v1/**` routes still run legacy Next Pages Router handlers through `compat/next/api.ts`, and 10 legacy `pg-meta` GET proxy routes are no longer called anywhere in the repo. Part 3 of 7 for [FE-5114](https://linear.app/supabase/issue/FE-5114/rewrite-api-routes-as-native-tanstack-start-handlers-and-remove-the) migrates the 9 active routes to native TanStack Start handlers and deletes the 10 unused proxy routes. ## Solution **Changed:** - Migrated `platform/pg-meta/$ref/query/index.ts` and all 8 `v1` routes (`api-keys`, `api-keys/$id`, `config/auth/signing-keys/{index,legacy}`, `database/migrations`, `functions/{index,$slug/index}`, `types/typescript`) to `createApiHandlers`; `query` and `database/migrations` share `pgMetaErrorResponse` - Enabled `{ withAuth: true }` on `api-keys`, `api-keys/$id`, and `config/auth/signing-keys/{index,legacy}` for consistency with the other `v1` routes - Updated `api-keys` route tests to use `callRoute` **Added:** - `pgMetaErrorResponse(error)` in `lib/api/self-hosted/pg-meta.ts` (keeps a `PgMetaDatabaseError`'s status and `{ message, formattedError }` payload expected by `data/error-classification.ts`, otherwise `500`) - Unit test for `pg-meta/$ref/query` (`tests/routes/api/platform/pg-meta/$ref/query/index.test.ts`) **Removed:** - Removed all 10 unused `pg-meta` GET proxy routes (`column-privileges`, `extensions`, `foreign-tables`, `materialized-views`, `policies`, `publications`, `tables`, `triggers`, `types`, `views`), removed their `FETCH_TYPE_BYPASS_EXCEPTIONS` entries from `eslint.config.cjs`, and regenerated `routeTree.gen.ts` - Removed `getPgMetaRedirectUrl` (`lib/api/apiHelpers.ts`) and `parseRevealQuery` (`lib/api/self-hosted/api-keys.ts`) **Behavior changes vs master:** - Routes forward only `cookie` and `x-connection-encrypted` to pg-meta via `constructHeaders(Object.fromEntries(request.headers))`, matching what master's adapter forwarded - `database/migrations` GET now forwards headers to `listMigrationVersions` (master passed them as the wrong argument) - `v1/projects/$ref/api-keys*` and `config/auth/signing-keys*` now pass `{ withAuth: true }` (no-op in self-hosted mode; consistent with the other `v1` routes) - The 10 unused `pg-meta` GET proxy routes have been removed (`pg-meta/$ref/query` and `v1/projects/$ref/types/typescript` remain) ## Review instructions 1. Run `pnpm --filter studio exec vitest run tests/routes/api/v1/ tests/routes/api/platform/pg-meta/`. 2. On self-hosted Studio, load tables/views/policies/extensions, run a query in the SQL Editor, check API keys, and generate TypeScript types. ## 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: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
c5fca0a0d7 |
[FE-5114] (part 2) – refactor(studio): migrate AI API routes (#54029)
## Problem Studio's AI API routes under `routes/api/ai/**` still run legacy Next Pages Router handlers through `compat/next/api.ts`. Part 2 of 7 for [FE-5114](https://linear.app/supabase/issue/FE-5114/rewrite-api-routes-as-native-tanstack-start-handlers-and-remove-the) migrates the active AI routes to native TanStack Start (`Request` → `Response`) handlers and drops 3 unused AI endpoints. ## Solution **Changed:** - Migrated 8 active AI routes (`ai/code/complete`, `ai/feedback/{classify,rate}`, and `ai/sql/{check-api-key,cron-v2,filter-v1,generate-v4,title-v2}`) to `createApiHandlers` and `parseJsonBody` - Replaced Node `pipeUIMessageStreamToResponse` in `ai/sql/generate-v4.ts` with native `createUIMessageStreamResponse`, preserving the `x-braintrust-span-id` header - Replaced `req.on`/`res.on` in `ai/sql/generate-v4.ts` with `AbortSignal.any([request.signal, done.signal])` and a `TransformStream` whose `flush`/`cancel` tear down the MCP connection opened in `getTools` on stream completion, cancellation, or setup error - Removed the custom malformed-JSON handling in `ai/code/complete.ts` in favor of the wrapper's `400` - Updated `lib/api/generate-v4.test.ts` to assert against the real native SSE `Response` stream instead of mocking `pipeUIMessageStreamToResponse`, with a shared `mockOpenStream()` helper, a stream-cancellation abort test, and a Braintrust tracing test asserting `x-braintrust-span-id` matches the exported root span - Updated `lib/ai/README.md` to drop references to removed endpoints **Removed:** - Removed 3 unused AI routes (`routes/api/ai/onboarding/design.ts`, `routes/api/ai/sql/parse-client-code.ts`, and `routes/api/ai/sql/policy.ts`), dropped them from `lib/hosted-api-allowlist.ts`, and regenerated `routeTree.gen.ts` - Removed the now-unused `withoutApprovalTools` helper from `lib/ai/tool-filter.ts` and its test from `lib/ai/tool-filter.test.ts` **Behavior changes vs master:** - `ai/code/complete` returns the wrapper's `400` JSON `{ error: { message: 'Invalid JSON' } }` for malformed bodies - Unused `ai/onboarding/design`, `ai/sql/parse-client-code`, and `ai/sql/policy` endpoints have been removed ## Review instructions 1. Run `pnpm --filter studio exec vitest run lib/api/generate-v4.test.ts lib/api/rate.test.ts lib/ai/tool-filter.test.ts`. 2. Send a prompt in the AI Assistant panel, verify streaming output, and cancel mid-stream. 3. Trigger SQL title, cron, and filter generation as well as AI code completion. ## 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: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
b6c391a058 |
[FE-5114] (part 1) – refactor(studio): add native API helpers & routes (#54028)
## Problem Studio's `routes/api/**` server routes still run legacy Next Pages Router handlers through the `toWebHandler` shim in `compat/next/api.ts`. Part 1 of 7 for [FE-5114](https://linear.app/supabase/issue/FE-5114/rewrite-api-routes-as-native-tanstack-start-handlers-and-remove-the) adds native TanStack Start (`Request` → `Response`) helpers and migrates the top-level utility routes so we can remove the adapter at the end of the stack. ## Solution **Added:** - `createApiHandlers` in `lib/api/apiWrapper.ts`: wraps native TanStack Start route handlers with optional platform JWT auth, JSON `400` (`{ error: { message: 'Invalid JSON' } }`) on `InvalidJsonError`, Sentry capture + generic `500` on unexpected throws, and an `ANY` handler that returns `405` with an `Allow` header derived from the registered methods. Exports `ApiHandler` / `ApiHandlerContext` (`params` is `Record<string, string>`) - `authenticateRequest` in `lib/api/apiAuthenticate.ts` (Web `Request` counterpart of `apiAuthenticate`, same error messages) - `InvalidJsonError` and `parseJsonBody` in `lib/api/apiHelpers.ts` - `callRoute(route, request, params)` test helper in `tests/lib/server-route.ts` - Unit tests for `createApiHandlers` (exercising real `authenticateRequest` through MSW in `lib/api/createApiHandlers.test.ts`), `authenticateRequest`, `parseJsonBody`, `/api/generate-attachment-url`, and `/api/integrations/stripe-sync` **Changed:** - Updated `getRouteHandler` in `tests/lib/server-route.ts` to mirror TanStack Start's `HEAD` → `GET` → `ANY` dispatch order - Migrated 11 top-level API routes (`check-cname`, `cli-release-version`, `content/graphql`, `edge-functions/test`, `enabled-features-overrides`, `generate-attachment-url`, `get-deployment-commit`, `get-ip-address`, `get-s3-keys`, `get-utc-time`, `integrations/stripe-sync`) to native handlers - Added `withAuth: true` to `check-cname`, `content/graphql`, and `integrations/stripe-sync`, and updated `check-cname-mutation.ts` and `data/graphql/execute.ts` to attach `constructHeaders()` - Reused `withAuth` `claims` in `generate-attachment-url` to avoid a duplicate GoTrue lookup in platform mode - Converted `tests/routes/api/get-deployment-commit.test.ts` to `callRoute` **Removed:** - Removed 2 unused routes (`routes/api/connect/index.ts` and `routes/api/parse-query.ts`), dropped `/parse-query` from `lib/hosted-api-allowlist.ts`, removed Nitro's `traceDeps: ['libpg-query*']` in `vite.config.ts` (no server runtime route imports `libpg-query` anymore), and regenerated `routeTree.gen.ts` **Behavior changes vs master:** - Methods a route doesn't register now get a JSON `405` with an `Allow` header (previously they fell through to the SSR app). `HEAD` requests that TanStack Start dispatches to a `GET` handler also get `405`, matching master's method switches - `InvalidJsonError` returns JSON `{ error: { message: 'Invalid JSON' } }` (`400`) instead of plain text - `check-cname`, `content/graphql`, and `integrations/stripe-sync` now verify the platform JWT via `withAuth: true` - Unexpected throws return a generic `500` with `{ error: { message: 'Internal Server Error' } }` - Unused `/api/connect` and `/api/parse-query` routes have been removed ## Review instructions 1. Run `pnpm --filter studio exec vitest run lib/api/apiAuthenticate.test.ts lib/api/apiHelpers.test.ts lib/api/apiWrappers.test.ts lib/api/createApiHandlers.test.ts tests/routes/api/ scripts/__tests__/server-source-maps.test.ts`. 2. Smoke-test `/api/get-deployment-commit`, `/api/check-cname`, `/api/content/graphql`, `/api/generate-attachment-url`, and `/api/edge-functions/test` in Studio and confirm unsupported HTTP methods return `405` with an `Allow` header. ## 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: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
c9a25cf11f |
Joshenlim/fe 5172 deprecate old table component (#53728)
## Context More housekeeping - deprecates the old Table component in favor of the Table component under `ui` JFYI also realised as part of this that the following 2 routes are unreachable from the dashboard and hence am opting to deprecate them with a redirect - /logs/explorer/recent - /logs/explorer/saved ## Areas affected to check - [ ] Integrations -> Webhooks <img width="600" alt="image" src="https://github.com/user-attachments/assets/58523cdb-6219-49be-9d2f-5bc26ae03d7f" /> - [ ] Database -> Column Privileges <img width="600" alt="image" src="https://github.com/user-attachments/assets/98bea654-24ac-4646-9c65-5bc4f18565e9" /> - [ ] Observability -> API <img width="600" alt="image" src="https://github.com/user-attachments/assets/a6512c6f-bd04-4d25-8e3c-99c85883434a" /> - [ ] Observability -> Storage - Its a table under "Request caching" which I don't have data for 😅 🙏 - [ ] Observability -> Database <img width="600" alt="image" src="https://github.com/user-attachments/assets/4f0ba203-64b3-41f7-971e-974e232bdedd" /> - [ ] Table Editor -> Project API Docs -> Column list <img width="600" alt="image" src="https://github.com/user-attachments/assets/6358e7a8-5770-46f9-a5a2-4851855ae97f" /> - [ ] Table Editor -> Project API Docs -> RPC parameters list <img width="600" alt="image" src="https://github.com/user-attachments/assets/5e45a1d6-cd29-451c-bf00-5d806ef37cec" /> |
||
|
|
48c90094d9 |
feat(studio): show Warehouse query activity in Observability (#53495)
## Problem Warehouse query activity is not available in Observability. ## Solution Add a Warehouse report showing query rate over the last hour, with loading, setup, no-data and request-error states. The report uses live project metrics and appears in navigation for projects with Warehouse access. | After | | --- | | <img width="2548" height="1416" alt="CleanShot 2026-11-17 at 16 55 33@2x" src="https://github.com/user-attachments/assets/4d6796e0-72f1-45d5-b6b7-2cd4a3577496" /> | | <img width="2552" height="1390" alt="CleanShot 2026-11-17 at 16 56 18@2x" src="https://github.com/user-attachments/assets/d96efdfd-4ca9-42fe-ac30-9cb4667c95d7" /> | | <img width="2544" height="1388" alt="CleanShot 2026-11-17 at 16 32 11@2x" src="https://github.com/user-attachments/assets/bc80af8d-0468-4229-98d0-ac2681823059" /> | | <img width="2560" height="1344" alt="CleanShot 2026-11-17 at 16 59 53@2x" src="https://github.com/user-attachments/assets/1ed70348-c2fc-4673-85a7-530d9734886c" /> | Visitor | What they see -- | -- Signed-in customer without Warehouse access | No Warehouse entry in Observability Customer with Warehouse access, not configured | “Warehouse is not set up” empty state and setup button Customer with Warehouse disabled | “Warehouse is disabled” empty state and setup button Customer with active Warehouse | Query rate chart, or the relevant loading/empty/error state ## Review instructions 1. Open the [Studio staging preview](https://studio-staging-git-dnywh-warehouse-metrics-client-supabase.vercel.app) with a staging project that has Warehouse access. 2. Go to **Observability > Warehouse**, or `/project/<ref>/observability/warehouse` ([example](https://studio-staging-git-dnywh-warehouse-metrics-client-supabase.vercel.app/dashboard/project/yirnfrgkxmnqgexikhfc/observability/warehouse)). 3. Check the query-rate chart after running Warehouse queries. A project without measurements shows an explicit last-hour empty state. 4. Open the report on a project where Warehouse is not set up and check the setup link. --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
d7f2b501b5 |
feat(studio): add the issue detail page (#52991)
Add issue details, affected resources, and copy actions with coverage for secondary checks and clipboard outcomes. |
||
|
|
e04c556bd5 |
feat(studio): add the issues list (#52990)
Add the Issues list, URL filters, and overview counts with complete advisor refresh handling. |
||
|
|
cd0b65c03e | feat(logs): Add Pipelines to unified logs and rename ETL to Pipelines (#52555) | ||
|
|
d98c277790 |
feat(studio): rotate Storage URL signing keys FE-4433 (#52165)
## Problem Rotating a project's Storage URL signing key currently needs a support ticket, so customers can't rotate on their own timeline or keep a standby key until their signed URLs have migrated. Linear: [FE-4433](https://linear.app/supabase/issue/FE-4433/allow-users-to-rotate-storage-url-signing-keys-via-ui) ## Solution Adds a URL signing keys page at `/project/{ref}/storage/signing-keys`, linked from the Storage menu. It builds on the design prototype from `feat/storage-rotate-signing-keys` and follows the current JWT Keys page styling. - Active key, standby key, and revoked keys are shown in separate tables, so there is only ever one active key. The UI allows one standby key at a time. - Create a standby key (ES256 by default, HS512 optional), rotate the standby key to active, revoke a standby key, or move a revoked key back to standby. - The key list reports JWK types (`EC`, `oct`), which are mapped to ES256 and HS512 labels. Unrecognized types fall back to the raw value. - Telemetry: `storage_url_signing_key_created` and `storage_url_signing_key_updated` (with a `change` property), fired when the action succeeds. - A "Created at" column is not included yet because the keys endpoint doesn't return it. It will follow in a later PR. <img width="1272" height="846" alt="Screenshot 2026-10-23 at 11 43 45" src="https://github.com/user-attachments/assets/980742ed-6c4e-43d1-b170-847e550fde4c" /> ## Review instructions 1. Open the preview and go to Storage > URL signing keys on a project. 2. Create a standby key, then rotate it to active. The previous active key should move to standby. 3. Revoke the standby key (type its ID to confirm), then move it back to standby from the revoked table. 4. Compare the table styling with Project Settings > JWT Keys. 5. Check that creating a standby key and moving a revoked key to standby are disabled while a standby key exists. ## 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) --------- Co-authored-by: Francesco Sansalvadore <f.sansalvadore@gmail.com> |
||
|
|
d8b4d7bc8f |
Revert "Joshenlim/fe 4676 port log drains api endpoints from platform to v2" (#52137)
Reverts supabase/supabase#51995 |
||
|
|
3af897e6d6 |
Joshenlim/fe 4676 port log drains api endpoints from platform to v2 (#51995)
## Context Just porting over log drains API from `platform` to `v2` - verified that log drains management still works locally ## To test - [ ] Staging preview: Verify that you can create, read, and delete - there's no way to update log drains atm - [ ] Local / Self-hosted: Verify that you can create, read, and delete |
||
|
|
27e6259a39 |
chore(studio): remove legacy status banner and incidentIoStatusPage flag (#51852)
## Summary The incident.io status page is now the only status banner for everyone, so the legacy status banner path is removed: - Removed the `incidentIoStatusPage` ConfigCat flag. The incident.io path is unconditional. - Deleted the legacy status banner code (`StatusPageBanner` and its utils/visibility hook) and its tests. - Deleted the legacy API endpoints `/api/incident-banner`, `/api/incident-status`, and `/api/status-override` (pages, app, and routes variants), along with their data hooks, query keys, and lib helpers. - Removed `STATUSPAGE_*` env vars from the Turbo config and the `INCIDENT_BANNER_DISMISSED_IDS` local storage key from `packages/common`. - Updated the AI tools and SQL generation endpoint that read the flag. `NEXT_PUBLIC_ONGOING_INCIDENT` / the `ongoingIncident` override is kept. The `incident_status_cache` table and its migration are intentionally untouched. Studio no longer reads it, and dropping it is a separate cleanup. ## Testing - Studio typecheck passes. - Related vitest suites pass (414 tests). |
||
|
|
09a4374b14 |
Fix: ensure the scoped oauth apps new UI doesn't show if mocks are enabled (#51829)
## Problem The feature flag enabling the new scoped oauth apps UI was enabled by mistake in production but this UI currently only work with mocks. We added an environment check in some places but not all so users did see the new UI ## Solution Add the environment check wherever needed |
||
|
|
4593b3ffc0 |
feat(studio): compose pipeline creation step navigation (#51776)
## Problem The pipeline wizard in #49243 needs its merged components composed into a full-page flow, with values preserved when moving backwards and forwards. ## Solution - Compose four full-page SteppedFlow steps behind **Pipeline creation wizard**. - Preserve values through step navigation and browser Back/Forward. Refresh starts at Destination. - Reuse Studio’s header controls and confirm before discarding changes. - Defer step validation and creation; **Start pipeline** is disabled. **Add pipeline** and preview-off visits keep the sheet. | After | | --- | | <img width="1024" height="759" alt="New Pipeline Supabase" src="https://github.com/user-attachments/assets/7c3c4511-9a00-4e64-a86a-d6d9489f7d75" /> | | _Only available by navigating to `database/pipelines/new` with the feature preview on._ | ## Review instructions 1. Open the [Pipelines preview](https://studio-staging-git-dnywh-featpipeline-stepped-n-ce5307-supabase.vercel.app/dashboard/project/_/database/pipelines), select a test project and enable **Pipeline creation wizard**. Open the [wizard preview](https://studio-staging-git-dnywh-featpipeline-stepped-n-ce5307-supabase.vercel.app/dashboard/project/_/database/pipelines/new) for that project. Check the full-page layout and header at desktop and phone widths. 2. Enter connection details, select a publication and change initial-sync and advanced settings. Use **Back/Continue**, browser **Back/Forward**, and switch destinations to confirm values remain. 3. Check Review shows your settings, masks secrets and disables **Start pipeline**. Refresh and confirm it restarts at Destination. Incomplete steps are allowed in this navigation-only slice. 4. With changes, try header navigation or **Close**. Check **Keep editing** preserves values and **Discard changes** leaves the flow. Turn the preview off and confirm the wizard URL opens the sheet. |
||
|
|
c8c12a87b4 |
feat(studio): add support satisfaction survey page (#51648)
## Problem After a support ticket is resolved, customers receive an email with a link to a satisfaction survey. That survey page is currently served from a standalone function outside this repo. We are consolidating it into the dashboard so it is deployed, monitored and tested with everything else. Linear: [TOOLING-1425](https://linear.app/supabase/issue/TOOLING-1425/build-csat-in-supase-studio) ## Solution Adds a public page at `/support/csat` that collects the survey answer and posts it to a new Platform endpoint, `POST /platform/support/csat`, which records the answer on the support conversation. Key choices: - **Pre-auth page**, modelled on `/verify-email`. Customers arrive from an email and may not have a dashboard session. Hosted platform only; self-hosted routes to 404. - **URL shape** `?conversation_id=cnv_…&helpful=yes|no` matches the links already sent in survey emails, so the email template only needs its host changed. `helpful` preselects the answer, defaulting to Yes. - **Copy and behaviour match the existing survey page**: same title, question, labels, button text, and result messages. - **Form** uses react-hook-form + zod; Yes/No are toggle buttons, the comment is optional. - **States**: missing or malformed ticket reference, already submitted (409), ticket mismatch (404), and a generic error that keeps the form so the customer can retry. - The mutation uses `fetchHandler` directly, like the email-verification mutation, because the endpoint is not in the generated API types yet. Screenshot: <img width="977" height="801" alt="image" src="https://github.com/user-attachments/assets/2331861e-e8e9-43e1-84fc-3bf5786c145e" /> Depends on the Platform endpoint https://github.com/supabase/platform/pull/40027. Until it is deployed, submissions fail with the generic error state. ## Review instructions 1. Run Studio against a Platform stack that has the `POST /platform/support/csat` endpoint. 2. Open `/support/csat?conversation_id=<a support conversation id>&helpful=yes` while logged out. The page renders without redirecting to sign in, with Yes preselected. 3. Pick an answer, optionally add a comment, and submit. The success message appears and the answer is recorded on the conversation. 4. Submit again for the same conversation: the page reports that the survey has already been submitted. 5. Open the page with no `conversation_id`: the page reports an invalid ticket. 6. `pnpm --filter studio exec vitest --run components/interfaces/Support/CsatSurvey` passes (18 tests). ## 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: Gildas Garcia <1122076+djhi@users.noreply.github.com> |
||
|
|
88bc1ac384 |
feat(studio): oauth apps users own grant list in account settings (#50903)
## Purpose Users now have an _apps_ page in their account settings allowing them to see their own grants, the projects they affect and to disconnect an app. This PR only uses mock data. Besides, the page and menu item are behind a feature flag enabled on staging <!-- ## 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 - In _Account/OAuth Apps_, you should see a list of apps <img width="748" height="359" alt="image" src="https://github.com/user-attachments/assets/8c50a467-e2c1-4000-aecf-09d5db1591d3" /> - Each app should have a menu entry allowing to disconnect it (fake for now) <img width="587" height="278" alt="image" src="https://github.com/user-attachments/assets/6221fbd6-3b61-4d93-903e-9aedaf94de3f" /> - Each app but the last should have a menu entry that opens a dialog to see the connected projects <img width="657" height="651" alt="image" src="https://github.com/user-attachments/assets/e985f933-fdfb-4d28-93c3-b3678d7d8a53" /> --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
6572fad288 |
fix(studio / ui) - update xss vuln version of tanstack (#51141)
## Problem When I bumped the pnpm-lock file in an unrelated KB fix (#51132), I believe that refreshed the build cache (either that, or Vercel started flagging this issue very recently). At any rate, builds are now failing b/c of a [vulnerable Tanstack/react-start package](https://github.com/TanStack/router/security/advisories/GHSA-qx66-fv34-fjm8), which this PR attempts to fix. ``` The build blocks vulnerable @tanstack/react-start@1.168.18 due to an XSS security check. ``` <img width="1355" height="397" alt="image" src="https://github.com/user-attachments/assets/7d0d90fb-009c-4a0b-aadc-b526e0fcce0a" /> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Chores** * Updated project maintenance settings and supporting TanStack package versions. * Improved error reporting so standard errors include their stack trace, while other error values are logged directly. * No app features were added or removed. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com> |
||
|
|
b2cf3693dd |
feat(studio): /api/status-page endpoint backed by incident.io Widget API (#50931)
## Summary * Adds `/api/status-page` (Next route + TanStack wrapper), backed by the [incident.io](<http://incident.io>) Widget API, annotating each item with `visible`, `show_banner`, and (for scheduled maintenances) `banner_lead_days`. * Deployment-mode visibility is driven by a new `status_page:visibility_field_ids` custom-content key. * Widget array parsing is fault-tolerant: a malformed item in one array is dropped and logged rather than failing the whole response, so one bad item can't hide a real ongoing incident. * 429s from [incident.io](<http://incident.io>) are retried with equal-jitter exponential backoff, respecting `Retry-After`, up to 2 retries. * Nothing consumes this endpoint yet — it replaces no existing behavior and changes nothing user-visible. Later PRs (this is PR 1 of a stack) wire up consumers behind the `incidentIoStatusPage` ConfigCat flag. Part of [FE-4057](https://linear.app/supabase/issue/FE-4057/frontend-bannerbot-reconfigured) — see Linear for full design context. ## Test plan - [X] `pnpm --filter studio run typecheck` - [X] `pnpm --filter studio run lint:ratchet` - [X] `pnpm knip --workspace apps/studio` - [X] `pnpm test:prettier` - [X] `pnpm --filter studio exec vitest run status-page` — 44 tests passing, including a regression test built from a real production [incident.io](<http://incident.io>) payload that initially failed to parse, and a compile-time type-safety regression test for the array-parsing helper Co-authored-by: Claude Code [charis@supabase.io](<mailto:charis@supabase.io>) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added a status page that displays ongoing incidents and maintenance, with visibility and banner settings based on linked incident details. * Status page data is available through a new API endpoint, with caching for successful responses and degraded results. * **Bug Fixes** * Status page data can still display when some linked incident details are unavailable; affected results are marked as degraded. * Improved handling of invalid widget entries so they don’t prevent valid items from being processed. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Claude Code <charis@supabase.io> |
||
|
|
12894ddd2a |
feat(studio): migrate storage infinite-query hook to list-v2 (#50730)
## Problem Storage's `list` (v1) endpoint is being deprecated in favor of `list-v2`, which uses cursor pagination instead of numeric offset (which degrades on large buckets) and fixes folders that differ only by case not both being listable. This is PR 1 of the migration (parent: FE-4423); it covers the shared infinite-query hook and its two consumers. ## Solution Added `listBucketObjectsV2` alongside the existing v1 `listBucketObjects` (still used elsewhere, migrated in a later PR), and replaced the `useBucketObjectsInfiniteQuery` hook with `bucketObjectsInfiniteQueryOptions` built on `infiniteQueryOptions`, following the repo's preferred data-fetching pattern. Pagination now uses `hasNext`/`nextCursor` instead of an offset multiplier, and `queryFn` rejects a response that claims `hasNext` without advancing the cursor so a misbehaving backend can't send `fetchNextPage` into an infinite loop. v2 splits results into separate `folders`/`objects` arrays and has no `search` field, so the two consumers (`BucketFilePickerColumn`, `MoveItemsFolderPicker`) merge/sort those arrays themselves, and search is folded into a `prefix` match instead. Also removed "Time last accessed" from the picker's sort dropdown since v2's `sortBy.column` doesn't support it, with a defensive fallback to `name` in case the shared sort preference (still used by the v1 main file explorer) carries that value over. Added the missing self-hosted `list-v2` API proxy route (`pages/api` + the TanStack `routes/api` wrapper) using storage-js's `listV2()`, since self-hosted Studio only had a v1 route and every v2 request was 404ing there. ## Review instructions 1. Open the bucket file picker (e.g. via an OAuth app logo upload), confirm folders and files both render and paginate correctly, and that searching still filters as expected. 2. Open the "Move items" modal's folder picker, confirm you can navigate into and back out of subfolders, and that folder search still works. 3. Run `pnpm test:studio -- MoveItemsModal`. ## 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 references [WORD_LIST](https://github.com/supabase/supabase/blob/master/apps/docs/WORD_LIST.md) and the docs [CONTRIBUTING](https://github.com/supabase/supabase/blob/master/apps/docs/CONTRIBUTING.md) guide 🤖 Generated with [Claude Code](https://claude.com/claude-code) <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Storage browsing loads large bucket listings in pages, helping keep navigation responsive. * Folder pickers display folders and files together across paginated results. * Moving items between folders uses the same paginated browsing experience. * Search remains available in the final folder level, and folder navigation shows the correct contents. * **Updates** * “Time last accessed” is no longer available as a sorting option in storage pickers. Sorting is available by name, creation time, or update time. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Claude Sonnet 5 <noreply@anthropic.com> |
||
|
|
05a45dd1ed |
feat(studio): rename Replication to Pipelines (#50637)
## What kind of change does this PR introduce? Feature and docs update. ## What is the current behavior? The Dashboard lists Pipelines destinations under Database > Replication. Read replicas have moved to Infrastructure, but the temporary notices remain on the destinations page and new destination sheet. Closes PIPE-1021. ## What is the new behavior? The canonical Dashboard routes are Database > Pipelines, while legacy Replication list and detail URLs permanently redirect to the equivalent Pipelines routes. Navigation, command palette, shortcuts, pipeline links, docs, and current marketing copy use Pipelines. Read-replica notices and their obsolete dismissal state are removed. | Before | After | | --- | --- | | <img width="1024" height="759" alt="Replication Database Agua Basket Supabase" src="https://github.com/user-attachments/assets/53f9f565-1ed1-43e9-a7d9-b66b2a47e948" /> | <img width="1024" height="759" alt="2540" src="https://github.com/user-attachments/assets/14ab2d61-d01c-483f-9d4f-0ac286dae159" /> | The Management API, pipeline behaviour, replication logs, and Postgres replication terminology remain unchanged. ## To test - Open `/project/<ref>/database/pipelines` and confirm the Database navigation, page header, and pipeline breadcrumb say Pipelines. - Open `/project/<ref>/database/replication?source=bookmark#destinations` and a legacy pipeline detail URL. Confirm each redirects to the matching Pipelines URL while preserving parameters and fragments. - From the Pipelines page, open Add destination. Confirm no read-replica migration notice appears. - Open the Pipelines guide and confirm its Dashboard steps lead to Database > Pipelines. ## Before merge - [ ] Get changelog entry reviewed https://github.com/supabase/changelog/pull/262 and prepare to merge simultaneously <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added dedicated **Database > Pipelines** pages for pipeline lists and details. - Added permanent redirects from legacy Replication URLs to their corresponding Pipelines pages. - Read replica management links now open **Settings > Infrastructure**. - **Documentation** - Updated Pipelines setup, monitoring, troubleshooting, and usage guidance to reference the current dashboard locations. - Updated Realtime guidance to use **Database > Publications**. - **Updates** - Renamed dashboard navigation, breadcrumbs, commands, and keyboard shortcuts from **Replication** to **Pipelines**. - Removed the “Read replicas have moved” notification. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
d276f75c89 |
Recovery codes: allow users to use recovery codes to access their account (#50569)
## What kind of change does this PR introduce? Allow users to sign in using a recovery code after being redirected to the MFA verification page. ## Additional context <img width="435" height="373" alt="image" src="https://github.com/user-attachments/assets/968fd15e-3081-4aa2-b645-4e0d2ec2637c" /> <img width="494" height="404" alt="image" src="https://github.com/user-attachments/assets/fd7cee49-dca7-4f1a-873a-293e21c68faa" /> ## How to test - Enable MFA on your account if needed - Generate recovery codes if needed (make sure you actually saved the recovery codes somewhere) - Sign out - Sign in and when redirected to the MFA verification page, click the _Authenticate using a recovery code_ link - Enter one recovery code Check that: - you're signed in - when on [your account security page](https://studio-staging-git-gildasgarcia-auth-1624-dashb-177251-supabase.vercel.app/dashboard/account/security), you have one less code available Then: - Disable the `enableAuthRecoveryCodes` config cat flag - Sign out - Sign in and wait on the MFA verification page Check that: - the _Authenticate using a recovery code_ link is not displayed - Accessing [the recovery code sign in page](https://studio-staging-git-gildasgarcia-auth-1624-dashb-177251-supabase.vercel.app/dashboard/sign-in-recovery-code) redirects you to the MFA page <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added recovery-code authentication as an alternative MFA sign-in method. * Added a dedicated recovery-code sign-in page with validation, visibility controls, cancellation, and sign-out options. * Added a link from the MFA sign-in screen when recovery codes are available. * Added loading and error states while checking recovery-code availability. * **Bug Fixes** * Prevented valid recovery-code sign-ins from being redirected back to the MFA prompt. * Limited recovery-code settings to accounts with exactly one enrolled authenticator. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Ali Waseem <waseema393@gmail.com> |
||
|
|
edec85d1ca |
fix(pipelines): Make pipeline actions and status updates reliable (#50085)
## Summary Make pipeline actions and status feedback reliable while requests are running or fail. Let the backend coordinate table resets and restarts, keep stopped pipelines stopped after resets or settings changes, and refresh the UI from confirmed backend state. ## Pipeline actions and recovery - Reset one table, all errored tables, or all tables through the rollback endpoint without separate frontend stop/start requests. Explain which destination data is deleted, which rows are copied again, initial sync charges, and the skip-initial-sync setting. - Keep pending feedback until the action and a fresh status read finish, including across navigation and polling errors. Prevent overlapping actions and disable start/stop controls when status is unavailable or transitioning. - Close the creation form once the pipeline is created. If its initial start fails, users can retry Start on the existing pipeline without creating a duplicate. - Wait for confirmed shutdown before deletion; a shutdown error or timeout leaves deletion retryable. Keep failed version updates open and avoid reporting success. - Clarify recovery guidance and pending labels, suppress duplicate error toasts, and hide stale table errors during transitions. ## Status updates and shared UI - Poll pipeline status and table metrics one second after each response, share in-flight reads, pause dashboard polling in background tabs, and respect rate-limit backoff. The shutdown waiter continues in the background. - Refresh metadata after mutations even when an older read is in flight, while preserving shared polling requests. Refresh affected data after failures that may follow a committed reset or settings change. - Move pending request state into the shared, project-keyed `DatabaseLayout` so the list, detail page, and diagram stay consistent. The surrounding database-page changes update named imports in both Next.js and TanStack routes. - Simplify action, status, and form rendering; announce status changes to assistive technology; and sort table statuses without mutating cached data. --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> Co-authored-by: Danny White <3104761+dnywh@users.noreply.github.com> |
||
|
|
9cdd412bab | feat(stripe-atlas): mock-up dashboard to enable live testing (#50327) | ||
|
|
0bf22ee6fc |
chore(studio): update product naming (#50208)
workers -> compute <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added the Compute experience for deploying, viewing, managing, and monitoring compute instances. - Added Compute navigation, instance detail pages, secrets, logs, deployment dialogs, generated snippets, and CLI commands. - Added filtering, status, availability, and data-loading support for compute instances. - **Updates** - Updated labels, icons, links, feature controls, unified logs, and secret-deletion messaging to use Compute terminology. - Compute routes now replace the previous Workers routes and pages. <!-- end of auto-generated comment: release notes by coderabbit.ai --> |
||
|
|
41e6d489f8 |
feat(studio): mcp elicitation url mode ui (#49954)
## 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? Initial build of the URL mode interstitial. Has complete mock data to be able to view different states (this will be stripped out in the end). A starting point for us to use as an intercept. This is linked with @barryroodt ticket in the MCP project. https://github.com/supabase/mcp/pull/412 <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added an authenticated MCP Secrets page for securely storing API secrets requested by AI tools. - Added provider-aware guidance for OpenAI, Anthropic, Resend, and Stripe keys, including validation warnings and dashboard links. - Added clear success, cancellation, expiration, error, and wrong-account states with account switching. - Added loading placeholders, secret visibility controls, overwrite warnings, and accessibility announcements. - **Bug Fixes** - Improved interstitial animations to respect reduced-motion preferences. - Preserved return destinations and related parameters during sign-in flows. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com> |
||
|
|
6738dded80 |
feat(studio): add Health Advisor page (#49663)
## 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? Feature ## Summary - Add a Health Advisor page at `/project/[ref]/advisors/health` - Put Health Advisor first in the Advisors left nav (above Security), platform-only - Register `V` then `H` and a command-menu entry Stacked on #49662. Top of the stack. ## To test 1. Open any project in Studio. 2. Click **Advisors** in the main nav (or go to `/project/<ref>/advisors/security`). 3. In the left nav, confirm the order is **Health Advisor**, then Security Advisor, then Performance Advisor, then Query Performance. 4. Click **Health Advisor**. You should land on a page titled “Health Advisor” with Errors / Warnings / Info tabs, same layout as Security Advisor. 5. If the project is healthy, Errors should say no errors were detected. If it is not, the failing checks should list here (database down, connection limit, and so on). 6. Click **Refresh** (or Shift+R) and confirm the list reloads. 7. Click a row and confirm the detail panel opens with a link through to logs, connections, or infrastructure. 8. While still in Advisors, press **V** then **H**. You should jump back to Health Advisor. 9. Open the command menu and search **Health Advisor**. Choosing it should navigate to this page. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Added a Health Advisor page for reviewing project health findings by severity and category. - Added Health Advisor navigation in the advisor menu and a keyboard shortcut (`V`, then `H`) on supported platforms. - Added refresh, filtering, selection, and lint detail navigation for health findings. - **Bug Fixes** - Added validation for linter severity values, safely handling unsupported or missing inputs. - **Documentation** - Updated migration and shortcut documentation to include the Health Advisor. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Claude Opus 5 <noreply@anthropic.com> |
||
|
|
b885b69bff |
feat(studio): restore workers secrets page FE-4280 (#49762)
## Problem Workers Secrets was merged in #49589 into the stacked jordi/workers-detail branch. The parent Workers PR reached master without that child merge, leaving the page absent from staging. ## Fix Cherry-pick the missing Workers Secrets route, menu item, shared-secret copy, and generated route tree onto current master. The page uses the existing workers flag and permission gates. ## How to test - Enable the workers flag for a project with Workers access. - Open Workers, then select Secrets. - Expected result: the shared project secrets page renders at /project/:ref/workers/secrets and is not treated as a worker named secrets. - Add, edit, or delete a secret, then confirm the same value appears under Edge Functions, Secrets. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added a **Secrets** page to the Workers section. * Added navigation to Worker secrets from the Workers menu. * Displayed default secrets and deployment-specific guidance where applicable. * Clarified that platform secrets are shared between Edge Functions and Workers. * Updated deletion warnings to reflect shared secret usage. <!-- end of auto-generated comment: release notes by coderabbit.ai --> |
||
|
|
5fd2023708 |
feat(studio): worker detail page (FE-4189, FE-4197) (#49195)
## What
The worker detail page at `/project/[ref]/workers/[name]`, reading `GET
/v2/projects/{ref}/workers/{name}`. Base: #49194.
## How to test
Only on the **Mockamaster** project in staging — it is the one project
in the alpha allow-list.
1. Staging dashboard → Mockamaster → **Workers** → click
`dashboard-test`
2. Overview: instances read 1 declared / 1 live / 1 ready / 0 stale, no
error alerts
3. Settings: Deno 2, `denoland/deno:latest`, 2 GB · 1 vCPU, private, US
West (locked)
4. **How to call** in the header → the snippets name the real worker URL
No write actions. Delete (FE-4190) is deliberately out.
Closes FE-4189
Closes FE-4197
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **New Features**
* Added worker detail pages with overview, requests, logs, builds, and
settings tabs.
* Added worker metadata, runtime details, invocation examples, and local
development commands.
* Added worker log streams with refresh, row selection, loading, empty,
and error states.
* Added worker-specific log formatting and clearer instance status
information.
* **Documentation**
* Updated migration tracking to mark the worker route as complete.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
|
||
|
|
e10f7cc808 |
feat: Add a config drift page in Studio (#48906)
## New Features - Initial work for showing configuration drift in Studio - This only works for Github-connected projects and it'll show a banner if the project state differs from the git-tracked `config.toml` - Currently behind a feature-flag `ConfigDrift`, enabled on local and staging. - There might be drift shown without changing any setting, this is work-in-progress. <img width="1217" height="1195" alt="Screenshot 2026-08-19 at 23 12 10" src="https://github.com/user-attachments/assets/fb0b18d8-1a93-4595-85cc-e8b8a3462847" /> ## How to test 1. Connect a project to a Github repo 2. Resync the branch on `/dashboard/project/_/branches`. This will trigger deployment of the `config.toml` on your project 3. Change some settings (I recommend `dashboard/project/_/auth/providers` 4. A banner should appear on all project pages with a link ## Tests - Added coverage for configuration conversion, normalization, matching, drift detection, and unmanaged settings. <!-- end of auto-generated comment: release notes by coderabbit.ai --> |
||
|
|
1d47a3190b |
Debounce notebook search (#49368)
## Context Sets up debouncing for notebooks search in the explorer so that we're not hammering the API when searching <img width="281" height="178" alt="image" src="https://github.com/user-attachments/assets/1fa2d633-7f7f-4891-87cc-aa90a5062bb7" /> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Bug Fixes** * Improved notebook search responsiveness by delaying searches until 500 ms after typing stops. * Empty searches now update immediately. <!-- end of auto-generated comment: release notes by coderabbit.ai --> |
||
|
|
7fd7ace118 |
feat(studio): add Infrastructure replica detail route and redirects (#49045)
## What kind of change does this PR introduce? Feature. Stack 3 of 5 for [PIPE-1007](https://linear.app/supabase/issue/PIPE-1007/move-read-replicas-out-of-replication-into-infrastructure). ## What is the current behavior? Replica detail lives at `/database/replication/replica/:id`. ## What is the new behavior? Detail moves to `/settings/infrastructure/replica/:id`. Old URLs redirect. List and diagram View/Manage replica links follow. ## Additional context Stacked on [#49044](https://github.com/supabase/supabase/pull/49044). Please review, but do not merge. Merge 2→5 in succession once they are all reviewed, so users never sit on a split create/list vs detail path. Replication still lists and creates replicas until [#49046](https://github.com/supabase/supabase/pull/49046). ## To test `infrastructure:read_replicas` is an enabled-feature, on by default. There is no Feature Preview or ConfigCat switch. You should already see the Infrastructure Read replicas section. If you do not, your profile lists `infrastructure:read_replicas` in `disabled_features`. From [Infrastructure](https://studio-staging-git-danny-pipe-1007-03-detail-redirects-supabase.vercel.app/dashboard/project/_/settings/infrastructure), open View replica on a row. Confirm you land on `/settings/infrastructure/replica/:id`. If you have an old bookmark, `/database/replication/replica/:id` should redirect there. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added read replica management to Infrastructure settings, including replica creation, status monitoring, details, restart, and removal actions. * Added eligibility guidance and estimated pricing details during replica setup. * Added support for topology and replica information within infrastructure configuration. * **Improvements** * Legacy database replication links now permanently redirect to the corresponding Infrastructure pages. * Added clearer empty, loading, error, and transition states for read replica management. * **Tests** * Expanded coverage for replica navigation, redirects, eligibility warnings, and empty states. <!-- end of auto-generated comment: release notes by coderabbit.ai --> |
||
|
|
6c6ac567b1 |
feat(studio): workers list behind the workers flag (FE-4188) (#49193)
## What
The Workers list page at `/project/[ref]/workers`, behind
`useFlag('workers')`. Reads `GET /v2/projects/{ref}/workers`.
- Sidebar and command-menu entries, both hidden when the flag is off
- Name search, state and access filters, pagination
- Read-only
Gating, in order: flag off redirects to the project home; a 404 from the
API means the project is outside the alpha allow-list ("not enabled for
this project"); a 403 means the caller lacks the permission
(`NoPermission`); anything else is an `AlertError`.
`parseWorker` in `data/workers/workers.utils.ts` is the only place the
API shape becomes the view model. It validates with zod, so a drifted
response fails the query instead of half-rendering a row.
## How to test
Only on the **Mockamaster** project in staging — it is the one project
in the alpha allow-list, and standing a worker up anywhere else is
involved right now.
1. Staging dashboard → Mockamaster → **Compute** in the sidebar
2. Expect the `dashboard-test` worker: state `Active`, runtime Deno,
private, US West, 2 GB · 1 vCPU · 1 inst
3. Open any other project's `/workers` URL → "Compute is not enabled for
this project"
4. Turn the `workers` flag off → the sidebar entry disappears and the
URL redirects to the project home
Closes FE-4188
|
||
|
|
85db94762c |
feat: add routed assistant chat tabs to Explorer (#49031)
<img width="1695" height="1042" alt="image" src="https://github.com/user-attachments/assets/b02e64ff-32ac-4aee-bda5-00b56f3a29e5" /> ## Summary - add routed Explorer chat pages backed by explicit assistant chat IDs - wait for persisted assistant state before creating chats so cold-load creation is not overwritten - register chat tabs and keep tab labels, navigation, close behavior, and missing-chat cleanup in sync - create and branch Explorer chats without changing the assistant sidebar selection - support both Next.js and TanStack Router paths This is PR 2 of 3 and is stacked on #48973. Review and merge #48973 first. The Explorer discovery, toolbar, and cross-surface entry points follow in #49032. This PR focuses purely on setting up chat tab types, routes and assistant conversation. ## To Test - Create a new assistant chat via the assistant sidebar, send a message etc - Copy the chat id - Visit /explorer/chat/[id] - Verify chat shows up, you can send more messages, chat is synced across tab and sidebar - Close the tab ## Test plan - `mise exec node@22 -- pnpm --dir apps/studio exec tsc --noEmit` - focused Vitest suite: 4 files / 30 tests covering assistant hydration, chat creation, routed chat rendering, and tab lifecycle - ESLint on changed TypeScript files - Prettier check on changed source files <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added Explorer chat pages with support for opening, selecting, and branching chats. * Added chat tabs, stable navigation, chat icons, and fallback behavior when tabs are closed. * Added chat creation that waits for assistant state to finish loading. * **Bug Fixes** * Removed tabs for deleted or unavailable chats. * Improved editor tab navigation and history clearing behavior. * **Tests** * Added coverage for chat routing, tab management, chat creation, and assistant-state loading. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Claude Opus 5 <noreply@anthropic.com> |
||
|
|
75d16f360f |
feat(studio): add Explorer query tabs (#49038)
<img width="1693" height="1037" alt="image" src="https://github.com/user-attachments/assets/51fdf618-f06e-45ca-bf30-e1307dfbb372" /> ## Stack Depends on #49041. Followed by #49028. ## Summary - add a dedicated ad-hoc query tab type and route under Explorer - connect query tabs to the shared `QueryEditor` through a `QueryTab` lifecycle adapter - add local query draft/result state and restore query tabs from their routes - confirm before closing populated local-only drafts and clean up their state on close ## To test 1. Open Explorer, select **Run SQL**, enter `select 1`, and run the query. 2. Rename the query, reload the page, then close the tab and confirm the discard prompt appears. ## Why Explorer needs a lightweight place to run SQL without creating a snippet. This layer adds the query-tab lifecycle on top of the shared editor foundation. ## Impact Queries in this layer run against the selected project's primary database. Drafts are local to the browser and are discarded when their tabs are closed. ## Validation - fresh non-incremental Studio TypeScript check - 22 focused tests across query draft state, tab state, and notebook tab registration <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added support for creating, opening, editing, and running SQL queries in Explorer. * Added project-scoped persistence for query drafts and results. * Added dedicated query routes, query icons, and query tabs. * Added unsaved-changes warnings when closing query tabs. * Added a pinned Explorer Home tab and “New query” option. * Improved notebook tab registration and editor tab organization. * **Bug Fixes** * Improved tab navigation, closing behavior, and layout. * **Tests** * Added coverage for query persistence, cleanup, restoration, and tab navigation. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Joshen Lim <joshenlimek@gmail.com> |
||
|
|
3a383c87c7 |
Initialize notebooks store (#48801)
## Context More groundwork for the Explorer - this one's focused on initializing the valtio store for managing notebooks Store architecture will follow closely with the existing sql-editor-store No data persistence yet, but can test creating a new notebook <img width="195" height="143" alt="image" src="https://github.com/user-attachments/assets/8656fb5b-3a8e-4f71-b2ce-d2f34ca9b552" /> Which should open a placeholder page <img width="1387" height="527" alt="image" src="https://github.com/user-attachments/assets/4a81b1ae-a740-40e6-9d33-29fa4f83b541" /> Closing the notebook brings you back to the explorer home page <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added support for creating and opening project notebooks from the Explorer. * Added notebook tabs alongside existing entity and SQL tabs. * Added notebook management, including loading, renaming, removing, editing cells, and tracking unsaved changes. * Added support for SQL, logs, and Markdown notebook cells. * Added dedicated notebook routes and an initial notebook editor view. * Added notebook icons throughout the Explorer interface. * **Documentation** * Documented session-scoped notebook state for query results and row limits. <!-- end of auto-generated comment: release notes by coderabbit.ai --> |
||
|
|
cddb430310 |
feat(studio): scoped pat root branch (#48384)
## Description This is the Scoped PAT stacked PRs root branch ## How to test ### With the `scopedPAT` enabled (default on staging) Go to https://studio-staging-git-scopedpat-merge-token-lists-supabase.vercel.app/dashboard/account/tokens. - You shouldn't see two tabs anymore - If you had classic tokens, they should have the _Legacy_ badge - You can create scoped tokens - You have a way to copy newly created tokens before closing the form side panel ### With the `scopedPAT` disabled (use the devtool to override) - You shouldn't see two tabs anymore - If you had classic tokens, they should **not** have the _Legacy_ badge - You can create classic tokens - You have a way to copy newly created tokens above the list upon form submission <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Show classic and scoped access tokens together in one list, with classic tokens labeled “Legacy” when the scoped experience is enabled. * Add scoped access token creation with a two-step configure → review → success flow (when enabled). * Add a dismissible migration notice about scoped tokens with a link to API docs. * Show “View permissions” only for scoped tokens. * **Bug Fixes** * Token deletion now supports both classic and scoped tokens with the correct confirmation and success handling. * The scoped tokens page now redirects to the unified access tokens page. * **Accessibility** * Improved accessibility by adding a label to the token “more options” action. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Ali Waseem <waseema393@gmail.com> Co-authored-by: kemal.earth <606977+kemaldotearth@users.noreply.github.com> |
||
|
|
a7671019a8 |
Scaffold the explorer layout (#48740)
## Context Resolves FE-4074 Just adds scaffolding for the explorer UI - no data fetching yet. Initializes the page + side nav, based off Saxon's POC in `poc/explorer-prototype` <img width="1389" height="500" alt="image" src="https://github.com/user-attachments/assets/8f293992-97d9-403e-91d6-2e104cd20eb5" /> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit ## New Features - Added a project Explorer page accessible from `/project/:ref/explorer`. - Added navigation for browsing notebooks and chats. - Added search fields, back navigation, animated transitions, and empty states for Explorer sections. - Added a conditional Explorer link to the SQL Editor menu when enabled. ## Documentation - Marked the Explorer route migration as complete in the migration checklist. <!-- end of auto-generated comment: release notes by coderabbit.ai --> |
||
|
|
ad203ae277 |
Merge compute and disk into Infrastructure (#48370)
## Summary This is the final step in merging compute and disk with infrastructure to become a single place to manage everything. This moves everything we've done in compute and disk over to infrastructure along with redirects. - Makes Infrastructure canonical for the completed compute and disk configuration and usage charts. - Moves Service Versions to General Project Settings. - Removes the legacy Infrastructure activity implementation and constants. - Updates settings navigation, shortcuts, banners, billing links, warning CTAs, usage pages, support suggestions, and other internal entry points. - Adds the permanent `/settings/compute-and-disk` redirect, removes its Next and TanStack routes, regenerates the route tree, and updates the migration checklist. - Preserves query parameters and legacy metric anchors, including `#cpu`. ## Stack 1. #48368 2. #48369 3. #48370 (this PR) ## How to test 1. Check out `chore/infra-compute-3-cutover`. 2. Test the Next implementation with `pnpm dev:studio`, then stop it and test TanStack with `STUDIO_FRAMEWORK=tanstack pnpm dev:studio`. 3. In each implementation, open `/project/<ref>/settings/infrastructure`. Confirm the page contains the usage charts and the Scaling, Compute, Disk, and Advanced configuration sections. 4. Open `/project/<ref>/settings/general`. Confirm Service Versions appears there with its existing name, content, and styling, and no longer appears on Infrastructure. 5. Open `/project/<ref>/settings/compute-and-disk?upgrade=micro#disk`. Confirm it permanently redirects to `/project/<ref>/settings/infrastructure?upgrade=micro#disk`, preserving the query string and hash. 6. Confirm the settings menu exposes Infrastructure and no longer exposes Compute and Disk. Repeat with platform and self-hosted settings. 7. Follow representative entry points from billing usage, resource warning CTAs, upgrade banners, shortcuts, and support suggestions. Confirm they land on Infrastructure and preserve any query parameters or metric anchors such as `#cpu`. 8. Smoke-test compute and disk updates from Infrastructure, including validation, the sticky review footer, and warning/critical chart states. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Consolidated compute and disk management under the **Infrastructure** project settings page. * Added a **Service versions** section to **General** project settings. * **Bug Fixes** * Updated links and upgrade CTAs across the product to route to the correct **Infrastructure** or **Service versions** destinations. * Added permanent redirects from legacy **Compute and Disk** to **Infrastructure**, preserving query/hash. * Improved resource warning upgrade routing for compute scenarios. * **Tests** * Expanded automated coverage for **Infrastructure**, **Service versions**, redirects, and warning-link routing. * **Chores** * Updated ESLint rule baseline configuration for the studio app. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> |
||
|
|
c7803b8b9b |
Chore/add sessions database connections (#48094)
## Context Initial work for Top for Postgres - adds a "Sessions" section under a new Observability segment "Database Connections" NOTE: All the copywriting and naming might change - not sure what's an ideal title for this We'll also be iteratively building on top of this UI, adding more actionable signals instead of just information Changes are featured flagged, off for public - This would essentially replace the "View ongoing queries" in the SQL Editor by providing a dedicated UI - It checks against `pg_stat_activity` as per the ongoing queries UI - We'll also subsequently deprecate the "Ongoing queries" UI in the SQL editor - Defaults into a "live mode" where the data is refreshed every 3 seconds via long-polling <img width="983" height="474" alt="image" src="https://github.com/user-attachments/assets/16402fe4-0b53-4f9e-9342-cdda26e3778a" /> - Supports filtering by state <img width="374" height="282" alt="image" src="https://github.com/user-attachments/assets/562f8fbe-2dc6-48e7-8ec0-de7ffb8348d1" /> - Users can also terminate queries through here <img width="247" height="164" alt="image" src="https://github.com/user-attachments/assets/23a639dc-8f96-473a-a823-605b0bab02ee" /> <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit # Release Notes * **New Features** * Added an Observability **Database Connections** page with a live **Sessions** activity table (state/roles filtering, blocked-by details, session duration, and per-session termination with confirmation). * Included a **Live/Pause** toggle to control automatic refresh (~3 seconds). * **Enhancements** * Improved Reports selection filtering: supports optional option quantities, better popover styling, sorted apply behavior, and shows quantity inline. * Query performance duration formatting now supports configurable decimal precision. * Tooltips can now render richer content (string or React node). <!-- end of auto-generated comment: release notes by coderabbit.ai --> |
||
|
|
4129c8954d |
feat(studio): TanStack project routes — auth/logs/settings/functions (stack 5.2/6, from #46424) (#47118)
**Stack 5.2/6** of the TanStack Start migration (#46424) — second half of the project routes (S5 was split for CodeRabbit's 150-file cap). Stacked on **#47117** (5.1). > [!NOTE] > Same shape as 5.1 — thin route wrappers over the existing pages-router components. With this PR every route is present, so `routeTree.gen.ts` is now **byte-identical to the migration branch**. ## What's in this PR - **Remaining project routes:** auth, logs, settings, observability, functions, advisors, project-level integrations. - **Supporting edits:** hoist `EdgeFunctionsIndexPageWrapper` out of `getLayout`, `functions/secrets`, and move `DefaultLayout` to the root for the logs page. - `routeTree.gen.ts` regenerated for the full set. ## Verification On top of S1–5.1: `studio` typecheck ✓, lint (0 errors) ✓, **Next build ✓ (181/181 pages)**. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Refactor** * Reorganized internal routing and page structure to improve navigation and maintainability across project settings, logs, functions, authentication, integrations, and observability sections. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com> |
||
|
|
7d3f72ec7d |
feat(studio): TanStack project routes — data surfaces (stack 5.1/6, from #46424) (#47117)
**Stack 5.1/6** of the TanStack Start migration (#46424). The original S5 (174 files) was over CodeRabbit's 150-file review cap, so it's split into 5.1 + 5.2 by product. Stacked on **#47113** (S4). > [!NOTE] > Thin route wrappers rendering the existing pages-router components via compat shims. Next-safe (full Next build run). The TanStack app isn't functional end-to-end until 5.2 + the matrix flip. ## What's in this PR - **Data-cluster project routes:** database, editor, sql, storage, realtime, branches. - **Top-level / onboarding routes:** `authorize`, `join`, `logout`, `redeem`, `verify-email`, `claim-project`, aws-marketplace, Vercel/GitHub integration entrypoints; `_app`/`_auth` layout shells; `/org/_` + `/project/_` catch-alls. - **Supporting edits:** hoist `BranchesPageWrapper` out of `getLayout`, `ConnectStepsSection` `import.meta.glob`, `api/server.js`. - `routeTree.gen.ts` regenerated for the routes present so far. ## Verification On top of S1–S4: `studio` typecheck ✓, lint (0 errors) ✓, **Next build ✓ (181/181 pages)**. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Refactor** * Restructured application routing infrastructure for improved code organization and maintainability. * Extracted and refactored layout wrapper components for enhanced reusability across different sections of the application. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com> |
||
|
|
2f90228f04 |
feat(studio): port API handlers to TanStack server routes (stack 4/6, from #46424) (#47113)
**Stack 4/6** of the TanStack Start migration (#46424). Stacked on **#47112** (S3). > [!NOTE] > Mechanical and homogeneous — every file is the same shape: a `createFileRoute(...)` whose `server.handlers` delegate to the existing `pages/api` handler via `toWebHandler` (the compat shim from S2). The pages-router handlers are unchanged; Next still serves them directly and ignores `routes/`. ## What's in this PR - `routes/api/**` (~104 files): platform (`pg-meta`, auth, storage, integrations, profile, telemetry, organizations, projects…), `ai/*`, `v1/*`, `connect`, `content`/`mcp`, and standalone endpoints (`deployment-mode`, `get-ip-address`, etc.). - `routeTree.gen.ts` — **regenerated** for the routes present so far (root + auth/app + api). ## Review tip The route files are near-identical wrappers, so this is fast to skim. The generated `routeTree.gen.ts` isn't meaningful review surface. ## Verification On top of S1–S3: `studio` typecheck ✓, lint (0 errors) ✓. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Added Model Context Protocol (MCP) API endpoint with configurable feature support and read-only mode * Added function artifact streaming capability for self-hosted functions * **Chores** * Migrated API route infrastructure for improved system architecture <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com> |
||
|
|
3d931aceb7 |
feat(studio): TanStack app shell — root + auth/org routes (stack 3/6, from #46424) (#47112)
**Stack 3/6** of the TanStack Start migration (#46424). Stacked on **#47110** (S2) → review that first; this PR's diff is the app shell. > [!NOTE] > Thin route wrappers that render the existing pages-router page components through the compat shims (S2). Next is untouched — it builds `pages/` and ignores `routes/`. The app doesn't function end-to-end on TanStack until the API + project routes land (S4/S5) and the flag is flipped. ## What's in this PR - `routes/__root.tsx` — root layout + a `beforeLoad` that runs the shared redirect rules; `router.tsx`. - `routes/_auth/*` — sign-in/up, forgot/reset password, SSO/MFA/partner sign-in, CLI login, Stripe-projects login. - `routes/_app/*` — account (me/security/audit/tokens), `org/$slug/*` (general/billing/team/usage/…), support. - `routeTree.gen.ts` — **regenerated** by the tanstackStart vite plugin for exactly the routes in this PR (the migration branch's tree references all ~300 routes, so it can't be copied verbatim here). It's a generated artifact; the meaningful review surface is the route files. ## Verification On top of S1+S2: `studio` typecheck ✓, lint (0 errors) ✓. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **Refactor** * Enhanced internal routing infrastructure to improve application performance and code organization. These behind-the-scenes updates ensure a more stable and maintainable foundation for the platform without affecting existing functionality or user experience. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --------- Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com> Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com> |