## Problem
platform, v1 and v2 have been already completely migrated and introduced
some changes.
Some types have been renamed, some outputs and inputs updated.
## Solution
- Update the API types
- Fix the TS errors
## Update
Taking this over to unblock #50134, which needs the new scoped token
permission ids from the regenerated types.
- Merged `master`.
- Regenerated `api-v2.d.ts` from the production spec. The previous files
came from a local API that exposed a webhook events endpoint production
doesn't have yet. Production has since added standardized 400 error
responses on the v2 organization endpoints. `api-v1.d.ts` and
`platform.d.ts` already matched production.
- Fixed `verify-production-types`. It formatted the regenerated files in
a temp directory outside the repository, so Prettier fell back to its
defaults and the comparison could never match the committed files. It
now passes the repository config explicitly. `pnpm api:verify-types`
passes on this branch.
- Verified locally: `pnpm typecheck`, `pnpm api:verify-types`, Studio
unit tests.
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **Bug Fixes**
* Preserved descriptions when saving, sharing, moving, or unsharing
notebooks, reports, SQL snippets, and saved queries.
* Improved handling of empty or null values across notebook
descriptions, billing usage, pooler settings, and infrastructure fields.
* Improved read-replica connection handling, including read-only
connection strings.
* Updated storage configuration and capability handling to match current
settings.
* **API and Compatibility**
* Updated organization, project, storage, OAuth, billing, and
infrastructure data handling to match current API responses.
* OAuth app creation and updates now require scopes.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: Alaister Young <10985857+alaister@users.noreply.github.com>
Show OAuth server endpoints in oauth server settings page.
Preview: [OAuth Server
settings](https://studio-staging-git-chore-show-oauth-server-endpoints-supabase.vercel.app/dashboard/project/_/auth/oauth-server)
<img width="1138" height="496" alt="Screenshot 2026-01-09 at 12 00 31"
src="https://github.com/user-attachments/assets/eeca7726-0426-4abe-990d-271b702e4f7b"
/>
<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit
* **New Features**
* Added an OAuth endpoints table showing Authorization, Token, JWKS, and
Discovery/OpenID URLs with copy-to-clipboard and a masked preview mode.
* Inline preview of the Authorization URL when an authorization path is
set.
* **Improvements**
* Reorganized OAuth server settings for clearer enable/disable flow,
conditional field visibility, and disable confirmation.
* Dynamic loading of the endpoints table, improved loading skeletons,
layout refinements, and form reset to reflect saved defaults.
<sub>✏️ Tip: You can customize this high-level summary in your review
settings.</sub>
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
---------
Co-authored-by: Ali Waseem <waseema393@gmail.com>
## Context
Main fix is to adjust the new home page + connect dialog (and connect
sheet) to render the project's custom domain if available
<img width="471" height="255" alt="image"
src="https://github.com/user-attachments/assets/3a208b2e-bdeb-43f5-a2e7-3495881dbaaa"
/>
<img width="1065" height="233" alt="image"
src="https://github.com/user-attachments/assets/2a7b8f81-8c0b-4803-bf0a-fc16a2f1e0e1"
/>
## Changes involved
- Created a `useProjectApiUrl` hook that will return the API URL
depending if custom domains is available, otherwise default to default
project API URL
- Refactored all the other places that were manually deriving the
project's endpoint
- Storage Explorer -> copy URL
- Edge Functions
- Integrations -> Data API + API Docs
- Auth Providers -> Callback URL
- Also updated the copy CTA for the addons page
- Instead of just "Change xxx", make it a bit more actionable
- For add ons with binary states (Custom domains, IPv4)
- If not enabled yet, "Enable xxx", otherwise "Toggle xxx"
- For PITR
- If not enabled yet, "Enable PITR", otherwise "Change recovery
duration"
- Also added "Edit custom domain" CTA if enabled
<img width="1144" height="518" alt="image"
src="https://github.com/user-attachments/assets/4f152ea5-0cc7-412c-95e8-ad5bb37c19c3"
/>
## To test
- [ ] Verify that for a project with custom domain set up, all the
affected UI mentioned in the above section look correct
* Remove the query for temp keys. Remove the query for supabase client. Add a function which creates a supabase client with a temp key.
* Add a new query for building the endpoint URL.
* Migrate all oAuth queries and mutations to use the new function for creating a Supabase project client.
* Use the new queries/mutations in the code.
* Use query in refetchInterval for useProjectSettings.
* Replace all uses in StorageExplorer with createProjectSupabaseClient.
* chore(studio): add oauth apps update panel
* chore(studio): add client_type value to oauth app form
* chore(studio): add logo_uri upload field to oauth apps
* chore(studio): don't show oauth app credentials when successfully editing
* chore(studio): apply correct filters to oauth apps
* chore(studio): show client_secret only on confidential apps
* chore(studio): hide regenerate client secret on public oauth apps
* chore(studio): add docs link on auth server page
* Add custom types for queries, mutations and infinite queries.
* Migrate all queries to use the new type.
* Migrate all infinite queries to useCustomInfiniteQueryOptions.
* Migrate all mutations to use useCustomMutationOptions.
* Add type to all imports in `types` folder.
* oAuth clients index layout
* oAuth apps crud
* is public
* add user count and client secret generation and management
* scaffold oauth server settings
* improve oauth server enablement / disablement
* show cover when oAuth server is disabled
* fix update panel update button
* add site url and authorization path settings values
* move oauth server to it's own nav item
* remove unneeded oauth server settings
* let the user disactivate oauth server even after creating oauth apps
* better delete button
* cleanup
* fix typecheck
* test endpoints
* add EnableOAuth21 feature flag
* update OAUTH_SERVER_ auth config api
* load OAUTH_SERVER_ENABLED in oauth list
* Update the api.d.ts. Remove the custom versions of supa libs.
* Add query for getTemporaryAPIKey.
* Add a hook for initializing a supabase client.
* Add hooks for oAuth Server apps.
* Regenerate pnpm-lock.yaml.
* Revert updates to the platform.d.ts. Not needed for this PR.
* Migrate all code to use the new hooks.
* Try to integrate the mutations and fix some of the sheet and dialogs.
* improve default and saving states
* fix oauth app form validation
* unify components into CreateOrUpdateOAuthAppModal
* create or update oauth app
* Update the OAuth Server page.
* Remove extra files.
* Minor various fixes.
* More fixes to the creation of oauth apps.
* Bump the libs to fix a DELETE oauth app error.
* Clean up the scope feature.
* Move the feature flag in the auth layout.
* Bunch of smaller fixes.
* Regenerate pnpm-lock.
* Revert SidePanel and CardDescription changes.
* Add confirm dialog for regenerating secret.
---------
Co-authored-by: Ivan Vasilov <vasilov.ivan@gmail.com>