Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

feat(studio): add app id and installation id to private apps metadata (#44126)

kemal.earth048dd3286169
diff --git a/apps/studio/components/interfaces/LogDrains/LogDrainDestinationSheetForm.tsx b/apps/studio/components/interfaces/LogDrains/LogDrainDestinationSheetForm.tsx
index bf04fae4380..acc2d839c81 100644
--- a/apps/studio/components/interfaces/LogDrains/LogDrainDestinationSheetForm.tsx
+++ b/apps/studio/components/interfaces/LogDrains/LogDrainDestinationSheetForm.tsx
@@ -135,6 +135,7 @@ const formUnion = z.discriminatedUnion('type', [
gzip: z.boolean().optional().default(true),
headers: z.record(z.string(), z.string()).optional(),
}),
+ z.object({ type: z.literal('syslog') }),
])
const formSchema = z
@@ -316,9 +317,7 @@ export function LogDrainDestinationSheetForm({
}
form.handleSubmit(onSubmit)(e)
- track('log_drain_save_button_clicked', {
- destination: form.getValues('type'),
- })
+ track('log_drain_save_button_clicked', { destination: form.getValues('type') })
}}
>
<div className="space-y-8 px-content">
diff --git a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/Apps.constants.ts b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/Apps.constants.ts
index 5dbcf8f52fa..100dd4f2f02 100644
--- a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/Apps.constants.ts
+++ b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/Apps.constants.ts
@@ -1,403 +1,15 @@
+import { permissions } from '@supabase/shared-types'
+
export interface Permission {
id: string
label: string
description: string
- group: 'organization' | 'project'
}
-export const PERMISSIONS: Permission[] = [
- // Organization permissions
- {
- id: 'organizations_read',
- label: 'organizations_read',
- description: 'View organization details',
- group: 'organization',
- },
- {
- id: 'organizations_create',
- label: 'organizations_create',
- description: 'Create organizations',
- group: 'organization',
- },
- {
- id: 'organization_admin_read',
- label: 'organization_admin_read',
- description: 'View organization admin settings',
- group: 'organization',
- },
- {
- id: 'organization_admin_write',
- label: 'organization_admin_write',
- description: 'Manage organization admin settings',
- group: 'organization',
- },
- {
- id: 'members_read',
- label: 'members_read',
- description: 'View organization members',
- group: 'organization',
- },
- {
- id: 'members_write',
- label: 'members_write',
- description: 'Manage organization members',
- group: 'organization',
- },
- {
- id: 'organization_projects_read',
- label: 'organization_projects_read',
- description: 'View organization projects',
- group: 'organization',
- },
- {
- id: 'organization_projects_create',
- label: 'organization_projects_create',
- description: 'Create projects in organization',
- group: 'organization',
- },
- {
- id: 'snippets_read',
- label: 'snippets_read',
- description: 'View SQL snippets',
- group: 'organization',
- },
- {
- id: 'analytics_usage_read',
- label: 'analytics_usage_read',
- description: 'View usage analytics',
- group: 'organization',
- },
- // Project permissions
- {
- id: 'projects_read',
- label: 'projects_read',
- description: 'View project details',
- group: 'project',
- },
- {
- id: 'project_admin_read',
- label: 'project_admin_read',
- description: 'View project admin settings',
- group: 'project',
- },
- {
- id: 'project_admin_write',
- label: 'project_admin_write',
- description: 'Manage project admin settings',
- group: 'project',
- },
- {
- id: 'action_runs_read',
- label: 'action_runs_read',
- description: 'View action runs',
- group: 'project',
- },
- {
- id: 'action_runs_write',
- label: 'action_runs_write',
- description: 'Manage action runs',
- group: 'project',
- },
- {
- id: 'advisors_read',
- label: 'advisors_read',
- description: 'View advisor recommendations',
- group: 'project',
- },
- {
- id: 'analytics_logs_read',
- label: 'analytics_logs_read',
- description: 'View analytics logs',
- group: 'project',
- },
- {
- id: 'api_gateway_keys_read',
- label: 'api_gateway_keys_read',
- description: 'View API gateway keys',
- group: 'project',
- },
- {
- id: 'api_gateway_keys_write',
- label: 'api_gateway_keys_write',
- description: 'Manage API gateway keys',
- group: 'project',
- },
- {
- id: 'auth_config_read',
- label: 'auth_config_read',
- description: 'View auth configuration',
- group: 'project',
- },
- {
- id: 'auth_config_write',
- label: 'auth_config_write',
- description: 'Manage auth settings',
- group: 'project',
- },
- {
- id: 'auth_signing_keys_read',
- label: 'auth_signing_keys_read',
- description: 'View auth signing keys',
- group: 'project',
- },
- {
- id: 'auth_signing_keys_write',
- label: 'auth_signing_keys_write',
- description: 'Manage auth signing keys',
- group: 'project',
- },
- { id: 'backups_read', label: 'backups_read', description: 'View backups', group: 'project' },
- { id: 'backups_write', label: 'backups_write', description: 'Manage backups', group: 'project' },
- {
- id: 'branching_development_read',
- label: 'branching_development_read',
- description: 'View development branches',
- group: 'project',
- },
- {
- id: 'branching_development_create',
- label: 'branching_development_create',
- description: 'Create development branches',
- group: 'project',
- },
- {
- id: 'branching_development_write',
- label: 'branching_development_write',
- description: 'Manage development branches',
- group: 'project',
- },
- {
- id: 'branching_development_delete',
- label: 'branching_development_delete',
- description: 'Delete development branches',
- group: 'project',
- },
- {
- id: 'branching_production_read',
- label: 'branching_production_read',
- description: 'View production branches',
- group: 'project',
- },
- {
- id: 'branching_production_create',
- label: 'branching_production_create',
- description: 'Create production branches',
- group: 'project',
- },
- {
- id: 'branching_production_write',
- label: 'branching_production_write',
- description: 'Manage production branches',
- group: 'project',
- },
- {
- id: 'branching_production_delete',
- label: 'branching_production_delete',
- description: 'Delete production branches',
- group: 'project',
- },
- {
- id: 'custom_domain_read',
- label: 'custom_domain_read',
- description: 'View custom domain settings',
- group: 'project',
- },
- {
- id: 'custom_domain_write',
- label: 'custom_domain_write',
- description: 'Manage custom domain',
- group: 'project',
- },
- {
- id: 'data_api_config_read',
- label: 'data_api_config_read',
- description: 'View Data API configuration',
- group: 'project',
- },
- {
- id: 'data_api_config_write',
- label: 'data_api_config_write',
- description: 'Manage Data API settings',
- group: 'project',
- },
- {
- id: 'database_read',
- label: 'database_read',
- description: 'Read database data',
- group: 'project',
- },
- {
- id: 'database_write',
- label: 'database_write',
- description: 'Write database data',
- group: 'project',
- },
- {
- id: 'database_config_read',
- label: 'database_config_read',
- description: 'View database configuration',
- group: 'project',
- },
- {
- id: 'database_config_write',
- label: 'database_config_write',
- description: 'Manage database settings',
- group: 'project',
- },
- {
- id: 'database_migrations_read',
- label: 'database_migrations_read',
- description: 'View database migrations',
- group: 'project',
- },
- {
- id: 'database_migrations_write',
- label: 'database_migrations_write',
- description: 'Run database migrations',
- group: 'project',
- },
- {
- id: 'database_pooling_config_read',
- label: 'database_pooling_config_read',
- description: 'View connection pooling settings',
- group: 'project',
- },
- {
- id: 'database_pooling_config_write',
- label: 'database_pooling_config_write',
- description: 'Manage connection pooling',
- group: 'project',
- },
- {
- id: 'database_ssl_config_read',
- label: 'database_ssl_config_read',
- description: 'View SSL configuration',
- group: 'project',
- },
- {
- id: 'database_ssl_config_write',
- label: 'database_ssl_config_write',
- description: 'Manage SSL settings',
- group: 'project',
- },
- {
- id: 'database_webhooks_config_read',
- label: 'database_webhooks_config_read',
- description: 'View database webhooks',
- group: 'project',
- },
- {
- id: 'database_webhooks_config_write',
- label: 'database_webhooks_config_write',
- description: 'Manage database webhooks',
- group: 'project',
- },
- {
- id: 'edge_functions_read',
- label: 'edge_functions_read',
- description: 'View Edge Functions',
- group: 'project',
- },
- {
- id: 'edge_functions_write',
- label: 'edge_functions_write',
- description: 'Deploy and manage Edge Functions',
- group: 'project',
- },
- {
- id: 'edge_functions_secrets_read',
- label: 'edge_functions_secrets_read',
- description: 'View Edge Function secrets',
- group: 'project',
- },
- {
- id: 'edge_functions_secrets_write',
- label: 'edge_functions_secrets_write',
- description: 'Manage Edge Function secrets',
- group: 'project',
- },
- {
- id: 'infra_add_ons_read',
- label: 'infra_add_ons_read',
- description: 'View infrastructure add-ons',
- group: 'project',
- },
- {
- id: 'infra_add_ons_write',
- label: 'infra_add_ons_write',
- description: 'Manage infrastructure add-ons',
- group: 'project',
- },
- {
- id: 'infra_disk_config_read',
- label: 'infra_disk_config_read',
- description: 'View disk configuration',
- group: 'project',
- },
- {
- id: 'infra_disk_config_write',
- label: 'infra_disk_config_write',
- description: 'Manage disk settings',
- group: 'project',
- },
- {
- id: 'infra_read_replicas_read',
- label: 'infra_read_replicas_read',
- description: 'View read replicas',
- group: 'project',
- },
- {
- id: 'infra_read_replicas_write',
- label: 'infra_read_replicas_write',
- description: 'Manage read replicas',
- group: 'project',
- },
- {
- id: 'project_snippets_read',
- label: 'project_snippets_read',
- description: 'View project SQL snippets',
- group: 'project',
- },
- {
- id: 'project_snippets_write',
- label: 'project_snippets_write',
- description: 'Manage project SQL snippets',
- group: 'project',
- },
- {
- id: 'storage_read',
- label: 'storage_read',
- description: 'Read storage objects',
- group: 'project',
- },
- {
- id: 'storage_write',
- label: 'storage_write',
- description: 'Write storage objects',
- group: 'project',
- },
- {
- id: 'storage_config_read',
- label: 'storage_config_read',
- description: 'View storage configuration',
- group: 'project',
- },
- {
- id: 'storage_config_write',
- label: 'storage_config_write',
- description: 'Manage storage settings',
- group: 'project',
- },
- {
- id: 'vanity_subdomain_read',
- label: 'vanity_subdomain_read',
- description: 'View vanity subdomain settings',
- group: 'project',
- },
- {
- id: 'vanity_subdomain_write',
- label: 'vanity_subdomain_write',
- description: 'Manage vanity subdomain',
- group: 'project',
- },
-]
+export const PERMISSIONS: Permission[] = Object.values(permissions.FgaPermissions.PROJECT).map(
+ (perm) => ({
+ id: perm.id,
+ label: perm.id,
+ description: perm.title,
+ })
+)
diff --git a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/CreateAppSheet/CreateAppSheet.tsx b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/CreateAppSheet/CreateAppSheet.tsx
index ebb0cefa032..fa60b82be59 100644
--- a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/CreateAppSheet/CreateAppSheet.tsx
+++ b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/CreateAppSheet/CreateAppSheet.tsx
@@ -212,7 +212,7 @@ export function CreateAppSheet({ visible, onClose, onCreated }: CreateAppSheetPr
<CommandEmpty_Shadcn_>No permissions found.</CommandEmpty_Shadcn_>
<CommandGroup_Shadcn_ className="[&>div]:text-left">
<div className="max-h-[210px] overflow-y-auto">
- {PERMISSIONS.filter((p) => p.group === 'project').map((perm) => (
+ {PERMISSIONS.map((perm) => (
<CommandItem_Shadcn_
key={perm.id}
value={`${perm.id} ${perm.label}`}
diff --git a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheet.tsx b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheet.tsx
index 6eed924a032..65c6a83a2f5 100644
--- a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheet.tsx
+++ b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheet.tsx
@@ -21,7 +21,8 @@ interface ViewAppSheetProps {
export function ViewAppSheet({ app, visible, onClose, onDeleted }: ViewAppSheetProps) {
const { slug, installations, removeInstallationsByAppId } = usePrivateApps()
- const isInstalled = installations.some((i) => i.app_id === app?.id)
+ const installation = installations.find((i) => i.app_id === app?.id)
+ const isInstalled = installation !== undefined
const [showDeleteModal, setShowDeleteModal] = useState(false)
const { data: detail, isLoading: isLoadingDetail } = usePlatformAppQuery(
@@ -73,7 +74,7 @@ export function ViewAppSheet({ app, visible, onClose, onDeleted }: ViewAppSheetP
<ScrollArea className="flex-1 max-h-[calc(100vh-60px)]">
{app && (
<div className="flex flex-col gap-0">
- <ViewAppSheetInfo app={app} isInstalled={isInstalled} />
+ <ViewAppSheetInfo app={app} isInstalled={isInstalled} installation={installation} />
<ViewAppSheetPermissions permissions={permissions} isLoading={isLoadingDetail} />
<ViewAppSheetDangerZone onDelete={() => setShowDeleteModal(true)} />
</div>
diff --git a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheetInfo.tsx b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheetInfo.tsx
index bbe2845e9b8..bee6b4cf05e 100644
--- a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheetInfo.tsx
+++ b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheetInfo.tsx
@@ -1,4 +1,7 @@
import { formatDistanceToNow } from 'date-fns'
+import { Check, Copy } from 'lucide-react'
+import { useState } from 'react'
+import { toast } from 'sonner'
import {
Badge,
Card,
@@ -9,15 +12,48 @@ import {
TableHead,
TableHeader,
TableRow,
+ copyToClipboard,
} from 'ui'
-import type { PrivateApp } from '../../PrivateAppsContext'
+import type { Installation, PrivateApp } from '../../PrivateAppsContext'
interface ViewAppSheetInfoProps {
app: PrivateApp
isInstalled: boolean
+ installation: Installation | undefined
}
-export function ViewAppSheetInfo({ app, isInstalled }: ViewAppSheetInfoProps) {
+function CopyableId({ id, label }: { id: string; label: string }) {
+ const [isCopied, setIsCopied] = useState(false)
+
+ function handleCopy(e: React.MouseEvent) {
+ e.stopPropagation()
+ copyToClipboard(id, () => {
+ setIsCopied(true)
+ toast.success(`Copied ${label} to clipboard`)
+ setTimeout(() => setIsCopied(false), 2000)
+ })
+ }
+
+ return (
+ <button
+ onClick={handleCopy}
+ className="inline-flex items-center gap-x-1 cursor-pointer border border-transparent border-dashed rounded transition-colors hover:bg-surface-100 hover:border hover:border-strong group font-mono text-xs text-foreground-light px-1 -ml-1"
+ >
+ <span className="truncate">{id}</span>
+ {isCopied ? (
+ <Check size={12} strokeWidth={1.25} className="text-brand shrink-0" />
+ ) : (
+ <Copy
+ size={12}
+ strokeWidth={1.25}
+ className="opacity-0 group-hover:opacity-100 transition-opacity shrink-0"
+ />
+ )}
+ </button>
+ )
+}
+
+export function ViewAppSheetInfo({ app, isInstalled, installation }: ViewAppSheetInfoProps) {
return (
<div className="px-5 sm:px-6 py-6 space-y-3">
<h3 className="text-sm font-medium text-foreground">Metadata</h3>
@@ -26,10 +62,10 @@ export function ViewAppSheetInfo({ app, isInstalled }: ViewAppSheetInfoProps) {
<Table className="table-fixed w-full">
<TableHeader>
<TableRow>
- <TableHead className="text-left font-mono uppercase text-xs text-foreground-lighter h-auto py-2 w-[50%]">
+ <TableHead className="text-left font-mono uppercase text-xs text-foreground-lighter h-auto py-2 w-[40%]">
Field
</TableHead>
- <TableHead className="text-left font-mono uppercase text-xs text-foreground-lighter h-auto py-2 w-[50%]">
+ <TableHead className="text-left font-mono uppercase text-xs text-foreground-lighter h-auto py-2 w-[60%]">
Value
</TableHead>
</TableRow>
@@ -69,6 +105,26 @@ export function ViewAppSheetInfo({ app, isInstalled }: ViewAppSheetInfoProps) {
)}
</TableCell>
</TableRow>
+ <TableRow>
+ <TableCell>
+ <p className="text-foreground-light truncate">App ID</p>
+ </TableCell>
+ <TableCell>
+ <CopyableId id={app.id} label="App ID" />
+ </TableCell>
+ </TableRow>
+ <TableRow>
+ <TableCell>
+ <p className="text-foreground-light truncate">Installation ID</p>
+ </TableCell>
+ <TableCell>
+ {installation ? (
+ <CopyableId id={installation.id} label="Installation ID" />
+ ) : (
+ <p className="font-mono text-xs text-foreground-light">—</p>
+ )}
+ </TableCell>
+ </TableRow>
</TableBody>
</Table>
</CardContent>
diff --git a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheetPermissions.tsx b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheetPermissions.tsx
index eb63be23a6d..0211186632a 100644
--- a/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheetPermissions.tsx
+++ b/apps/studio/components/interfaces/Organization/PrivateApps/Apps/ViewAppSheet/ViewAppSheetPermissions.tsx
@@ -27,10 +27,10 @@ export function ViewAppSheetPermissions({ permissions, isLoading }: ViewAppSheet
<Table className="table-fixed w-full">
<TableHeader>
<TableRow>
- <TableHead className="text-left font-mono uppercase text-xs text-foreground-lighter h-auto py-2 w-[50%]">
+ <TableHead className="text-left font-mono uppercase text-xs text-foreground-lighter h-auto py-2 w-[40%]">
Permission
</TableHead>
- <TableHead className="text-left font-mono uppercase text-xs text-foreground-lighter h-auto py-2 w-[50%]">
+ <TableHead className="text-left font-mono uppercase text-xs text-foreground-lighter h-auto py-2 w-[60%]">
Description
</TableHead>
</TableRow>
diff --git a/apps/studio/components/interfaces/Storage/StorageExplorer/StorageExplorer.utils.tsx b/apps/studio/components/interfaces/Storage/StorageExplorer/StorageExplorer.utils.tsx
index bc8dbe73db0..0459fd3c838 100644
--- a/apps/studio/components/interfaces/Storage/StorageExplorer/StorageExplorer.utils.tsx
+++ b/apps/studio/components/interfaces/Storage/StorageExplorer/StorageExplorer.utils.tsx
@@ -1,10 +1,10 @@
import { toast } from 'sonner'
-
-import { StorageObject } from 'data/storage/bucket-objects-list-mutation'
import { copyToClipboard } from 'ui'
+
import { inverseValidObjectKeyRegex, validObjectKeyRegex } from '../CreateBucketModal.utils'
import { STORAGE_ROW_STATUS, STORAGE_ROW_TYPES } from '../Storage.constants'
import { StorageItem, StorageItemMetadata } from '../Storage.types'
+import type { StorageObject } from '@/data/storage/bucket-objects-list-mutation'
import type { StorageExplorerState } from '@/state/storage-explorer'
type UploadProgress = {
@@ -164,7 +164,8 @@ export const formatFolderItems = (items: StorageObject[] = [], prefix?: string):
.map((item) => {
const type = item.id ? STORAGE_ROW_TYPES.FILE : STORAGE_ROW_TYPES.FOLDER
- const durationSinceCreated = Number(new Date()) - Number(new Date(item.created_at))
+ const durationSinceCreated =
+ Number(new Date()) - Number(item.created_at ? new Date(item.created_at) : new Date())
const isCorrupted =
type === STORAGE_ROW_TYPES.FILE &&
!item.metadata &&
diff --git a/packages/api-types/types/platform.d.ts b/packages/api-types/types/platform.d.ts
index 8d5b481152b..5d3a7fe59e5 100644
--- a/packages/api-types/types/platform.d.ts
+++ b/packages/api-types/types/platform.d.ts
@@ -2432,183 +2432,8 @@ export interface paths {
delete: operations['LogDrainController_deleteLogDrain']
options?: never
head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/access-tokens': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- /** Lists project's warehouse access tokens from logflare */
- get: operations['AccessTokenController_listAccessTokens']
- put?: never
- /** Create a warehouse access token */
- post: operations['AccessTokenController_createAccessToken']
- delete?: never
- options?: never
- head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/access-tokens/{token}': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- get?: never
- put?: never
- post?: never
- /** Delete a warehouse access token */
- delete: operations['AccessTokenController_deleteAccessToken']
- options?: never
- head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/collections': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- /** Lists project's telemetry collections from logflare */
- get: operations['CollectionController_listCollections']
- put?: never
- /** Create a telemetry collection */
- post: operations['CollectionController_createCollection']
- delete?: never
- options?: never
- head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/collections/{token}': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- /** Get a telemetry collection */
- get: operations['CollectionController_getCollectionSchema']
- put?: never
- post?: never
- /** Delete a telemetry collection */
- delete: operations['CollectionController_deleteCollection']
- options?: never
- head?: never
- /** Update a telemetry collection */
- patch: operations['CollectionController_updateCollection']
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/collections/{token}/schema': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- /** Get a telemetry collection schema */
- get: operations['CollectionController_getCollection']
- put?: never
- post?: never
- delete?: never
- options?: never
- head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/endpoints': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- /** Lists project's warehouse endpoints from logflare */
- get: operations['EndpointController_listEndpoints']
- put?: never
- /** Create a warehouse endpoint */
- post: operations['EndpointController_createEndpoint']
- delete?: never
- options?: never
- head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/endpoints/{token}': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- get?: never
- /** Update a warehouse endpoint */
- put: operations['EndpointController_updateEndpoint']
- post?: never
- /** Delete a warehouse endpoint */
- delete: operations['EndpointController_deleteEndpoint']
- options?: never
- head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/query': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- /** Lists project's warehouse queries from logflare */
- get: operations['WarehouseQueryController_runQuery']
- put?: never
- post?: never
- delete?: never
- options?: never
- head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/query/parse': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- /** Parses a warehouse query */
- get: operations['WarehouseQueryController_parseQuery']
- put?: never
- post?: never
- delete?: never
- options?: never
- head?: never
- patch?: never
- trace?: never
- }
- '/platform/projects/{ref}/analytics/warehouse/tenant': {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- /** Gets project's warehouse tenant from logflare */
- get: operations['TenantController_getTenant']
- put?: never
- post?: never
- delete?: never
- options?: never
- head?: never
- patch?: never
+ /** Patch a log drain */
+ patch: operations['LogDrainController_patchLogDrain']
trace?: never
}
'/platform/projects/{ref}/api-keys/temporary': {
@@ -4763,7 +4588,7 @@ export interface components {
slug: string
}
/** @enum {string} */
- status: 'pending' | 'complete' | 'expired'
+ status: 'pending' | 'complete' | 'expired' | 'error'
}
AddAwsAccountToPrivateLinkBody: {
account_name?: string
@@ -4991,7 +4816,7 @@ export interface components {
CreateBackendParamsOpenapi: {
config:
| {
- hostname: string
+ hostname?: string
password?: string | null
port?: number | null
schema?: string
@@ -5005,19 +4830,19 @@ export interface components {
}
/** @enum {string} */
http?: 'http1' | 'http2'
- url: string
+ url?: string
}
| {
- dataset_id: string
- project_id: string
+ dataset_id?: string
+ project_id?: string
}
| {
- api_key: string
- region: string
+ api_key?: string
+ region?: string
}
| {
password?: string | null
- url: string
+ url?: string
username?: string | null
}
| {
@@ -5025,17 +4850,28 @@ export interface components {
[key: string]: string
}
password?: string | null
- url: string
+ url?: string
username?: string | null
}
| {
- dsn: string
+ dsn?: string
}
| {
- api_token: string
- dataset_name: string
+ api_token?: string
+ dataset_name?: string
domain?: string
}
+ | {
+ ca_cert?: string
+ cipher_key?: string
+ client_cert?: string
+ client_key?: string
+ host?: string
+ port?: number
+ structured_data?: string
+ /** @default false */
+ tls?: boolean
+ }
description?: string
name: string
/** @enum {string} */
@@ -5052,6 +4888,7 @@ export interface components {
| 'axiom'
| 'last9'
| 'otlp'
+ | 'syslog'
}
CreateBucketIndexBody: {
/** @enum {string} */
@@ -5069,10 +4906,6 @@ export interface components {
session_id: string
token_name?: string
}
- CreateCollectionBody: {
- name: string
- retention_days: number
- }
CreateContentFolderBody: {
name: string
/** Format: uuid */
@@ -5421,6 +5254,8 @@ export interface components {
| 'infra_read_replicas_write'
| 'project_snippets_read'
| 'project_snippets_write'
+ | 'realtime_config_read'
+ | 'realtime_config_write'
| 'storage_read'
| 'storage_write'
| 'storage_config_read'
@@ -5882,6 +5717,8 @@ export interface components {
| 'infra_read_replicas_write'
| 'project_snippets_read'
| 'project_snippets_write'
+ | 'realtime_config_read'
+ | 'realtime_config_write'
| 'storage_read'
| 'storage_write'
| 'storage_config_read'
@@ -7289,17 +7126,10 @@ export interface components {
/** Format: uri */
receipt_pdf: string
}
- LFAccessToken: {
- description: string | null
- id: number
- inserted_at: string
- scopes: string
- token: string
- }
LFBackend: {
config:
| {
- hostname: string
+ hostname?: string
password?: string | null
port?: number | null
schema?: string
@@ -7313,19 +7143,19 @@ export interface components {
}
/** @enum {string} */
http?: 'http1' | 'http2'
- url: string
+ url?: string
}
| {
- dataset_id: string
- project_id: string
+ dataset_id?: string
+ project_id?: string
}
| {
- api_key: string
- region: string
+ api_key?: string
+ region?: string
}
| {
password?: string | null
- url: string
+ url?: string
username?: string | null
}
| {
@@ -7333,17 +7163,28 @@ export interface components {
[key: string]: string
}
password?: string | null
- url: string
+ url?: string
username?: string | null
}
| {
- dsn: string
+ dsn?: string
}
| {
- api_token: string
- dataset_name: string
+ api_token?: string
+ dataset_name?: string
domain?: string
}
+ | {
+ ca_cert?: string
+ cipher_key?: string
+ client_cert?: string
+ client_key?: string
+ host?: string
+ port?: number
+ structured_data?: string
+ /** @default false */
+ tls?: boolean
+ }
description?: string
id: number
metadata: {
@@ -7367,48 +7208,9 @@ export interface components {
| 'axiom'
| 'last9'
| 'otlp'
+ | 'syslog'
user_id: number
}
- LFEndpoint: {
- cache_duration_seconds: number
- description: string
- enable_auth: number
- id: number
- /** @enum {string} */
- language: 'bq_sql' | 'pg_sql'
- max_limit: number
- name: string
- proactive_requerying_seconds: number
- query: string
- sandboxable: boolean | null
- token: string
- }
- LFSource: {
- bigquery_table_ttl: number
- custom_event_message_keys: string | null
- favourite: boolean
- id: number
- lock_schema: boolean
- name: string
- public_token: string | null
- retention_days: number
- slack_hook_url: string | null
- token: string
- webhook_notification_url: string | null
- }
- LFUser: {
- bigquery_dataset_id: string | null
- bigquery_dataset_location: string | null
- bigquery_project_id: string | null
- company: string | null
- email: string | null
- email_me_product: string | null
- metadata?: {
- project_ref: string
- }
- phone: string | null
- token: string
- }
LinkClazarBuyerBody: {
buyer_id: string
}
@@ -9738,17 +9540,15 @@ export interface components {
}
StorageListResponseV2: {
folders: {
- created_at: string
- key: string
+ key?: string
name: string
- updated_at: string
}[]
hasNext: boolean
nextCursor?: string
objects: {
created_at: string
id: string
- key: string
+ key?: string
last_accessed_at: string
metadata: {
cacheControl?: string | null
@@ -9758,14 +9558,14 @@ export interface components {
lastModified?: string | null
mimetype?: string | null
size?: number | null
- }
+ } | null
name: string
updated_at: string
}[]
}
StorageObject: {
- bucket_id: string
- buckets: {
+ bucket_id?: string
+ buckets?: {
allowed_mime_types?: string[]
created_at: string
file_size_limit?: number
@@ -9777,15 +9577,15 @@ export interface components {
type?: 'STANDARD' | 'ANALYTICS'
updated_at: string
}
- created_at: string
- id: string
- last_accessed_at: string
+ created_at: string | null
+ id: string | null
+ last_accessed_at: string | null
metadata: {
[key: string]: unknown
- }
+ } | null
name: string
- owner: string
- updated_at: string
+ owner?: string
+ updated_at: string | null
}
StorageVectorBucketListIndexesResponse: {
indexes: {
@@ -10085,7 +9885,7 @@ export interface components {
UpdateBackendParamsOpenapi: {
config?:
| {
- hostname: string
+ hostname?: string
password?: string | null
port?: number | null
schema?: string
@@ -10099,19 +9899,19 @@ export interface components {
}
/** @enum {string} */
http?: 'http1' | 'http2'
- url: string
+ url?: string
}
| {
- dataset_id: string
- project_id: string
+ dataset_id?: string
+ project_id?: string
}
| {
- api_key: string
- region: string
+ api_key?: string
+ region?: string
}
| {
password?: string | null
- url: string
+ url?: string
username?: string | null
}
| {
@@ -10119,21 +9919,32 @@ export interface components {
[key: string]: string
}
password?: string | null
- url: string
+ url?: string
username?: string | null
}
| {
- dsn: string
+ dsn?: string
}
| {
- api_token: string
- dataset_name: string
+ api_token?: string
+ dataset_name?: string
domain?: string
}
+ | {
+ ca_cert?: string
+ cipher_key?: string
+ client_cert?: string
+ client_key?: string
+ host?: string
+ port?: number
+ structured_data?: string
+ /** @default false */
+ tls?: boolean
+ }
description?: string
name?: string
/** @enum {string} */
- type:
+ type?:
| 'postgres'
| 'bigquery'
| 'clickhouse'
@@ -10146,10 +9957,7 @@ export interface components {
| 'axiom'
| 'last9'
| 'otlp'
- }
- UpdateCollectionBody: {
- name: string
- retention_days: number
+ | 'syslog'
}
UpdateContentFolderBody: {
name: string
@@ -10602,6 +10410,8 @@ export interface components {
| 'infra_read_replicas_write'
| 'project_snippets_read'
| 'project_snippets_write'
+ | 'realtime_config_read'
+ | 'realtime_config_write'
| 'storage_read'
| 'storage_write'
| 'storage_config_read'
@@ -19267,764 +19077,30 @@ export interface operations {
}
}
}
- AccessTokenController_listAccessTokens: {
+ LogDrainController_patchLogDrain: {
parameters: {
query?: never
header?: never
path: {
/** @description Project ref */
ref: string
+ /** @description Log drains identifier */
+ token: string
}
cookie?: never
}
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFAccessToken'][]
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to fetch warehouse access tokens */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
+ requestBody: {
+ content: {
+ 'application/json': components['schemas']['UpdateBackendParamsOpenapi']
}
}
- }
- AccessTokenController_createAccessToken: {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- requestBody?: never
responses: {
- 201: {
+ 200: {
headers: {
[name: string]: unknown
}
content: {
- 'application/json': components['schemas']['LFAccessToken']
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to create warehouse access token */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- AccessTokenController_deleteAccessToken: {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to delete warehouse access token */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- CollectionController_listCollections: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- }
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFSource'][]
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to fetch telemetry collections */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- CollectionController_createCollection: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- }
- cookie?: never
- }
- requestBody: {
- content: {
- 'application/json': components['schemas']['CreateCollectionBody']
- }
- }
- responses: {
- 201: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFSource']
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to create telemetry collection */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- CollectionController_getCollectionSchema: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- token: string
- }
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFSource']
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to fetch telemetry collection */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- CollectionController_deleteCollection: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- token: string
- }
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFSource']
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to delete telemetry collection */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- CollectionController_updateCollection: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- token: string
- }
- cookie?: never
- }
- requestBody: {
- content: {
- 'application/json': components['schemas']['UpdateCollectionBody']
- }
- }
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFSource']
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to update telemetry collection */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- CollectionController_getCollection: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- token: string
- variant: 'dot' | 'json_schema'
- }
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFSource']
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to fetch telemetry collection schema */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- EndpointController_listEndpoints: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- }
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFEndpoint'][]
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to fetch warehouse endpoints */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- EndpointController_createEndpoint: {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- requestBody?: never
- responses: {
- 201: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFEndpoint']
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to create warehouse endpoint */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- EndpointController_updateEndpoint: {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFEndpoint']
- }
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to update warehouse endpoint */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- EndpointController_deleteEndpoint: {
- parameters: {
- query?: never
- header?: never
- path?: never
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to delete warehouse endpoint */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- WarehouseQueryController_runQuery: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- }
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to fetch warehouse queries */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- WarehouseQueryController_parseQuery: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- }
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Unauthorized */
- 401: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Forbidden action */
- 403: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Rate limit exceeded */
- 429: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- /** @description Failed to parse warehouse query */
- 500: {
- headers: {
- [name: string]: unknown
- }
- content?: never
- }
- }
- }
- TenantController_getTenant: {
- parameters: {
- query?: never
- header?: never
- path: {
- /** @description Project ref */
- ref: string
- }
- cookie?: never
- }
- requestBody?: never
- responses: {
- 200: {
- headers: {
- [name: string]: unknown
- }
- content: {
- 'application/json': components['schemas']['LFUser']
+ 'application/json': components['schemas']['LFBackend']
}
}
/** @description Unauthorized */
@@ -20048,7 +19124,7 @@ export interface operations {
}
content?: never
}
- /** @description Failed to fetch or provision warehouse tenant */
+ /** @description Failed to patch log drain */
500: {
headers: {
[name: string]: unknown
diff --git a/packages/common/telemetry-constants.ts b/packages/common/telemetry-constants.ts
index 4ccbee941c3..27a9600b424 100644
--- a/packages/common/telemetry-constants.ts
+++ b/packages/common/telemetry-constants.ts
@@ -2603,6 +2603,7 @@ export interface LogDrainSaveButtonClickedEvent {
| 'axiom'
| 'last9'
| 'otlp'
+ | 'syslog'
}
groups: TelemetryGroups
}
@@ -2633,6 +2634,7 @@ export interface LogDrainConfirmButtonSubmittedEvent {
| 'axiom'
| 'last9'
| 'otlp'
+ | 'syslog'
}
groups: TelemetryGroups
}