The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.
TypeScript aialternativeauthdatabasedenoembeddingsexamplefirebasenextjsoauth2pgvectorpostgispostgrespostgresqlpostgrestrealtimesupabasevectorswebsockets
chore: Add new OAuth scopes for analytics config to studio (#44826)
Alex Halld70ed2ef76a4
diff --git a/apps/studio/components/interfaces/Organization/OAuthApps/AuthorizeRequesterDetails.tsx b/apps/studio/components/interfaces/Organization/OAuthApps/AuthorizeRequesterDetails.tsxindex 9d238b3acdf..dc8aca5c40c 100644--- a/apps/studio/components/interfaces/Organization/OAuthApps/AuthorizeRequesterDetails.tsx+++ b/apps/studio/components/interfaces/Organization/OAuthApps/AuthorizeRequesterDetails.tsx@@ -98,6 +98,11 @@ export const AuthorizeRequesterDetails = ({hasReadScope={scopes.includes(OAuthScope.ANALYTICS_READ)}hasWriteScope={scopes.includes(OAuthScope.ANALYTICS_WRITE)}/>+ <ScopeSection+ description={PERMISSIONS_DESCRIPTIONS.ANALYTICS_CONFIG}+ hasReadScope={scopes.includes(OAuthScope.ANALYTICS_CONFIG_READ)}+ hasWriteScope={scopes.includes(OAuthScope.ANALYTICS_CONFIG_WRITE)}+ /><ScopeSectiondescription={PERMISSIONS_DESCRIPTIONS.AUTH}hasReadScope={scopes.includes(OAuthScope.AUTH_READ)}diff --git a/apps/studio/components/interfaces/Organization/OAuthApps/OAuthApps.constants.ts b/apps/studio/components/interfaces/Organization/OAuthApps/OAuthApps.constants.tsindex 6fdc47c2547..6684d392cf0 100644--- a/apps/studio/components/interfaces/Organization/OAuthApps/OAuthApps.constants.ts+++ b/apps/studio/components/interfaces/Organization/OAuthApps/OAuthApps.constants.ts@@ -1,5 +1,6 @@export const PERMISSIONS_DESCRIPTIONS = {ANALYTICS: 'access to analytics logs.',+ ANALYTICS_CONFIG: 'access to analytics logs configurations.',AUTH: 'access to auth configurations and SSO providers.',DATABASE:'access to Postgres configurations, SQL snippets, SSL enforcement configurations and Typescript schema types.',diff --git a/apps/studio/components/interfaces/Organization/OAuthApps/PublishAppSidePanel/Scopes.tsx b/apps/studio/components/interfaces/Organization/OAuthApps/PublishAppSidePanel/Scopes.tsxindex 7b9108ef2b1..f4a8baea852 100644--- a/apps/studio/components/interfaces/Organization/OAuthApps/PublishAppSidePanel/Scopes.tsx+++ b/apps/studio/components/interfaces/Organization/OAuthApps/PublishAppSidePanel/Scopes.tsx@@ -116,6 +116,14 @@ export const ScopesPanel = ({scopes={scopes}setScopes={setScopes}/>+ <Scope+ title="Analytics Config"+ description={PERMISSIONS_DESCRIPTIONS.ANALYTICS_CONFIG}+ readScopeName={OAuthScope.ANALYTICS_CONFIG_READ}+ writeScopeName={OAuthScope.ANALYTICS_CONFIG_WRITE}+ scopes={scopes}+ setScopes={setScopes}+ /><Scopetitle="Auth"description={PERMISSIONS_DESCRIPTIONS.AUTH}diff --git a/apps/studio/components/interfaces/Organization/ProjectClaim/confirm.tsx b/apps/studio/components/interfaces/Organization/ProjectClaim/confirm.tsxindex 5fd7c7cc526..89e4134fb87 100644--- a/apps/studio/components/interfaces/Organization/ProjectClaim/confirm.tsx+++ b/apps/studio/components/interfaces/Organization/ProjectClaim/confirm.tsx@@ -199,6 +199,11 @@ export const ProjectClaimConfirm = ({hasReadScope={requester.scopes.includes(OAuthScope.ANALYTICS_READ)}hasWriteScope={requester.scopes.includes(OAuthScope.ANALYTICS_WRITE)}/>+ <ScopeSection+ description={PERMISSIONS_DESCRIPTIONS.ANALYTICS_CONFIG}+ hasReadScope={requester.scopes.includes(OAuthScope.ANALYTICS_CONFIG_READ)}+ hasWriteScope={requester.scopes.includes(OAuthScope.ANALYTICS_CONFIG_WRITE)}+ /><ScopeSectiondescription={PERMISSIONS_DESCRIPTIONS.AUTH}hasReadScope={requester.scopes.includes(OAuthScope.AUTH_READ)}diff --git a/apps/studio/package.json b/apps/studio/package.jsonindex ee91bb4f560..1c84df9123d 100644--- a/apps/studio/package.json+++ b/apps/studio/package.json@@ -64,7 +64,7 @@"@supabase/mcp-utils": "^0.4.0","@supabase/pg-meta": "workspace:*","@supabase/realtime-js": "catalog:",- "@supabase/shared-types": "0.1.84",+ "@supabase/shared-types": "0.1.88","@supabase/sql-to-rest": "^0.1.6","@supabase/supabase-js": "catalog:","@tanstack/react-query": "^5.0.0",diff --git a/pnpm-lock.yaml b/pnpm-lock.yamlindex 368c428a5db..ea717e0bfdd 100644--- a/pnpm-lock.yaml+++ b/pnpm-lock.yaml@@ -959,8 +959,8 @@ importers:specifier: 'catalog:'version: 2.103.0'@supabase/shared-types':- specifier: 0.1.84- version: 0.1.84+ specifier: 0.1.88+ version: 0.1.88'@supabase/sql-to-rest':specifier: ^0.1.6version: 0.1.6([email protected])([email protected])@@ -8773,8 +8773,8 @@ packages:resolution: {integrity: sha512-gcPtXzZ6izyyBVf2of7K3dEt8CScPJn8VcSlQq6oWL9QoE1kqfQl0oFrOMHd5qrcADewxI7OxxosLB8W4XqtIQ==}engines: {node: '>=20.0.0'}- '@supabase/[email protected]':- resolution: {integrity: sha512-0bcV8Il0r5zybdY6gIWEmbJ/5VGGw60p9SOZ8tUe3x7iKxW/2H+CmPezyqQHuwYURxF4Gf18zJfENlaDyn+g8w==}+ '@supabase/[email protected]':+ resolution: {integrity: sha512-9LYy+pD6cD2o8ZSxeUeJ1nrHPigeoP1kzhd2+k6MmzrwBHwxwUhWjywQJVjpU6fLNQxdkoNqxPfI7UQgOjG7Lg==}'@supabase/[email protected]':resolution: {integrity: sha512-06KgjeINtc6405XQvfnchBE1azEsU8G2NElfadmvVHKmHa5l2bFzjbtFbpaYgpgTzccHlcDmBaCgedVf2Gyl8Q==}@@ -26414,7 +26414,7 @@ snapshots:- bufferutil- utf-8-validate- '@supabase/[email protected]': {}+ '@supabase/[email protected]': {}dependencies: