From 1cc0682c47a6984d71852f335a85c346a746bafb Mon Sep 17 00:00:00 2001
From: "kemal.earth" <606977+kemaldotearth@users.noreply.github.com>
Date: Tue, 11 Aug 2026 09:48:02 +0100
Subject: [PATCH] chore(studio): remove admonition now that mcp supports scoped
pat (#48931)
## 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?
This removes the pre-cautionary admonition we had before the MCP support
for scoped access tokens landed. We can now remove this admonition (and
anything related) as it's been merged.
| Before | After |
|--------|--------|
| |
|
## Summary by CodeRabbit
* **Changes**
* Removed the MCP unsupported warning from scoped access-token creation
and viewing screens.
* Removed the option to switch from scoped-token creation to the legacy
account-wide token flow.
* MCP tools now display directly when available.
---
.../Scoped/Form/NewScopedTokenForm.tsx | 4 --
.../Scoped/Form/NewScopedTokenFormReview.tsx | 5 ---
.../Scoped/McpUnsupportedWarning.tsx | 40 -------------------
.../Scoped/NewScopedTokenSheet.test.tsx | 21 ----------
.../AccessTokens/Scoped/ViewTokenSheet.tsx | 2 -
5 files changed, 72 deletions(-)
delete mode 100644 apps/studio/components/interfaces/Account/AccessTokens/Scoped/McpUnsupportedWarning.tsx
diff --git a/apps/studio/components/interfaces/Account/AccessTokens/Scoped/Form/NewScopedTokenForm.tsx b/apps/studio/components/interfaces/Account/AccessTokens/Scoped/Form/NewScopedTokenForm.tsx
index 4c1845d97a3..25f572efe1b 100644
--- a/apps/studio/components/interfaces/Account/AccessTokens/Scoped/Form/NewScopedTokenForm.tsx
+++ b/apps/studio/components/interfaces/Account/AccessTokens/Scoped/Form/NewScopedTokenForm.tsx
@@ -178,10 +178,6 @@ export const NewScopedTokenForm = ({
values={formValues}
access={access}
permissionScopeMap={permissionScopeMap}
- onSelectLegacyToken={() => {
- handleSelectLegacyMode()
- setStep('form')
- }}
/>
)}
diff --git a/apps/studio/components/interfaces/Account/AccessTokens/Scoped/Form/NewScopedTokenFormReview.tsx b/apps/studio/components/interfaces/Account/AccessTokens/Scoped/Form/NewScopedTokenFormReview.tsx
index d0b2a2b9882..3f71e882fb7 100644
--- a/apps/studio/components/interfaces/Account/AccessTokens/Scoped/Form/NewScopedTokenFormReview.tsx
+++ b/apps/studio/components/interfaces/Account/AccessTokens/Scoped/Form/NewScopedTokenFormReview.tsx
@@ -15,7 +15,6 @@ import {
import { useCapabilitySummary } from '../../hooks/useCapabilitySummary'
import { useOrgAndProjectData } from '../../hooks/useOrgAndProjectData'
import { failingResourceLine } from '../ExceedsRoleBadge'
-import { McpUnsupportedWarning } from '../McpUnsupportedWarning'
import { CapabilityCategoryList, ResourceSummaryItem, RiskLevelSummary } from '../TokenSummaryRows'
import { EXPIRY_OPTIONS, type TokenFormValues } from './NewScopedTokenForm.utils'
import { PermissionScopeMap } from '@/data/scoped-access-tokens/permission-scope-map-query'
@@ -24,15 +23,12 @@ interface ReviewStepProps {
values: TokenFormValues
access: TokenAccessEvaluation
permissionScopeMap: PermissionScopeMap | undefined
- /** Switches the form back to step one in legacy (account-wide) token mode. */
- onSelectLegacyToken: () => void
}
export const NewScopedTokenFormReview = ({
values,
access,
permissionScopeMap,
- onSelectLegacyToken,
}: ReviewStepProps) => {
const { organizations, projects } = useOrgAndProjectData()
const selection = values.permissions
@@ -211,7 +207,6 @@ export const NewScopedTokenFormReview = ({
No MCP tools are enabled by the selected capabilities.
diff --git a/apps/studio/components/interfaces/Account/AccessTokens/Scoped/McpUnsupportedWarning.tsx b/apps/studio/components/interfaces/Account/AccessTokens/Scoped/McpUnsupportedWarning.tsx
deleted file mode 100644
index 0e3b7ee6332..00000000000
--- a/apps/studio/components/interfaces/Account/AccessTokens/Scoped/McpUnsupportedWarning.tsx
+++ /dev/null
@@ -1,40 +0,0 @@
-import { Admonition } from 'ui-patterns/Admonition'
-
-import { InlineLinkClassName } from '@/components/ui/InlineLink'
-
-// Temporary warning: scoped tokens can't be used with the Supabase MCP server yet.
-// Tracked by Linear DESIGN-479, blocked on the AI-1025 FGA guard migration.
-// Remove once that lands: delete this module, then the two call sites (NewScopedTokenFormReview, ViewTokenSheet).
-
-export const MCP_UNSUPPORTED_WARNING_TITLE =
- "Scoped tokens don't currently work with the Supabase MCP server"
-export const MCP_UNSUPPORTED_WARNING_DESCRIPTION = 'Support for scoped tokens is coming soon.'
-
-interface McpUnsupportedWarningProps {
- onSelectLegacyToken?: () => void
-}
-
-export const McpUnsupportedWarning = ({ onSelectLegacyToken }: McpUnsupportedWarningProps) => (
-
No MCP tools are enabled by the selected capabilities.