:hedgehog: PostHog is the leading platform for building self-driving products. Our developer tools – AI observability, analytics, session replay, flags, experiments, error tracking, logs, and more – capture all the context agents need to diagnose problems, uncover opportunities, and ship fixes. Steer it all from Slack, web, desktop, or the MCP.
Python ab-testingai-analyticsanalyticscdpdata-warehouseexperimentsfeature-flagsjavascriptproduct-analyticspythonreactsession-replaysurveystypescriptweb-analytics
refactor(warehouse-sources): own the source-config contract in backend (#94996)
Julian Bezab90930ea386
diff --git a/docs/published/handbook/engineering/type-system.md b/docs/published/handbook/engineering/type-system.mdindex 213bb5396228..3ecab3a6abc9 100644--- a/docs/published/handbook/engineering/type-system.md+++ b/docs/published/handbook/engineering/type-system.md@@ -81,6 +81,8 @@ ViewSets in `products/*/backend/` are **automatically tagged** based on their moSerializers are the source of truth for response types. Use explicit field types and `help_text` where helpful.+Some response contracts already exist in the backend as Pydantic models, for example a discriminated union that sources build at runtime. Declare those models directly as the response in `@extend_schema(responses=...)`. drf-spectacular converts them to OpenAPI, so do not copy them into a serializer. Keep ordinary resource endpoints on serializers. See `products/warehouse_sources/backend/facade/source_config.py` for an example.+For detailed guidance on serializer patterns, field typing, and annotations that improve OpenAPI generation, see the [`improving-drf-endpoints` skill](https://github.com/PostHog/posthog/blob/master/.agents/skills/improving-drf-endpoints/SKILL.md).### Documenting query parameters@@ -154,7 +156,7 @@ Add to `schema.ts` when you need a type that:- Do not add types that are only used in the frontend UI- Do not add types just because you need a type in Python – use handwritten types for backend-only logic-If you need a type from the backend in the frontend, define it in serializers and use the backend → frontend generation system.+If you need a type from the backend in the frontend, define it in a serializer or a Pydantic response model and use the backend → frontend generation system.For backend-only types, define Pydantic models directly in your own product e.g. in a `domain_types.py` file.diff --git a/frontend/src/lib/api.ts b/frontend/src/lib/api.tsindex 41cd4206e9b5..944d634a426b 100644--- a/frontend/src/lib/api.ts+++ b/frontend/src/lib/api.ts@@ -38,7 +38,6 @@ import {ErrorTrackingExternalReference,ErrorTrackingIssue,ErrorTrackingRelationalIssue,- ExternalDataSourceType,FileSystemCount,FileSystemEntry,FileSystemViewLogEntry,@@ -60,7 +59,6 @@ import {RecordingsQuery,RecordingsQueryResponse,RefreshType,- SourceConfig,SpanTreeNode,TileFilters,UserProductListItem,@@ -245,6 +243,10 @@ import type {TaskRunBootstrapCreateRequestInitialPermissionModeEnumApi,TaskRunCreateRequestSchemaApi,} from 'products/tasks/frontend/generated/api.schemas'+import type {+ ExternalDataSourceTypeEnumApi,+ SourceConfigMapResponseApi,+} from 'products/warehouse_sources/frontend/generated/api.schemas'import type { BlastRadiusApi } from 'products/workflows/frontend/generated/api.schemas'import type { HogFlowPublishResponseApi } from 'products/workflows/frontend/generated/api.schemas'import type { MessageTemplate } from 'products/workflows/frontend/TemplateLibrary/types'@@ -5888,7 +5890,7 @@ const api = {return await new ApiRequest().externalDataSource(sourceId).update({ data })},async database_schema(- source_type: ExternalDataSourceType,+ source_type: ExternalDataSourceTypeEnumApi,payload: Record<string, any>): Promise<ExternalDataSourceSyncSchema[]> {return await new ApiRequest()@@ -5896,11 +5898,11 @@ const api = {.withAction('database_schema').create({ data: { source_type, ...payload } })},- async wizard(): Promise<Record<string, SourceConfig>> {+ async wizard(): Promise<SourceConfigMapResponseApi> {return await new ApiRequest().externalDataSources().withAction('wizard').get()},async source_prefix(- source_type: ExternalDataSourceType,+ source_type: ExternalDataSourceTypeEnumApi,prefix: string): Promise<ExternalDataSourceSyncSchema[]> {return await new ApiRequest()@@ -5910,7 +5912,7 @@ const api = {},async check_cdc_prerequisites(payload: {- source_type: ExternalDataSourceType+ source_type: ExternalDataSourceTypeEnumApicdc_management_mode: 'posthog' | 'self_managed'tables?: string[]cdc_slot_name?: string | nulldiff --git a/frontend/src/scenes/data-pipelines/utils/nonHogFunctionTemplatesLogic.tsx b/frontend/src/scenes/data-pipelines/utils/nonHogFunctionTemplatesLogic.tsxindex 5573d11d0997..dd5e1c46939b 100644--- a/frontend/src/scenes/data-pipelines/utils/nonHogFunctionTemplatesLogic.tsx+++ b/frontend/src/scenes/data-pipelines/utils/nonHogFunctionTemplatesLogic.tsx@@ -7,18 +7,18 @@ import { featureFlagLogic } from 'lib/logic/featureFlagLogic'import { humanizeBatchExportDescription, humanizeBatchExportName } from 'scenes/data-pipelines/batch-exports/utils'import { userLogic } from 'scenes/userLogic'-import { SourceConfig } from '~/queries/schema/schema-general'import { BATCH_EXPORT_SERVICE_NAMES, HogFunctionTemplateStatus, HogFunctionTemplateType } from '~/types'import { sourceWizardLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic'import { DATA_WAREHOUSE_SOURCE_ICON_MAP } from 'products/data_warehouse/frontend/shared/components/SourceIcon'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import type { FeatureFlagsSet } from '../../../lib/logic/featureFlagLogic'import type { ManualLinkSourceType, UserType } from '../../../types'import { BATCH_EXPORT_ICON_MAP } from '../batch-exports/BatchExportIcon'export interface NonHogFunctionTemplatesLogicProps {- availableSources: Record<string, SourceConfig>+ availableSources: Record<string, SourceConfigResponseApi>}type SourceDisplayStatus = {@@ -58,7 +58,7 @@ export function getSourceDisplayStatus(unreleased: boolean, featureFlag: boolean// Generated by kea-typegen. Update if you're an agent, ignore if you're human.export interface nonHogFunctionTemplatesLogicValues {featureFlags: FeatureFlagsSet // featureFlagLogic- connectors: SourceConfig[] // sourceWizardLogic+ connectors: SourceConfigResponseApi[] // sourceWizardLogicmanualConnectors: {name: stringtype: ManualLinkSourceType@@ -72,7 +72,7 @@ export interface nonHogFunctionTemplatesLogicValues {export interface nonHogFunctionTemplatesLogicMeta {__keaTypeGenInternalSelectorTypes: {hogFunctionTemplatesDataWarehouseSources: (- connectors: SourceConfig[],+ connectors: SourceConfigResponseApi[],manualConnectors: {name: stringtype: ManualLinkSourceType@@ -112,14 +112,14 @@ export const nonHogFunctionTemplatesLogic = kea<nonHogFunctionTemplatesLogicTypehogFunctionTemplatesDataWarehouseSources: [(s) => [s.connectors, s.manualConnectors, s.featureFlags],(- connectors: SourceConfig[],+ connectors: SourceConfigResponseApi[],manualConnectors: {name: stringtype: import('~/types').ManualLinkSourceType}[],featureFlags: import('lib/logic/featureFlagLogic').FeatureFlagsSet): HogFunctionTemplateType[] => {- const managed = connectors.map((connector: SourceConfig): HogFunctionTemplateType => {+ const managed = connectors.map((connector: SourceConfigResponseApi): HogFunctionTemplateType => {const featureFlagDefined = !!connector.featureFlagconst featureFlagRaw = featureFlags[connector.featureFlag as FeatureFlagKey]// Treat "flag declared but absent in featureFlags" as off — non-cloud@@ -142,7 +142,7 @@ export const nonHogFunctionTemplatesLogic = kea<nonHogFunctionTemplatesLogicTypetype: 'source',name: connector.label ?? connector.name,icon_url: connector.iconPath,- icon_class_name: connector.iconClassName,+ icon_class_name: connector.iconClassName ?? undefined,status: status,description: descriptionEl,code: '',diff --git a/frontend/src/scenes/data-pipelines/utils/nonHogFunctionsLogic.tsx b/frontend/src/scenes/data-pipelines/utils/nonHogFunctionsLogic.tsxindex 4e343ba311cc..0ea320e6a20c 100644--- a/frontend/src/scenes/data-pipelines/utils/nonHogFunctionsLogic.tsx+++ b/frontend/src/scenes/data-pipelines/utils/nonHogFunctionsLogic.tsx@@ -12,8 +12,8 @@ import { HogFunctionType, PluginConfigTypeNew, PluginType } from '~/types'import { sourceWizardLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic'+import type { SourceConfigResponseApi } from '../../../../../products/warehouse_sources/frontend/generated/api.schemas'import type { FeatureFlagsSet } from '../../../lib/logic/featureFlagLogic'-import type { SourceConfig } from '../../../queries/schema/schema-general'import type { UserType } from '../../../types'import { BATCH_EXPORT_ICON_MAP } from '../batch-exports/BatchExportIcon'import { humanizeBatchExportDescription } from '../batch-exports/utils'@@ -22,7 +22,7 @@ import { humanizeBatchExportDescription } from '../batch-exports/utils'export interface nonHogFunctionsLogicValues {featureFlags: FeatureFlagsSet // featureFlagLogiccurrentOrganizationId: string // organizationLogic- connectors: SourceConfig[] // sourceWizardLogic+ connectors: SourceConfigResponseApi[] // sourceWizardLogiccurrentProjectId: number | string // teamLogicuser: UserType | null // userLogichogFunctionBatchExports: HogFunctionType[] | nulldiff --git a/frontend/src/scenes/data-warehouse/editor/sidebar/QueryDatabase.tsx b/frontend/src/scenes/data-warehouse/editor/sidebar/QueryDatabase.tsxindex 86e82c31af51..c80ab60f48a8 100644--- a/frontend/src/scenes/data-warehouse/editor/sidebar/QueryDatabase.tsx+++ b/frontend/src/scenes/data-warehouse/editor/sidebar/QueryDatabase.tsx@@ -56,12 +56,13 @@ import { expressionModalLogic } from 'scenes/data-warehouse/expressionModalLogicimport { urls } from 'scenes/urls'import { SearchHighlightMultiple } from '~/layout/navigation-3000/components/SearchHighlight'-import { DatabaseSerializedFieldType, externalDataSources } from '~/queries/schema/schema-general'+import { DatabaseSerializedFieldType } from '~/queries/schema/schema-general'import { escapeDottedHogQLIdentifier, escapePropertyAsHogQLIdentifier } from '~/queries/utils'import { AccessControlLevel, AccessControlResourceType } from '~/types'import { sourceManagementLogic } from 'products/data_warehouse/frontend/shared/logics/sourceManagementLogic'import { buildSelectAllQuery } from 'products/data_warehouse/frontend/utils'+import { ExternalDataSourceTypeEnumApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { dataWarehouseViewsLogic } from '../../saved_queries/dataWarehouseViewsLogic'import { TableCertificationIcon } from '../../TableCertificationBadge'@@ -1132,7 +1133,7 @@ export const QueryDatabase = ({// External source folders get an actions menu: edit the source and add a new one of this typeif (item.record?.type === 'source-folder' &&- externalDataSources.includes(item.record?.sourceType as (typeof externalDataSources)[number])+ Object.values(ExternalDataSourceTypeEnumApi).includes(item.record?.sourceType)) {const sourceType = item.record?.sourceTypeconst sources: { id: string; label: string }[] = item.record?.sources ?? []diff --git a/frontend/src/scenes/onboarding/legacy/data-warehouse/DataWarehouseQueryVariant.tsx b/frontend/src/scenes/onboarding/legacy/data-warehouse/DataWarehouseQueryVariant.tsxindex 43fd2e0a3346..4d15dee7b0e9 100644--- a/frontend/src/scenes/onboarding/legacy/data-warehouse/DataWarehouseQueryVariant.tsx+++ b/frontend/src/scenes/onboarding/legacy/data-warehouse/DataWarehouseQueryVariant.tsx@@ -7,7 +7,6 @@ import { LemonButton } from '@posthog/lemon-ui'import { eventUsageLogic } from 'lib/utils/eventUsageLogic'-import { SourceConfig } from '~/queries/schema/schema-general'import { OnboardingStepKey } from '~/types'import IconPostHog from 'public/posthog-icon.svg'@@ -21,6 +20,7 @@ import IconZendesk from 'public/services/zendesk.png'import { availableSourcesLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/availableSourcesLogic'import { sourceWizardLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic'import { InlineSourceSetup } from 'products/data_warehouse/frontend/shared/components/InlineSourceSetup'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { onboardingLogic } from '../onboardingLogic'import { OnboardingStep } from '../OnboardingStep'@@ -160,7 +160,7 @@ function DataWarehouseQueryInner(): JSX.Element {const [phase, setPhase] = useState<'value-prop' | 'setup'>(initialOnboardingPhase)const [sceneIndex, setSceneIndex] = useState(0)- const visibleConnectors = connectors.filter((c: SourceConfig) => !c.unreleasedSource)+ const visibleConnectors = connectors.filter((c: SourceConfigResponseApi) => !c.unreleasedSource)const s = QUERY_SCENES[sceneIndex]useEffect(() => {diff --git a/frontend/src/scenes/onboarding/legacy/data-warehouse/DataWarehouseValuePropVariant.tsx b/frontend/src/scenes/onboarding/legacy/data-warehouse/DataWarehouseValuePropVariant.tsxindex fccca5a55aea..9c88c91ca68c 100644--- a/frontend/src/scenes/onboarding/legacy/data-warehouse/DataWarehouseValuePropVariant.tsx+++ b/frontend/src/scenes/onboarding/legacy/data-warehouse/DataWarehouseValuePropVariant.tsx@@ -7,7 +7,6 @@ import { LemonButton, LemonTag } from '@posthog/lemon-ui'import { eventUsageLogic } from 'lib/utils/eventUsageLogic'-import { SourceConfig } from '~/queries/schema/schema-general'import { OnboardingStepKey } from '~/types'import IconPostHog from 'public/posthog-icon.svg'@@ -18,6 +17,7 @@ import IconZendesk from 'public/services/zendesk.png'import { availableSourcesLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/availableSourcesLogic'import { sourceWizardLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic'import { InlineSourceSetup } from 'products/data_warehouse/frontend/shared/components/InlineSourceSetup'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { onboardingLogic } from '../onboardingLogic'import { OnboardingStep } from '../OnboardingStep'@@ -73,7 +73,7 @@ function DataWarehouseValuePropInner(): JSX.Element {const { connectors } = useValues(sourceWizardLogic)const [phase, setPhase] = useState<'value-prop' | 'setup'>(initialOnboardingPhase)- const visibleConnectors = connectors.filter((c: SourceConfig) => !c.unreleasedSource)+ const visibleConnectors = connectors.filter((c: SourceConfigResponseApi) => !c.unreleasedSource)const handleConnectClick = (): void => {posthog.capture('dwh onboarding connect clicked', { variant: 'table' })diff --git a/frontend/src/scenes/onboarding/legacy/data-warehouse/components.tsx b/frontend/src/scenes/onboarding/legacy/data-warehouse/components.tsxindex 90bcb2f22784..52c843ff513c 100644--- a/frontend/src/scenes/onboarding/legacy/data-warehouse/components.tsx+++ b/frontend/src/scenes/onboarding/legacy/data-warehouse/components.tsx@@ -1,9 +1,9 @@import { useValues } from 'kea'-import { SourceConfig } from '~/queries/schema/schema-general'import { OnboardingStepKey } from '~/types'import { availableSourcesLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/availableSourcesLogic'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { OnboardingStep } from '../OnboardingStep'@@ -26,14 +26,14 @@ export function useDataWarehouseLoadingState(): { isLoading: boolean } {return { isLoading: availableSourcesLoading || availableSources === null }}-export function ConnectorIconGrid({ connectors }: { connectors: SourceConfig[] }): JSX.Element | null {+export function ConnectorIconGrid({ connectors }: { connectors: SourceConfigResponseApi[] }): JSX.Element | null {if (connectors.length === 0) {return null}return (<div className="flex flex-wrap justify-center gap-2">- {connectors.map((connector: SourceConfig) => (+ {connectors.map((connector: SourceConfigResponseApi) => (<divkey={connector.name}className="size-8 rounded-md border border-border bg-bg-light flex items-center justify-center"diff --git a/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/components/settings/CampaignNameMappingsConfiguration.tsx b/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/components/settings/CampaignNameMappingsConfiguration.tsxindex 645fb8e9beb3..8180ac3d5012 100644--- a/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/components/settings/CampaignNameMappingsConfiguration.tsx+++ b/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/components/settings/CampaignNameMappingsConfiguration.tsx@@ -7,7 +7,9 @@ import { LemonButton, LemonInputSelect, LemonSelect, LemonTag, LemonTextArea, Toimport { RestrictionScope, useRestrictedArea } from 'lib/components/RestrictedArea'import { TeamMembershipLevel } from 'lib/constants'-import { MatchField, VALID_NATIVE_MARKETING_SOURCES, externalDataSources } from '~/queries/schema/schema-general'+import { MatchField, VALID_NATIVE_MARKETING_SOURCES } from '~/queries/schema/schema-general'++import { ExternalDataSourceTypeEnumApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { marketingAnalyticsSettingsLogic } from '../../logic/marketingAnalyticsSettingsLogic'import {@@ -155,7 +157,7 @@ export function CampaignNameMappingsConfiguration({updateCampaignNameMappings(newMappings)}- const availableSources = externalDataSources.filter((source) =>+ const availableSources = Object.values(ExternalDataSourceTypeEnumApi).filter((source) =>VALID_NATIVE_MARKETING_SOURCES.includes(source as any))diff --git a/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/components/settings/MarketingIntegrationAdvancedSettings.tsx b/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/components/settings/MarketingIntegrationAdvancedSettings.tsxindex a50f5d735ad6..1e31986b5157 100644--- a/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/components/settings/MarketingIntegrationAdvancedSettings.tsx+++ b/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/components/settings/MarketingIntegrationAdvancedSettings.tsx@@ -2,7 +2,7 @@ import { useValues } from 'kea'import { featureFlagLogic } from 'lib/logic/featureFlagLogic'-import { externalDataSources } from '~/queries/schema/schema-general'+import { ExternalDataSourceTypeEnumApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { getEnabledNativeMarketingSources } from '../../logic/utils'import { IntegrationSettingsCard } from './IntegrationSettingsCard'@@ -10,7 +10,9 @@ import { IntegrationSettingsCard } from './IntegrationSettingsCard'export function MarketingIntegrationAdvancedSettings(): JSX.Element {const { featureFlags } = useValues(featureFlagLogic)const enabledSources = getEnabledNativeMarketingSources(featureFlags)- const availableIntegrations = externalDataSources.filter((source) => enabledSources.includes(source as any))+ const availableIntegrations = Object.values(ExternalDataSourceTypeEnumApi).filter((source) =>+ enabledSources.includes(source as any)+ )return (<div className="space-y-4">diff --git a/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/logic/utils.ts b/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/logic/utils.tsindex 4a5e633fe24f..16997cca1a7b 100644--- a/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/logic/utils.ts+++ b/frontend/src/scenes/web-analytics/tabs/marketing-analytics/frontend/logic/utils.ts@@ -4,7 +4,6 @@ import {AttributionMode,ConversionGoalFilter,DataWarehouseNode,- ExternalDataSourceType,IntegrationFilter,MARKETING_INTEGRATION_CONFIGS,MarketingAnalyticsColumnsSchemaNames,@@ -17,9 +16,11 @@ import {} from '~/queries/schema/schema-general'import { HogQLMathType, ManualLinkSourceType, PropertyMathType } from '~/types'+import type { ExternalDataSourceTypeEnumApi } from 'products/warehouse_sources/frontend/generated/api.schemas'+import { NativeSource } from './marketingAnalyticsLogic'-export type NonNativeMarketingSource = Extract<ExternalDataSourceType, 'BigQuery'>+export type NonNativeMarketingSource = Extract<ExternalDataSourceTypeEnumApi, 'BigQuery'>export const VALID_NON_NATIVE_MARKETING_SOURCES: NonNativeMarketingSource[] = ['BigQuery']export const VALID_SELF_MANAGED_MARKETING_SOURCES: ManualLinkSourceType[] = [diff --git a/frontend/src/types.ts b/frontend/src/types.tsindex 4362f2b3bc33..221dce99635c 100644--- a/frontend/src/types.ts+++ b/frontend/src/types.ts@@ -53,7 +53,6 @@ import type {ExperimentFunnelsQuery,ExperimentMetric,ExperimentTrendsQuery,- ExternalDataSourceType,FileSystemIconType,FileSystemImport,EndpointQueryNode,@@ -95,6 +94,7 @@ import type { CommentSlackThreadRefApi } from 'products/platform_features/fronteimport type { InsightFilterOverrideContextApi } from 'products/product_analytics/frontend/generated/api.schemas'import type { AIPromptConfigApi, DeliveryConfigApi } from 'products/subscriptions/frontend/generated/api.schemas'import type { TaskRuntimeEnumApi } from 'products/tasks/frontend/generated/api.schemas'+import type { ExternalDataSourceTypeEnumApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { CyclotronInputType } from 'products/workflows/frontend/Workflows/hogflows/steps/types'import type { HogFlow } from 'products/workflows/frontend/Workflows/hogflows/types'@@ -6437,7 +6437,7 @@ export interface ExternalDataSourceRevenueAnalyticsConfig {}export interface ExternalDataSourceCreatePayload {- source_type: ExternalDataSourceType+ source_type: ExternalDataSourceTypeEnumApiprefix?: stringdescription?: stringaccess_method?: 'warehouse' | 'direct'@@ -6469,7 +6469,7 @@ export interface ExternalDataSource {source_id: stringconnection_id: stringstatus: ExternalDataJobStatus- source_type: ExternalDataSourceType+ source_type: ExternalDataSourceTypeEnumApiprefix: string | nulldescription: string | nullaccess_method?: 'warehouse' | 'direct'@@ -6693,7 +6693,7 @@ export interface ExternalDataSourceSchema extends SimpleExternalDataSourceSchema/** Lightweight parent-source summary embedded in the single-schema retrieve endpoint. */export interface ExternalDataSchemaSourceSummary {id: string- source_type: ExternalDataSourceType+ source_type: ExternalDataSourceTypeEnumApiaccess_method?: ExternalDataSource['access_method']supports_column_selection?: booleansupports_row_filters?: booleandiff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/NewSourceScene.tsx b/products/data_warehouse/frontend/scenes/NewSourceScene/NewSourceScene.tsxindex 99d93ce63a4d..6113ec345a44 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/NewSourceScene.tsx+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/NewSourceScene.tsx@@ -27,9 +27,13 @@ import { urls } from 'scenes/urls'import { SceneContent } from '~/layout/scenes/components/SceneContent'import { SceneTitleSection } from '~/layout/scenes/components/SceneTitleSection'-import { ExternalDataSourceType, SourceConfig } from '~/queries/schema/schema-general'import { AccessControlLevel, AccessControlResourceType, Breadcrumb } from '~/types'+import {+ ExternalDataSourceTypeEnumApi,+ SourceConfigResponseApi,+} from 'products/warehouse_sources/frontend/generated/api.schemas'+import SchemaForm from '../../shared/components/forms/SchemaForm'import { splitQualifiedTableName, supportsDirectQuery } from '../../shared/components/forms/schemaGroupingUtils'import SourceForm, { SourceAccessMethodSelector, getSourceQueryMode } from '../../shared/components/forms/SourceForm'@@ -60,7 +64,7 @@ export const getEffectiveAccessMethod = (// Generated by kea-typegen. Update if you're an agent, ignore if you're human.export interface newSourceSceneLogicValues {- availableSources: Record<string, SourceConfig> | null // availableSourcesLogic+ availableSources: Record<string, SourceConfigResponseApi> | null // availableSourcesLogicavailableSourcesLoading: boolean // availableSourcesLogicbreadcrumbs: Breadcrumb[]}@@ -138,7 +142,11 @@ export function AvailableSourcesError(): JSX.Element {)}-function MountedNewSourceScene({ availableSources }: { availableSources: Record<string, SourceConfig> }): JSX.Element {+function MountedNewSourceScene({+ availableSources,+}: {+ availableSources: Record<string, SourceConfigResponseApi>+}): JSX.Element {const sourceWizardLogicProps = useMemo(() => ({ availableSources }), [availableSources])const wizardLogic = sourceWizardLogic(sourceWizardLogicProps)const sceneRootLogic = newSourceSceneLogic()@@ -183,8 +191,8 @@ function InternalNewSourceScene({interface NewSourcesWizardProps {onComplete?: () => void- allowedSources?: ExternalDataSourceType[] // Filter to only show these source types- initialSource?: ExternalDataSourceType // Pre-select this source and start on step 2+ allowedSources?: ExternalDataSourceTypeEnumApi[] // Filter to only show these source types+ initialSource?: ExternalDataSourceTypeEnumApi // Pre-select this source and start on step 2hideBackButton?: booleanautoConfigureTables?: boolean // Onboarding: pre-select all syncable tables for a one-click syncsourceWizardLogicProps?: SourceWizardLogicProps@@ -525,7 +533,7 @@ function FirstStep({ allowedSources }: NewSourcesWizardProps): JSX.Element {// Connectors in the "Databases" category that PostHog reaches over the provider's public HTTPS API// with a key the provider issues. The customer has no network path in front of them, so the// firewall hint would name a setup step that does not exist.-const SOURCES_WITHOUT_NETWORK_ALLOWLIST: ExternalDataSourceType[] = ['BigQuery', 'DynamoDB', 'Firebase']+const SOURCES_WITHOUT_NETWORK_ALLOWLIST: ExternalDataSourceTypeEnumApi[] = ['BigQuery', 'DynamoDB', 'Firebase']// Firewall allowlisting only applies to self-hosted databases PostHog dials out to, so the hint is// scoped to that category rather than shown for OAuth/API connectors.diff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/SourceCatalog.tsx b/products/data_warehouse/frontend/scenes/NewSourceScene/SourceCatalog.tsxindex ab1054f6ed04..ff0941cce51a 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/SourceCatalog.tsx+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/SourceCatalog.tsx@@ -8,9 +8,10 @@ import { Tooltip } from 'lib/lemon-ui/Tooltip'import { getAccessControlDisabledReason } from 'lib/utils/accessControlUtils'import { urls } from 'scenes/urls'-import { ExternalDataSourceType } from '~/queries/schema/schema-general'import { AccessControlLevel, AccessControlResourceType } from '~/types'+import { ExternalDataSourceTypeEnumApi } from 'products/warehouse_sources/frontend/generated/api.schemas'+import { SourceIcon } from '../../shared/components/SourceIcon'import { SourceReleaseTag } from '../../shared/components/SourceReleaseTag'import { WarehouseWizardHint } from '../../shared/components/WarehouseWizardHint'@@ -22,7 +23,7 @@ const TILE_CLASS ='flex flex-row items-center gap-4 p-5 min-h-[8.5rem] rounded-lg border border-border bg-surface-primary'export interface SourceCatalogProps {- allowedSources?: ExternalDataSourceType[]+ allowedSources?: ExternalDataSourceTypeEnumApi[]}// Memoized so the whole grid doesn't re-render per keystroke in the search input or requestdiff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/availableSourcesLogic.ts b/products/data_warehouse/frontend/scenes/NewSourceScene/availableSourcesLogic.tsindex 5151e3a98299..0f0f4f341b05 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/availableSourcesLogic.ts+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/availableSourcesLogic.ts@@ -3,11 +3,13 @@ import { loaders } from 'kea-loaders'import api from 'lib/api'-import { SourceConfig } from '~/queries/schema/schema-general'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'++import type { SourceConfigMapResponseApi } from '../../../../warehouse_sources/frontend/generated/api.schemas'// Generated by kea-typegen. Update if you're an agent, ignore if you're human.export interface availableSourcesLogicValues {- availableSources: Record<string, SourceConfig> | null+ availableSources: Record<string, SourceConfigResponseApi> | nullavailableSourcesLoading: boolean}@@ -22,10 +24,10 @@ export interface availableSourcesLogicActions {errorObject?: any}loadSuccess: (- availableSources: Record<string, SourceConfig> | null,+ availableSources: SourceConfigMapResponseApi | null,payload?: any) => {- availableSources: Record<string, SourceConfig> | null+ availableSources: SourceConfigMapResponseApi | nullpayload?: any}}@@ -36,7 +38,7 @@ export const availableSourcesLogic = kea<availableSourcesLogicType>([path(['products', 'dataWarehouse', 'availableSourcesLogic']),loaders({availableSources: [- null as Record<string, SourceConfig> | null,+ null as Record<string, SourceConfigResponseApi> | null,{load: async () => {try {diff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/fileUploadSource.ts b/products/data_warehouse/frontend/scenes/NewSourceScene/fileUploadSource.tsindex a83d232ccb41..eae9402aef2c 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/fileUploadSource.ts+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/fileUploadSource.ts@@ -1,19 +1,22 @@import { urls } from 'scenes/urls'-import { ExternalDataSourceType, SourceConfig } from '~/queries/schema/schema-general'+import {+ ExternalDataSourceTypeEnumApi,+ SourceConfigResponseApi,+} from 'products/warehouse_sources/frontend/generated/api.schemas'// File upload is a client-only catalog entry — it has no backend SourceConfig because an uploaded// file becomes a self-managed DataWarehouseTable (read in place from our own bucket), not a synced-// source. `FileUpload` is deliberately not a real `ExternalDataSourceType` (there is no backend-// source of that type), so it's cast here once to reuse the shared `SourceConfig` shape and the+// source. `FileUpload` is deliberately not a real source type (there is no backend+// source of that type), so it's cast here once to reuse the shared source-config shape and the// wizard's connector-selection plumbing. This synthetic config drives the wizard's second step and// the tile icon; the three tiles below (one per format) all point back at it, since users look for// "CSV", not "File upload".-export const FILE_UPLOAD_SOURCE_NAME = 'FileUpload' as unknown as ExternalDataSourceType+export const FILE_UPLOAD_SOURCE_NAME = 'FileUpload' as unknown as ExternalDataSourceTypeEnumApiexport type FileUploadFormat = 'csv' | 'json' | 'parquet'-export const FILE_UPLOAD_SOURCE_CONFIG: SourceConfig = {+export const FILE_UPLOAD_SOURCE_CONFIG: SourceConfigResponseApi = {name: FILE_UPLOAD_SOURCE_NAME,label: 'File upload',caption: 'Upload a CSV, JSON, or Parquet file to query it in the PostHog data warehouse.',@@ -21,6 +24,11 @@ export const FILE_UPLOAD_SOURCE_CONFIG: SourceConfig = {releaseStatus: 'alpha',// The upload form is bespoke (`FileUploadSourceForm`), so no generic connection fields.fields: [],+ // No vendor API sits behind an upload, so the version fields the response type requires stay empty.+ supportsColumnSelection: false,+ versions: [],+ defaultVersion: '',+ deprecatedVersions: [],}export const FILE_UPLOAD_FORMATS: { format: FileUploadFormat; label: string; keywords: string[] }[] = [diff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/sourceCatalogLogic.ts b/products/data_warehouse/frontend/scenes/NewSourceScene/sourceCatalogLogic.tsindex e006712ec315..fea52c15f510 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/sourceCatalogLogic.ts+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/sourceCatalogLogic.ts@@ -12,14 +12,14 @@ import { getSourceDisplayStatus } from 'scenes/data-pipelines/utils/nonHogFunctiimport { urls } from 'scenes/urls'import { userLogic } from 'scenes/userLogic'-import {- DataWarehouseSourceCategory,- ExternalDataSourceType,- SourceConfig,- dataWarehouseSourceCategories,-} from '~/queries/schema/schema-general'import { HogFunctionTemplateStatus } from '~/types'+import {+ DataWarehouseSourceCategoryApi,+ ExternalDataSourceTypeEnumApi,+ SourceConfigResponseApi,+} from 'products/warehouse_sources/frontend/generated/api.schemas'+import type { FeatureFlagsSet } from '../../../../../frontend/src/lib/logic/featureFlagLogic'import type { ManualLinkSourceType, UserType } from '../../../../../frontend/src/types'import { availableSourcesLogic } from './availableSourcesLogic'@@ -35,15 +35,15 @@ import { sourceWizardLogic } from './sourceWizardLogic'// Helps kea-typegen reference the Fuse type without a bad `import { Fuse } from 'fuse.js'`.export interface Fuse extends FuseClass<CatalogItem> {}-export type SourceCategoryFilter = DataWarehouseSourceCategory | 'all'+export type SourceCategoryFilter = DataWarehouseSourceCategoryApi | 'all'export const ALL_SOURCES_CATEGORY = 'all'-// Self-managed (S3/GCS/Azure/R2) connectors don't flow through SourceConfig, so place+// Self-managed (S3/GCS/Azure/R2) connectors don't flow through SourceConfigResponseApi, so place// them in a sensible catalog bucket explicitly.-const MANUAL_SOURCE_CATEGORY: DataWarehouseSourceCategory = 'File storage'+const MANUAL_SOURCE_CATEGORY: DataWarehouseSourceCategoryApi = 'File storage'-// Self-managed connectors carry no SourceConfig keywords, and their labels alone ("S3",+// Self-managed connectors carry no SourceConfigResponseApi keywords, and their labels alone ("S3",// "Google Cloud Storage") miss the terms users actually search ("amazon", "aws", "gcs").// Keys match ManualLinkSourceType.const MANUAL_SOURCE_KEYWORDS: Record<string, string[]> = {@@ -64,7 +64,7 @@ export const SOURCE_REQUEST_SURVEY_ID = '0190ff15-5032-0000-722a-e13933c140ac'export interface SourceCatalogLogicProps {/** When set, only managed sources whose name is in this list are shown. */- allowedSources?: ExternalDataSourceType[]+ allowedSources?: ExternalDataSourceTypeEnumApi[]}export interface CatalogItem {@@ -73,10 +73,10 @@ export interface CatalogItem {label: stringiconType: stringiconClassName?: string- category: DataWarehouseSourceCategory+ category: DataWarehouseSourceCategoryApikeywords: string[]status: HogFunctionTemplateStatus- releaseStatus?: SourceConfig['releaseStatus']+ releaseStatus?: SourceConfigResponseApi['releaseStatus']url: stringdisabledReason?: string | nullexistingSource?: boolean@@ -94,7 +94,7 @@ export interface CatalogCategory {// Generated by kea-typegen. Update if you're an agent, ignore if you're human.export interface sourceCatalogLogicValues {- availableSources: Record<string, SourceConfig> | null // availableSourcesLogic+ availableSources: Record<string, SourceConfigResponseApi> | null // availableSourcesLogicfeatureFlags: FeatureFlagsSet // featureFlagLogicmanualConnectors: {name: string@@ -144,1356 +144,13 @@ export interface sourceCatalogLogicActions {export interface sourceCatalogLogicMeta {__keaTypeGenInternalSelectorTypes: {catalogItems: (- availableSources: Record<string, SourceConfig> | null,+ availableSources: Record<string, SourceConfigResponseApi> | null,manualConnectors: {name: stringtype: ManualLinkSourceType}[],featureFlags: FeatureFlagsSet,- arg:- | (- | 'Ably'- | 'AbnormalSecurity'- | 'AbTasty'- | 'Acast'- | 'Acculynx'- | 'Actionstep'- | 'ActiveCampaign'- | 'AcuityScheduling'- | 'Adapty'- | 'Adjust'- | 'AdobeAnalytics'- | 'AdobeCommerce'- | 'AdpWorkforceNow'- | 'AdRoll'- | 'Adyen'- | 'Aftership'- | 'AgileCRM'- | 'Aha'- | 'AhaIdeas'- | 'Ahrefs'- | 'AikidoSecurity'- | 'Airbrake'- | 'Airbridge'- | 'Airbyte'- | 'Aircall'- | 'AirOps'- | 'Airtable'- | 'Airwallex'- | 'Aiven'- | 'AkamaiReporting'- | 'Akeneo'- | 'Alation'- | 'Alegra'- | 'Algolia'- | 'Alguna'- | 'Allegro'- | 'AlpacaBrokerAPI'- | 'AlphaVantage'- | 'AmazonAds'- | 'AmazonCloudWatch'- | 'AmazonEventBridge'- | 'AmazonKinesis'- | 'AmazonS3'- | 'AmazonSellingPartner'- | 'AmazonSNS'- | 'AmazonSQS'- | 'Amplemarket'- | 'Amplitude'- | 'AnodotCost'- | 'Anomalo'- | 'Anthropic'- | 'Anvil'- | 'Apaleo'- | 'ApifyDataset'- | 'Apitally'- | 'Apollo'- | 'Appcues'- | 'Appdirect'- | 'Appdynamics'- | 'Appfigures'- | 'Appfolio'- | 'Appfollow'- | 'AppleSearchAds'- | 'AppLovin'- | 'AppsFlyer'- | 'Appsignal'- | 'Appstack'- | 'AppStoreConnect'- | 'Apptivo'- | 'Appwrite'- | 'Argocd'- | 'Arxiv'- | 'Asaas'- | 'Asana'- | 'Ashby'- | 'Asknicely'- | 'AssemblyAI'- | 'Astronomer'- | 'Athenahealth'- | 'Atlan'- | 'Attentive'- | 'Attio'- | 'Auth0'- | 'AutodeskConstructionCloud'- | 'Automox'- | 'Autumn'- | 'Avalara'- | 'Aviationstack'- | 'Aviator'- | 'Awin'- | 'AwsAthena'- | 'AwsBatch'- | 'AwsBudgets'- | 'AwsCloudformation'- | 'AwsCloudTrail'- | 'AwsComputeOptimizer'- | 'AwsConfig'- | 'AwsConnect'- | 'AwsCostAndUsageReport'- | 'AwsCostAnomalyDetection'- | 'AwsCostExplorer'- | 'AwsGlueDataCatalog'- | 'AwsGuardduty'- | 'AwsHealth'- | 'AwsIamAccessAnalyzer'- | 'AwsInspector'- | 'AwsMacie'- | 'AwsOrganizations'- | 'AwsRdsPerformanceInsights'- | 'AwsSagemaker'- | 'AwsSavingsPlans'- | 'AwsSecurityHub'- | 'AwsSes'- | 'AwsStepFunctions'- | 'AwsSupport'- | 'AwsSystemsManager'- | 'AwsTrustedAdvisor'- | 'AwsWaf'- | 'AwsXray'- | 'Axiom'- | 'AzureActivityLog'- | 'AzureAdvisor'- | 'AzureApiManagement'- | 'AzureApplicationInsights'- | 'AzureBlob'- | 'AzureCostManagement'- | 'AzureDataExplorer'- | 'AzureDataFactory'- | 'AzureDevOps'- | 'AzureLogAnalytics'- | 'AzureMonitorAlerts'- | 'AzureMonitorMetrics'- | 'AzureOpenaiUsage'- | 'AzurePolicyInsights'- | 'AzureReservations'- | 'AzureResourceGraph'- | 'AzureResourceHealth'- | 'AzureServiceHealth'- | 'AzureSynapse'- | 'AzureTableStorage'- | 'Babelforce'- | 'Backblaze'- | 'BackMarket'- | 'BambooHR'- | 'Basecamp'- | 'Baserow'- | 'Baseten'- | 'BCMS'- | 'Beamer'- | 'Beehiiv'- | 'Bettermode'- | 'BetterStack'- | 'Bexio'- | 'BigCommerce'- | 'Bigeye'- | 'BigMailer'- | 'BigQuery'- | 'BillCom'- | 'Billit'- | 'Billomat'- | 'BingAds'- | 'BingWebmasterTools'- | 'Bitbucket'- | 'Bitly'- | 'Bitrise'- | 'Bitwarden'- | 'BlackbaudRaisersEdgeNxt'- | 'BlackboardLearn'- | 'BlandAI'- | 'Bling'- | 'Blogger'- | 'Bloomerang'- | 'Bluesky'- | 'Bluetally'- | 'BoldSign'- | 'BolRetailer'- | 'Boulevard'- | 'Box'- | 'Braintree'- | 'Braintrust'- | 'Branch'- | 'Braze'- | 'Breezometer'- | 'BreezyHR'- | 'Brevo'- | 'Brex'- | 'BrowseAI'- | 'Browserbase'- | 'BrowserUse'- | 'Buffer'- | 'Bugherd'- | 'Bugsnag'- | 'BuildBetter'- | 'Buildium'- | 'Buildkite'- | 'Bunny'- | 'Buttondown'- | 'BuyMeACoffee'- | 'Buzzsprout'- | 'CalCom'- | 'Calendarific'- | 'Calendly'- | 'Calibre'- | 'CallRail'- | 'CampaignManager360'- | 'CampaignMonitor'- | 'Campayn'- | 'Campfire'- | 'Canny'- | 'CanvasLms'- | 'CapsuleCRM'- | 'CaptainData'- | 'Capterra'- | 'Captivate'- | 'CareQualityCommission'- | 'CartCom'- | 'Cashfree'- | 'CastAi'- | 'CastorEDC'- | 'Catchpoint'- | 'CdcOpenData'- | 'Census'- | 'Chameleon'- | 'Chargebee'- | 'Chargedesk'- | 'Chargify'- | 'ChartHop'- | 'ChartMogul'- | 'Chatwoot'- | 'Checkly'- | 'Checkmarx'- | 'CheckoutCom'- | 'Chift'- | 'Chorus'- | 'Churnkey'- | 'Cimis'- | 'Cin7'- | 'CircleCI'- | 'CircleciInsights'- | 'CircleSo'- | 'CiscoDuo'- | 'CiscoMeraki'- | 'Clari'- | 'Clarifai'- | 'Clarify'- | 'Classy'- | 'Clay'- | 'Clazar'- | 'Cleartax'- | 'Clerk'- | 'Clever'- | 'Clevertap'- | 'ClickHouse'- | 'ClickhouseCloud'- | 'ClickUp'- | 'Cliniko'- | 'Clio'- | 'Clip'- | 'Clockify'- | 'Clockodo'- | 'Close'- | 'Cloudability'- | 'Cloudbeds'- | 'Cloudflare'- | 'Cloudinary'- | 'Cloudsmith'- | 'Cloudzero'- | 'Clover'- | 'Coassemble'- | 'CockroachDB'- | 'Coda'- | 'Codacy'- | 'Codecov'- | 'Codefresh'- | 'Codemagic'- | 'Codescene'- | 'Cody'- | 'Cohere'- | 'CoinApi'- | 'CoinGecko'- | 'CoinMarketCap'- | 'Collibra'- | 'Commercetools'- | 'CommissionJunction'- | 'Companycam'- | 'Concord'- | 'Conekta'- | 'ConfigCat'- | 'Confluence'- | 'ConfluentCloud'- | 'ConstantContact'- | 'ContaAzul'- | 'Contentsquare'- | 'ConvertKit'- | 'Convex'- | 'Convonite'- | 'Coolify'- | 'Copper'- | 'Coralogix'- | 'Cortex'- | 'CosmosDB'- | 'Couchbase'- | 'Coupa'- | 'Courier'- | 'Coveralls'- | 'CratesIO'- | 'Crisp'- | 'Criteo'- | 'Cronitor'- | 'Crossref'- | 'CrowdstrikeFalcon'- | 'Crunchbase'- | 'CubeCloud'- | 'CultureAmp'- | 'Cursor'- | 'Curve'- | 'Custom'- | 'CustomerIO'- | 'Customerly'- | 'Cybersource'- | 'D2lBrightspace'- | 'DagsterCloud'- | 'Databricks'- | 'Datadog'- | 'DataForSEO'- | 'Datahub'- | 'Datascope'- | 'DatoCMS'- | 'Datorama'- | 'Dayforce'- | 'Db2'- | 'Dbt'- | 'Debugbear'- | 'Decagon'- | 'Deel'- | 'DeelFlows'- | 'Deepgram'- | 'Deepsource'- | 'Demodesk'- | 'DenoDeploy'- | 'Depot'- | 'Deputy'- | 'Descope'- | 'Develocity'- | 'DevinAI'- | 'Dialpad'- | 'DigitalOcean'- | 'DingConnect'- | 'Directus'- | 'Discord'- | 'Discourse'- | 'DisplayVideo360'- | 'Dixa'- | 'Dockerhub'- | 'Docuseal'- | 'Docusign'- | 'DodoPayments'- | 'DoIt'- | 'Dokploy'- | 'Dolibarr'- | 'Donorbox'- | 'Doorloop'- | 'Doppler'- | 'Dovetail'- | 'Drata'- | 'Drchrono'- | 'Dremio'- | 'Drip'- | 'Dropbox'- | 'DropboxSign'- | 'Dub'- | 'Dubsado'- | 'DuckLake'- | 'Dwolla'- | 'Dynamics365'- | 'Dynamics365BusinessCentral'- | 'DynamoDB'- | 'Dynatrace'- | 'E2B'- | 'Easybill'- | 'Easypost'- | 'Easypromos'- | 'Ebay'- | 'EcbDataPortal'- | 'EConomic'- | 'Elasticemail'- | 'Elasticsearch'- | 'ElectricityMaps'- | 'ElevenLabs'- | 'Eloqua'- | 'EmailOctopus'- | 'Emarsys'- | 'Embrace'- | 'EmploymentHero'- | 'Encharge'- | 'Entsoe'- | 'Env0'- | 'Eppo'- | 'Etsy'- | 'Eurostat'- | 'Eventbrite'- | 'Eventee'- | 'Eventzilla'- | 'Everhour'- | 'ExchangeRatesApi'- | 'Expensify'- | 'EZOfficeInventory'- | 'FacebookPages'- | 'Factorial'- | 'Faire'- | 'FarosAi'- | 'Fastbill'- | 'Fastly'- | 'Fauna'- | 'Featurebase'- | 'Feishu'- | 'Fieldpulse'- | 'Fieldwire'- | 'Filevine'- | 'Fillout'- | 'Finage'- | 'FinancialModelling'- | 'Finnhub'- | 'Finnworlds'- | 'Finout'- | 'Fintoc'- | 'Firebase'- | 'Firebolt'- | 'Firecrawl'- | 'FireHydrant'- | 'FireworksAI'- | 'FirstPromoter'- | 'Five9'- | 'Flagsmith'- | 'Fleetio'- | 'FlexeraCloudCost'- | 'Flexmail'- | 'Flexport'- | 'FloatApp'- | 'Flowlu'- | 'Flutterwave'- | 'FlyIo'- | 'Folk'- | 'Formbricks'- | 'Fortnox'- | 'Fourthwall'- | 'Framer'- | 'Fred'- | 'FreeAgent'- | 'Freightview'- | 'FreshBooks'- | 'Freshcaller'- | 'Freshchat'- | 'Freshdesk'- | 'Freshsales'- | 'Freshservice'- | 'Frill'- | 'Front'- | 'Frontegg'- | 'Fulcrum'- | 'FullStory'- | 'FusionAuth'- | 'G2'- | 'GainsightCs'- | 'GainsightPx'- | 'Gcore'- | 'GcpApigee'- | 'GcpArtifactRegistry'- | 'GcpBigtable'- | 'GcpChronicle'- | 'GcpCloudAssetInventory'- | 'GcpCloudBilling'- | 'GcpCloudBuild'- | 'GcpCloudDeploy'- | 'GcpCloudDns'- | 'GcpCloudFunctions'- | 'GcpCloudLogging'- | 'GcpCloudMonitoring'- | 'GcpCloudRun'- | 'GcpCloudSpanner'- | 'GcpCloudSql'- | 'GcpCloudTrace'- | 'GcpCloudWorkflows'- | 'GcpComputeEngine'- | 'GcpContainerAnalysis'- | 'GcpDataflow'- | 'GcpDataplex'- | 'GcpDataproc'- | 'GcpErrorReporting'- | 'GcpGke'- | 'GcpPubsub'- | 'GcpRecaptchaEnterprise'- | 'GcpRecommender'- | 'GcpSecurityCommandCenter'- | 'Gdelt'- | 'GenesysCloud'- | 'Gerrit'- | 'Getdx'- | 'GetStream'- | 'Ghost'- | 'Giphy'- | 'GitBook'- | 'Gitea'- | 'Gitguardian'- | 'Github'- | 'GitLab'- | 'Givebutter'- | 'Gladly'- | 'Glassfrog'- | 'Gleif'- | 'Gmail'- | 'GNews'- | 'GoCardless'- | 'Gojiberry'- | 'Goldcast'- | 'GoLogin'- | 'Gong'- | 'GoogleAdManager'- | 'GoogleAds'- | 'GoogleAdSense'- | 'GoogleAnalytics'- | 'GoogleCalendar'- | 'GoogleChat'- | 'GoogleClassroom'- | 'GoogleCloudStorage'- | 'GoogleDirectory'- | 'GoogleDrive'- | 'GoogleForms'- | 'GoogleMerchantCenter'- | 'GooglePageSpeedInsights'- | 'GooglePlayConsole'- | 'GooglePostmasterTools'- | 'GoogleSearchConsole'- | 'GoogleSheets'- | 'GoogleTasks'- | 'GoogleWebfonts'- | 'GoogleWorkspaceAdminReports'- | 'Gorgias'- | 'Grafana'- | 'Granola'- | 'Greenhouse'- | 'GreytHr'- | 'Gridly'- | 'Groq'- | 'Growi'- | 'GrowthBook'- | 'Guardian'- | 'Guesty'- | 'Gumloop'- | 'Gumroad'- | 'Guru'- | 'Gusto'- | 'Harness'- | 'HarnessCcm'- | 'HarnessSei'- | 'Harvest'- | 'Harvey'- | 'Hatchet'- | 'Healthchecks'- | 'Healthie'- | 'Heap'- | 'Height'- | 'Helicone'- | 'Hellobaton'- | 'HelpScout'- | 'Heroku'- | 'Hetzner'- | 'Hex'- | 'HeyGen'- | 'HiBob'- | 'HighLevel'- | 'Hightouch'- | 'Hitpay'- | 'Hivebrite'- | 'Holded'- | 'Honeybadger'- | 'Honeycomb'- | 'Hookdeck'- | 'HoorayHR'- | 'Hootsuite'- | 'Hostaway'- | 'HousecallPro'- | 'Hubplanner'- | 'Hubspot'- | 'HuggingFace'- | 'Humanitec'- | 'Humanitix'- | 'Huntr'- | 'Hyperspell'- | 'Hyros'- | 'Ikas'- | 'IlluminaBasespace'- | 'Imagga'- | 'ImfData'- | 'Impact'- | 'ImpactPartner'- | 'Imperva'- | 'IncidentIo'- | 'Infisical'- | 'Inflowinventory'- | 'InfluxdbCloud'- | 'InforNexus'- | 'Inngest'- | 'Insightful'- | 'Insightly'- | 'Instagram'- | 'Instana'- | 'Instantly'- | 'Instatus'- | 'Intercom'- | 'Interzoid'- | 'Inth'- | 'Intruder'- | 'Invoiced'- | 'Invoiceninja'- | 'IP2Whois'- | 'IronSourceAds'- | 'Iterable'- | 'Iyzico'- | 'JamfPro'- | 'Jellyfish'- | 'Jenkins'- | 'JfrogArtifactory'- | 'Jira'- | 'Jobber'- | 'JobNimbus'- | 'Jobtread'- | 'Jotform'- | 'JudgeMeReviews'- | 'Jumpcloud'- | 'JustCall'- | 'JustSift'- | 'K6Cloud'- | 'Kafka'- | 'Kajabi'- | 'Kalshi'- | 'Kameleoon'- | 'Kandji'- | 'KapaAI'- | 'Katana'- | 'KauflandMarketplace'- | 'Keka'- | 'Kernel'- | 'Kestra'- | 'Kick'- | 'Kickscale'- | 'Kickstarter'- | 'Kinde'- | 'Kion'- | 'Kisi'- | 'Kissmetrics'- | 'Klarna'- | 'Klaus'- | 'Klaviyo'- | 'Knock'- | 'Knowbe4'- | 'Kommo'- | 'Komodor'- | 'KongKonnect'- | 'Koyeb'- | 'Kubecost'- | 'Kustomer'- | 'KYVE'- | 'Labelbox'- | 'Lacework'- | 'Lago'- | 'LambdaLabs'- | 'Langfuse'- | 'LangSmith'- | 'Latitude'- | 'Lattice'- | 'LaunchDarkly'- | 'Lawmatics'- | 'Leadfeeder'- | 'Learnworlds'- | 'Leexi'- | 'Lemlist'- | 'LemonSqueezy'- | 'LessAnnoyingCRM'- | 'Lever'- | 'LexwareOffice'- | 'Liana'- | 'Lightdash'- | 'Lightfield'- | 'LightspeedRetail'- | 'Linear'- | 'Linearb'- | 'LingoDev'- | 'LinkedinAds'- | 'LinkedinPages'- | 'Linkrunner'- | 'Linnworks'- | 'Linode'- | 'Liveblocks'- | 'LlamaCloud'- | 'Lob'- | 'Lodgify'- | 'Logicmonitor'- | 'Logrocket'- | 'LogzIO'- | 'Lokalise'- | 'Looker'- | 'LoopReturns'- | 'Loops'- | 'Lovable'- | 'Luma'- | 'M3ter'- | 'Mailchimp'- | 'MailerLite'- | 'MailerSend'- | 'Mailgun'- | 'Mailjet'- | 'Mailosaur'- | 'Mailtrap'- | 'Mantle'- | 'Manychat'- | 'Marketo'- | 'Marketstack'- | 'Mastodon'- | 'Matomo'- | 'Maxio'- | 'Medusa'- | 'Meetup'- | 'Meltwater'- | 'Mem0'- | 'Memberful'- | 'Membrain'- | 'Mendeley'- | 'Mention'- | 'MercadoAds'- | 'MercadoPago'- | 'Mercury'- | 'Merge'- | 'MetaAds'- | 'Metabase'- | 'Metaplane'- | 'Meteostat'- | 'Metorial'- | 'Metricool'- | 'Metriport'- | 'Metronome'- | 'Mews'- | 'Mezmo'- | 'Microsoft365UsageReports'- | 'MicrosoftAdvertising'- | 'MicrosoftClarity'- | 'MicrosoftDataverse'- | 'MicrosoftDefenderCloudApps'- | 'MicrosoftDefenderEndpoint'- | 'MicrosoftDefenderForCloud'- | 'MicrosoftEntraId'- | 'MicrosoftExcel'- | 'MicrosoftIntune'- | 'MicrosoftLists'- | 'MicrosoftPurview'- | 'MicrosoftPurviewAudit'- | 'MicrosoftSentinel'- | 'MicrosoftTeams'- | 'MicrosoftTeamsCallRecords'- | 'Midtrans'- | 'MightyNetworks'- | 'Mindbody'- | 'Mintlify'- | 'Mirakl'- | 'Miro'- | 'Missive'- | 'MistralAI'- | 'MixMax'- | 'Mixpanel'- | 'Mode'- | 'Moesif'- | 'Mollie'- | 'Monday'- | 'Moneybird'- | 'MongoDB'- | 'Mono'- | 'MonteCarlo'- | 'Moodle'- | 'Motherduck'- | 'Motion'- | 'Moxie'- | 'MSG91'- | 'MSSQL'- | 'Mux'- | 'Mycase'- | 'MyHours'- | 'MySQL'- | 'N8n'- | 'NagerDate'- | 'Nasa'- | 'NationBuilder'- | 'Navan'- | 'NebiusAI'- | 'Neon'- | 'NeonCrm'- | 'Netlify'- | 'NetSuite'- | 'NewRelic'- | 'NewsApi'- | 'NewsData'- | 'NewYorkTimes'- | 'Nexhealth'- | 'Nexiopay'- | 'NextdoorAds'- | 'NinjaOneRMM'- | 'NoaaCdo'- | 'Nobl9'- | 'NoCRM'- | 'Nolt'- | 'Nops'- | 'Northflank'- | 'NorthpassLMS'- | 'Notion'- | 'NpmRegistry'- | 'Nuget'- | 'Nuntly'- | 'Nutshell'- | 'Nylas'- | 'Octolens'- | 'OctopusDeploy'- | 'Odoo'- | 'Oecd'- | 'Okendo'- | 'Okta'- | 'Omni'- | 'Omnisend'- | 'Oncehub'- | 'OneDrive'- | 'OneHundredMs'- | 'Onelogin'- | 'Onepagecrm'- | 'OnePassword'- | 'OneSignal'- | 'Onfleet'- | 'OpenAI'- | 'OpenAIAds'- | 'Openalex'- | 'OpenAQ'- | 'Opencorporates'- | 'OpenDataDc'- | 'OpenDental'- | 'OpenExchangeRates'- | 'OpenFDA'- | 'Openfec'- | 'OpenMeteo'- | 'OpenRouter'- | 'OpenWeather'- | 'OpinionStage'- | 'OpnPayments'- | 'Opsgenie'- | 'Opslevel'- | 'Optimizely'- | 'OPUSWatch'- | 'Oracle'- | 'OracleEbs'- | 'OracleFusion'- | 'Orb'- | 'Orbit'- | 'OrcaSecurity'- | 'Ortto'- | 'OttoMarket'- | 'Oura'- | 'Outbrain'- | 'Outlook'- | 'Outreach'- | 'Oveit'- | 'Ownerrez'- | 'PabblySubscriptionsBilling'- | 'Packagist'- | 'Paddle'- | 'Pagbank'- | 'PagerDuty'- | 'PandaDoc'- | 'Paperform'- | 'Papersign'- | 'Pardot'- | 'Partnerize'- | 'PartnerStack'- | 'Patreon'- | 'Pax8'- | 'Paychex'- | 'PayFit'- | 'Paylocity'- | 'Paymob'- | 'Paymongo'- | 'PayPal'- | 'Paystack'- | 'PeecAI'- | 'Pendo'- | 'Pennylane'- | 'Perigon'- | 'Perk'- | 'PersistIq'- | 'Persona'- | 'Personio'- | 'Pexels'- | 'PgAnalyze'- | 'Phonepe'- | 'Phyllo'- | 'Picqer'- | 'Pike13'- | 'Pinecone'- | 'Pingdom'- | 'Pingone'- | 'PinterestAds'- | 'PinterestOrganic'- | 'Pipedrive'- | 'Pipeliner'- | 'PivotalTracker'- | 'Piwik'- | 'Plaid'- | 'Plain'- | 'PlanetScaleMySQL'- | 'PlanetScalePostgres'- | 'Planhat'- | 'PlanningCenter'- | 'PlatformSh'- | 'Plausible'- | 'Plivo'- | 'Plunk'- | 'PluralsightFlow'- | 'Pocket'- | 'Podbean'- | 'Podium'- | 'Polar'- | 'Polygon'- | 'Polymarket'- | 'Poplar'- | 'Postgres'- | 'Postmark'- | 'Postscript'- | 'PowerBiAdmin'- | 'Practicepanther'- | 'PrefectCloud'- | 'Preset'- | 'PrestaShop'- | 'Pretix'- | 'Primetric'- | 'Printavo'- | 'Printify'- | 'Procore'- | 'Productboard'- | 'Productiv'- | 'Productive'- | 'Profound'- | 'PromptingCompany'- | 'PromptWatch'- | 'ProofpointTap'- | 'Propertyware'- | 'Pubnub'- | 'PulumiCloud'- | 'Pylon'- | 'PyPI'- | 'Qdrant'- | 'Qonto'- | 'Qualaroo'- | 'Qualtrics'- | 'QualysVmdr'- | 'Quay'- | 'QuickBooks'- | 'Railway'- | 'Railz'- | 'Raisely'- | 'Raken'- | 'RakutenAdvertising'- | 'Ramp'- | 'Rapid7Insightvm'- | 'Raygun'- | 'Razorpay'- | 'RB2B'- | 'RDStationMarketing'- | 'RecallAI'- | 'Recharge'- | 'Recreation'- | 'Recruitee'- | 'Recurly'- | 'Reddit'- | 'RedditAds'- | 'Redis'- | 'RedpandaCloud'- | 'Redshift'- | 'ReferralHero'- | 'Render'- | 'RentCast'- | 'RentManager'- | 'Repairshopr'- | 'Replicate'- | 'ReplyIo'- | 'Resend'- | 'RetailExpress'- | 'RetellAI'- | 'Retently'- | 'RevenueCat'- | 'Reverb'- | 'RevolutMerchant'- | 'RingCentral'- | 'Rippling'- | 'RKICovid'- | 'Roark'- | 'RocketChat'- | 'Rocketlane'- | 'RocketMatter'- | 'RoktAds'- | 'Rollbar'- | 'Rootly'- | 'Rss'- | 'Rubygems'- | 'RudderStack'- | 'Ruddr'- | 'RunPod'- | 'SafetyCulture'- | 'SageHR'- | 'SageIntacct'- | 'Sailthru'- | 'Salesflare'- | 'Salesforce'- | 'SalesforceMarketingCloud'- | 'SalesLoft'- | 'Salestrics'- | 'SamCart'- | 'Sanity'- | 'SapConcur'- | 'SapErp'- | 'SAPFieldglass'- | 'SapHana'- | 'SapSuccessFactors'- | 'SavvyCal'- | 'ScaleAI'- | 'Scaleway'- | 'Scalr'- | 'Schematic'- | 'SearchAds360'- | 'SecEdgar'- | 'Secoda'- | 'Secureframe'- | 'Segment'- | 'SelectStar'- | 'SemanticScholar'- | 'Semaphore'- | 'Semgrep'- | 'Semrush'- | 'SendGrid'- | 'Sendowl'- | 'SendPulse'- | 'Senseforce'- | 'Sentinelone'- | 'Sentry'- | 'Sequenzy'- | 'Serpstat'- | 'ServiceFusion'- | 'Servicem8'- | 'ServiceNow'- | 'Servicetitan'- | 'Servicetrade'- | 'Sevalla'- | 'Sevdesk'- | 'SevenShifts'- | 'SFTP'- | 'SharePoint'- | 'Sharetribe'- | 'Shipmail'- | 'Shippo'- | 'ShipStation'- | 'Shopify'- | 'Shopware'- | 'ShopWired'- | 'Shortcut'- | 'Shortio'- | 'Shutterstock'- | 'SideShift'- | 'SigmaComputing'- | 'SignNow'- | 'SigNoz'- | 'Sim'- | 'SimFin'- | 'Similarweb'- | 'SimonData'- | 'SimpleCast'- | 'Simplesat'- | 'Simpro'- | 'Sinch'- | 'Singlestore'- | 'Singular'- | 'Site24x7'- | 'Skio'- | 'Skyvern'- | 'Slack'- | 'Slash'- | 'Sleekplan'- | 'Sleuth'- | 'Smaily'- | 'SmartEngage'- | 'Smartlead'- | 'Smartlook'- | 'Smartreach'- | 'Smartrecruiters'- | 'Smartsheet'- | 'Smartwaiver'- | 'Smokeball'- | 'SnapchatAds'- | 'Snovio'- | 'Snowflake'- | 'Snowplow'- | 'Snyk'- | 'SocialPilot'- | 'SodaCloud'- | 'SolarwindsServiceDesk'- | 'SonarCloud'- | 'Sonarqube'- | 'SonatypeNexus'- | 'Sourcegraph'- | 'Spacelift'- | 'SparkPost'- | 'Speedcurve'- | 'SplitIo'- | 'SplunkObservabilityCloud'- | 'SpotifyAds'- | 'SpotIo'- | 'SpotlerCRM'- | 'Sprig'- | 'Sprinklr'- | 'SproutSocial'- | 'Squadcast'- | 'Square'- | 'Squarespace'- | 'StackOverflowForTeams'- | 'Starburst'- | 'Statsig'- | 'Statuscake'- | 'Statuspage'- | 'Stigg'- | 'StockData'- | 'Stockx'- | 'Strato'- | 'Strava'- | 'StreamElements'- | 'Streamlabs'- | 'Stripe'- | 'Stytch'- | 'Substack'- | 'SumoLogic'- | 'Sumsub'- | 'Supabase'- | 'Superwall'- | 'SurveyMonkey'- | 'SurveySparrow'- | 'Survicate'- | 'Svix'- | 'Swan'- | 'Swarmia'- | 'Swonkie'- | 'Synthesia'- | 'Systeme'- | 'Taboola'- | 'TackleIo'- | 'Tailscale'- | 'Talkdesk'- | 'Talkwalker'- | 'Tally'- | 'Tana'- | 'Tavus'- | 'TawkTo'- | 'Teachable'- | 'Teamcity'- | 'Teamtailor'- | 'TeamupFitness'- | 'Teamwork'- | 'Tebra'- | 'Telli'- | 'Telnyx'- | 'Tempo'- | 'TemporalIO'- | 'TenableVulnerabilityManagement'- | 'Tenjin'- | 'TeraBox'- | 'Ternary'- | 'TerraApi'- | 'TerraformCloud'- | 'Testrail'- | 'Thinkific'- | 'ThinkificCourses'- | 'Thoughtspot'- | 'Thousandeyes'- | 'Threads'- | 'ThriveLearning'- | 'Ticketmaster'- | 'TicketTailor'- | 'TickTick'- | 'TikTokAds'- | 'TiktokShop'- | 'Tile38'- | 'Timely'- | 'Tinybird'- | 'Tinyemail'- | 'TinyErp'- | 'Tipalti'- | 'TMDb'- | 'Toast'- | 'Todoist'- | 'TogetherAI'- | 'Toggl'- | 'Torii'- | 'TrackPMS'- | 'TradableBits'- | 'Transistor'- | 'TravisCI'- | 'Trello'- | 'Tremendous'- | 'TriggerDev'- | 'Trino'- | 'TripleWhale'- | 'TrunkIo'- | 'TrustPilot'- | 'Trustradius'- | 'Turso'- | 'TVMaze'- | 'TwelveData'- | 'TwelveLabs'- | 'Twenty'- | 'Twilio'- | 'Twitch'- | 'Twitter'- | 'TwitterAds'- | 'TwoC2p'- | 'TyntecSMS'- | 'Typeform'- | 'Typesense'- | 'Ubidots'- | 'UkCompaniesHouse'- | 'UkOns'- | 'Umami'- | 'UnComtrade'- | 'Unleash'- | 'Unstructured'- | 'Uploadcare'- | 'UpPromote'- | 'Upstash'- | 'Uptick'- | 'Uptimerobot'- | 'UsBea'- | 'UsBls'- | 'USCensus'- | 'UsEia'- | 'UserCom'- | 'Usersnap'- | 'Uservoice'- | 'UsTreasuryFiscalData'- | 'Vanta'- | 'Vantage'- | 'Vapi'- | 'Veeqo'- | 'Vellum'- | 'Vendr'- | 'Veracode'- | 'Vercel'- | 'Vespa'- | 'Virtuous'- | 'VismaEconomic'- | 'Vitally'- | 'Vonage'- | 'Vturb'- | 'Vultr'- | 'VWO'- | 'Waiteraid'- | 'WalmartMarketplace'- | 'Wasabi'- | 'Watchmode'- | 'Waydev'- | 'Wayfair'- | 'Webflow'- | 'WeightsAndBiases'- | 'WhatsappBusinessManagement'- | 'WhenIWork'- | 'WHMCS'- | 'WhoGho'- | 'Whop'- | 'WikipediaPageviews'- | 'Windmill'- | 'WindsorAi'- | 'WisprFlow'- | 'Wix'- | 'Wiz'- | 'Wompi'- | 'WooCommerce'- | 'Wordpress'- | 'Workable'- | 'Workato'- | 'Workday'- | 'Workflowmax'- | 'Workiz'- | 'WorkOS'- | 'Workramp'- | 'WorldBank'- | 'WPSOffice'- | 'Wrike'- | 'Writesonic'- | 'Wufoo'- | 'Xendit'- | 'Xero'- | 'Xmatters'- | 'Xsolla'- | 'YahooFinance'- | 'YandexMetrica'- | 'Ynab'- | 'Yoco'- | 'Yotpo'- | 'Younium'- | 'YouSign'- | 'YouTubeAnalytics'- | 'YoutubeData'- | 'ZalandoZdirect'- | 'ZapierSupportedStorage'- | 'ZapSign'- | 'Zellify'- | 'Zenchef'- | 'Zendesk'- | 'ZendeskSell'- | 'ZendeskSunshine'- | 'Zenduty'- | 'Zenefits'- | 'Zenloop'- | 'Zep'- | 'Zero'- | 'Zitadel'- | 'Zluri'- | 'ZohoAnalytics'- | 'ZohoBigin'- | 'ZohoBilling'- | 'ZohoBooks'- | 'ZohoCampaign'- | 'ZohoCRM'- | 'ZohoDesk'- | 'ZohoExpense'- | 'ZohoInventory'- | 'ZohoInvoice'- | 'ZonkaFeedback'- | 'Zoom'- | 'ZoomInfo'- | 'Zuora'- | 'Zylo'- )[]- | undefined+ arg: ExternalDataSourceTypeEnumApi[] | undefined) => CatalogItem[]categoriesWithCounts: (catalogItems: CatalogItem[]) => CatalogCategory[]catalogFuse: (catalogItems: CatalogItem[]) => Fuse@@ -1576,17 +233,17 @@ export const sourceCatalogLogic = kea<sourceCatalogLogicType>([(_, p: SourceCatalogLogicProps) => p.allowedSources,],(- availableSources: Record<string, SourceConfig> | null,+ availableSources: Record<string, SourceConfigResponseApi> | null,manualConnectors: {name: stringtype: import('~/types').ManualLinkSourceType}[],featureFlags: import('lib/logic/featureFlagLogic').FeatureFlagsSet,- allowedSources: ExternalDataSourceType[] | undefined+ allowedSources: ExternalDataSourceTypeEnumApi[] | undefined): CatalogItem[] => {const managed = Object.values(availableSources ?? {}).filter((c) => !allowedSources || allowedSources.includes(c.name))- .flatMap((connector: SourceConfig): CatalogItem[] => {+ .flatMap((connector: SourceConfigResponseApi): CatalogItem[] => {// Mirror nonHogFunctionTemplatesLogic: a declared-but-absent flag reads as// off (featureFlagLogic only exposes truthy flags), so flag-gated sources// render as coming-soon ("Notify me") until the user is in the rollout.@@ -1603,16 +260,16 @@ export const sourceCatalogLogic = kea<sourceCatalogLogicType>([return [{iconType: connector.name,- iconClassName: connector.iconClassName,+ iconClassName: connector.iconClassName ?? undefined,category: connector.category ?? MANUAL_SOURCE_CATEGORY,status,releaseStatus,disabledReason: connector.disabledReason,- existingSource: connector.existingSource,+ existingSource: connector.existingSource ?? undefined,name: connector.name,label: connector.label ?? connector.name,keywords: connector.keywords ?? [],- featured: connector.featured,+ featured: connector.featured ?? undefined,url: urls.dataWarehouseSourceNew(connector.name),},]@@ -1659,11 +316,11 @@ export const sourceCatalogLogic = kea<sourceCatalogLogicType>([categoriesWithCounts: [(s) => [s.catalogItems],(catalogItems: CatalogItem[]): CatalogCategory[] => {- const counts = new Map<DataWarehouseSourceCategory, number>()+ const counts = new Map<DataWarehouseSourceCategoryApi, number>()for (const item of catalogItems) {counts.set(item.category, (counts.get(item.category) ?? 0) + 1)}- const present = dataWarehouseSourceCategories+ const present = Object.values(DataWarehouseSourceCategoryApi).filter((category) => counts.has(category)).map((category): CatalogCategory => ({diff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic.tsx b/products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic.tsxindex de078b643c3c..8f7c702bb7c3 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic.tsx+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic.tsx@@ -21,17 +21,7 @@ import {VALID_SELF_MANAGED_MARKETING_SOURCES,} from 'scenes/web-analytics/tabs/marketing-analytics/frontend/logic/utils'-import {- ExternalDataSourceType,- ProductIntentContext,- ProductKey,- SourceConfig,- SourceFieldConfig,- SourceFieldSwitchGroupConfig,- SuggestedTable,- VALID_NATIVE_MARKETING_SOURCES,- externalDataSources,-} from '~/queries/schema/schema-general'+import { ProductIntentContext, ProductKey, VALID_NATIVE_MARKETING_SOURCES } from '~/queries/schema/schema-general'import {Breadcrumb,ExternalDataSourceCreatePayload,@@ -42,6 +32,14 @@ import {RowFilter,} from '~/types'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'+import {+ ExternalDataSourceTypeEnumApi,+ SourceConfigResponseApi,+ SourceFieldSwitchGroupConfigApi,+ SuggestedTableApi,+} from 'products/warehouse_sources/frontend/generated/api.schemas'+import type { AvailableSetupTaskIdsEnumApi } from '../../../../../frontend/src/generated/core/api.schemas'import type { PaginatedResponse } from '../../../../../frontend/src/lib/api'import type { FeatureFlagsSet } from '../../../../../frontend/src/lib/logic/featureFlagLogic'@@ -60,7 +58,7 @@ import { FILE_UPLOAD_SOURCE_CONFIG, FILE_UPLOAD_SOURCE_NAME } from './fileUploadimport { selfManagedSourceLogic } from './selfManagedSourceLogic'import { restoreSourceFormState, saveSourceFormState } from './wizardFormStorage'-export const SSH_FIELD: SourceFieldSwitchGroupConfig = {+export const SSH_FIELD: SourceFieldSwitchGroupConfigApi = {name: 'ssh_tunnel',label: 'Use SSH tunnel?',type: 'switch-group',@@ -155,7 +153,7 @@ export const SSH_FIELD: SourceFieldSwitchGroupConfig = {}export const buildKeaFormDefaultFromSourceDetails = (- sourceDetails: Record<string, SourceConfig>+ sourceDetails: Record<string, SourceConfigResponseApi>): Record<string, any> => {if (!sourceDetails) {return {}@@ -233,8 +231,8 @@ export function mergeRestoredSourceFormValues(export function shouldHydrateSourceFromUrl(currentStep: number,- selectedConnector: SourceConfig | null,- source: SourceConfig,+ selectedConnector: SourceConfigResponseApi | null,+ source: SourceConfigResponseApi,currentAccessMethod: 'warehouse' | 'direct',urlAccessMethod: 'warehouse' | 'direct'): boolean {@@ -395,7 +393,7 @@ function syncExpandedSchemaGroupKeys(export interface SourceWizardLogicProps {onComplete?: () => void- availableSources: Record<string, SourceConfig>+ availableSources: Record<string, SourceConfigResponseApi>/** When set, only these tables will be pre-selected and they cannot be deselected */requiredTables?: string[]/** Onboarding: pre-select every syncable table with smart defaults for a one-click sync */@@ -425,7 +423,7 @@ export interface sourceWizardLogicValues {} | nullcdcSelfManagedVerifyResultLoading: booleanconfiguredSchemaName: string | null- connectors: SourceConfig[]+ connectors: SourceConfigResponseApi[]currentStep: numbercurrentSyncMethodModalSchema: ExternalDataSourceSyncSchema | nulldatabaseSchema: ExternalDataSourceSyncSchema[]@@ -471,9 +469,9 @@ export interface sourceWizardLogicValues {schemaGroupKeys: string[]schemaGroupKeysFingerprint: stringschemaNameFilter: string- selectedConnector: SourceConfig | null+ selectedConnector: SourceConfigResponseApi | nullshowDestinationStep: boolean- showFooter: boolean | SourceConfig+ showFooter: boolean | SourceConfigResponseApishowSkipButton: booleanshowSourceConnectionDetailsErrors: booleanshowWebhookFieldInputsErrors: boolean@@ -622,1351 +620,11 @@ export interface sourceWizardLogicActions {value: true}handleRedirect: (- source: ExternalDataSourceType,+ source: ExternalDataSourceTypeEnumApi,searchParams?: any) => {searchParams: any- source:- | 'Ably'- | 'AbnormalSecurity'- | 'AbTasty'- | 'Acast'- | 'Acculynx'- | 'Actionstep'- | 'ActiveCampaign'- | 'AcuityScheduling'- | 'Adapty'- | 'Adjust'- | 'AdobeAnalytics'- | 'AdobeCommerce'- | 'AdpWorkforceNow'- | 'AdRoll'- | 'Adyen'- | 'Aftership'- | 'AgileCRM'- | 'Aha'- | 'AhaIdeas'- | 'Ahrefs'- | 'AikidoSecurity'- | 'Airbrake'- | 'Airbridge'- | 'Airbyte'- | 'Aircall'- | 'AirOps'- | 'Airtable'- | 'Airwallex'- | 'Aiven'- | 'AkamaiReporting'- | 'Akeneo'- | 'Alation'- | 'Alegra'- | 'Algolia'- | 'Alguna'- | 'Allegro'- | 'AlpacaBrokerAPI'- | 'AlphaVantage'- | 'AmazonAds'- | 'AmazonCloudWatch'- | 'AmazonEventBridge'- | 'AmazonKinesis'- | 'AmazonS3'- | 'AmazonSellingPartner'- | 'AmazonSNS'- | 'AmazonSQS'- | 'Amplemarket'- | 'Amplitude'- | 'AnodotCost'- | 'Anomalo'- | 'Anthropic'- | 'Anvil'- | 'Apaleo'- | 'ApifyDataset'- | 'Apitally'- | 'Apollo'- | 'Appcues'- | 'Appdirect'- | 'Appdynamics'- | 'Appfigures'- | 'Appfolio'- | 'Appfollow'- | 'AppleSearchAds'- | 'AppLovin'- | 'AppsFlyer'- | 'Appsignal'- | 'Appstack'- | 'AppStoreConnect'- | 'Apptivo'- | 'Appwrite'- | 'Argocd'- | 'Arxiv'- | 'Asaas'- | 'Asana'- | 'Ashby'- | 'Asknicely'- | 'AssemblyAI'- | 'Astronomer'- | 'Athenahealth'- | 'Atlan'- | 'Attentive'- | 'Attio'- | 'Auth0'- | 'AutodeskConstructionCloud'- | 'Automox'- | 'Autumn'- | 'Avalara'- | 'Aviationstack'- | 'Aviator'- | 'Awin'- | 'AwsAthena'- | 'AwsBatch'- | 'AwsBudgets'- | 'AwsCloudformation'- | 'AwsCloudTrail'- | 'AwsComputeOptimizer'- | 'AwsConfig'- | 'AwsConnect'- | 'AwsCostAndUsageReport'- | 'AwsCostAnomalyDetection'- | 'AwsCostExplorer'- | 'AwsGlueDataCatalog'- | 'AwsGuardduty'- | 'AwsHealth'- | 'AwsIamAccessAnalyzer'- | 'AwsInspector'- | 'AwsMacie'- | 'AwsOrganizations'- | 'AwsRdsPerformanceInsights'- | 'AwsSagemaker'- | 'AwsSavingsPlans'- | 'AwsSecurityHub'- | 'AwsSes'- | 'AwsStepFunctions'- | 'AwsSupport'- | 'AwsSystemsManager'- | 'AwsTrustedAdvisor'- | 'AwsWaf'- | 'AwsXray'- | 'Axiom'- | 'AzureActivityLog'- | 'AzureAdvisor'- | 'AzureApiManagement'- | 'AzureApplicationInsights'- | 'AzureBlob'- | 'AzureCostManagement'- | 'AzureDataExplorer'- | 'AzureDataFactory'- | 'AzureDevOps'- | 'AzureLogAnalytics'- | 'AzureMonitorAlerts'- | 'AzureMonitorMetrics'- | 'AzureOpenaiUsage'- | 'AzurePolicyInsights'- | 'AzureReservations'- | 'AzureResourceGraph'- | 'AzureResourceHealth'- | 'AzureServiceHealth'- | 'AzureSynapse'- | 'AzureTableStorage'- | 'Babelforce'- | 'Backblaze'- | 'BackMarket'- | 'BambooHR'- | 'Basecamp'- | 'Baserow'- | 'Baseten'- | 'BCMS'- | 'Beamer'- | 'Beehiiv'- | 'Bettermode'- | 'BetterStack'- | 'Bexio'- | 'BigCommerce'- | 'Bigeye'- | 'BigMailer'- | 'BigQuery'- | 'BillCom'- | 'Billit'- | 'Billomat'- | 'BingAds'- | 'BingWebmasterTools'- | 'Bitbucket'- | 'Bitly'- | 'Bitrise'- | 'Bitwarden'- | 'BlackbaudRaisersEdgeNxt'- | 'BlackboardLearn'- | 'BlandAI'- | 'Bling'- | 'Blogger'- | 'Bloomerang'- | 'Bluesky'- | 'Bluetally'- | 'BoldSign'- | 'BolRetailer'- | 'Boulevard'- | 'Box'- | 'Braintree'- | 'Braintrust'- | 'Branch'- | 'Braze'- | 'Breezometer'- | 'BreezyHR'- | 'Brevo'- | 'Brex'- | 'BrowseAI'- | 'Browserbase'- | 'BrowserUse'- | 'Buffer'- | 'Bugherd'- | 'Bugsnag'- | 'BuildBetter'- | 'Buildium'- | 'Buildkite'- | 'Bunny'- | 'Buttondown'- | 'BuyMeACoffee'- | 'Buzzsprout'- | 'CalCom'- | 'Calendarific'- | 'Calendly'- | 'Calibre'- | 'CallRail'- | 'CampaignManager360'- | 'CampaignMonitor'- | 'Campayn'- | 'Campfire'- | 'Canny'- | 'CanvasLms'- | 'CapsuleCRM'- | 'CaptainData'- | 'Capterra'- | 'Captivate'- | 'CareQualityCommission'- | 'CartCom'- | 'Cashfree'- | 'CastAi'- | 'CastorEDC'- | 'Catchpoint'- | 'CdcOpenData'- | 'Census'- | 'Chameleon'- | 'Chargebee'- | 'Chargedesk'- | 'Chargify'- | 'ChartHop'- | 'ChartMogul'- | 'Chatwoot'- | 'Checkly'- | 'Checkmarx'- | 'CheckoutCom'- | 'Chift'- | 'Chorus'- | 'Churnkey'- | 'Cimis'- | 'Cin7'- | 'CircleCI'- | 'CircleciInsights'- | 'CircleSo'- | 'CiscoDuo'- | 'CiscoMeraki'- | 'Clari'- | 'Clarifai'- | 'Clarify'- | 'Classy'- | 'Clay'- | 'Clazar'- | 'Cleartax'- | 'Clerk'- | 'Clever'- | 'Clevertap'- | 'ClickHouse'- | 'ClickhouseCloud'- | 'ClickUp'- | 'Cliniko'- | 'Clio'- | 'Clip'- | 'Clockify'- | 'Clockodo'- | 'Close'- | 'Cloudability'- | 'Cloudbeds'- | 'Cloudflare'- | 'Cloudinary'- | 'Cloudsmith'- | 'Cloudzero'- | 'Clover'- | 'Coassemble'- | 'CockroachDB'- | 'Coda'- | 'Codacy'- | 'Codecov'- | 'Codefresh'- | 'Codemagic'- | 'Codescene'- | 'Cody'- | 'Cohere'- | 'CoinApi'- | 'CoinGecko'- | 'CoinMarketCap'- | 'Collibra'- | 'Commercetools'- | 'CommissionJunction'- | 'Companycam'- | 'Concord'- | 'Conekta'- | 'ConfigCat'- | 'Confluence'- | 'ConfluentCloud'- | 'ConstantContact'- | 'ContaAzul'- | 'Contentsquare'- | 'ConvertKit'- | 'Convex'- | 'Convonite'- | 'Coolify'- | 'Copper'- | 'Coralogix'- | 'Cortex'- | 'CosmosDB'- | 'Couchbase'- | 'Coupa'- | 'Courier'- | 'Coveralls'- | 'CratesIO'- | 'Crisp'- | 'Criteo'- | 'Cronitor'- | 'Crossref'- | 'CrowdstrikeFalcon'- | 'Crunchbase'- | 'CubeCloud'- | 'CultureAmp'- | 'Cursor'- | 'Curve'- | 'Custom'- | 'CustomerIO'- | 'Customerly'- | 'Cybersource'- | 'D2lBrightspace'- | 'DagsterCloud'- | 'Databricks'- | 'Datadog'- | 'DataForSEO'- | 'Datahub'- | 'Datascope'- | 'DatoCMS'- | 'Datorama'- | 'Dayforce'- | 'Db2'- | 'Dbt'- | 'Debugbear'- | 'Decagon'- | 'Deel'- | 'DeelFlows'- | 'Deepgram'- | 'Deepsource'- | 'Demodesk'- | 'DenoDeploy'- | 'Depot'- | 'Deputy'- | 'Descope'- | 'Develocity'- | 'DevinAI'- | 'Dialpad'- | 'DigitalOcean'- | 'DingConnect'- | 'Directus'- | 'Discord'- | 'Discourse'- | 'DisplayVideo360'- | 'Dixa'- | 'Dockerhub'- | 'Docuseal'- | 'Docusign'- | 'DodoPayments'- | 'DoIt'- | 'Dokploy'- | 'Dolibarr'- | 'Donorbox'- | 'Doorloop'- | 'Doppler'- | 'Dovetail'- | 'Drata'- | 'Drchrono'- | 'Dremio'- | 'Drip'- | 'Dropbox'- | 'DropboxSign'- | 'Dub'- | 'Dubsado'- | 'DuckLake'- | 'Dwolla'- | 'Dynamics365'- | 'Dynamics365BusinessCentral'- | 'DynamoDB'- | 'Dynatrace'- | 'E2B'- | 'Easybill'- | 'Easypost'- | 'Easypromos'- | 'Ebay'- | 'EcbDataPortal'- | 'EConomic'- | 'Elasticemail'- | 'Elasticsearch'- | 'ElectricityMaps'- | 'ElevenLabs'- | 'Eloqua'- | 'EmailOctopus'- | 'Emarsys'- | 'Embrace'- | 'EmploymentHero'- | 'Encharge'- | 'Entsoe'- | 'Env0'- | 'Eppo'- | 'Etsy'- | 'Eurostat'- | 'Eventbrite'- | 'Eventee'- | 'Eventzilla'- | 'Everhour'- | 'ExchangeRatesApi'- | 'Expensify'- | 'EZOfficeInventory'- | 'FacebookPages'- | 'Factorial'- | 'Faire'- | 'FarosAi'- | 'Fastbill'- | 'Fastly'- | 'Fauna'- | 'Featurebase'- | 'Feishu'- | 'Fieldpulse'- | 'Fieldwire'- | 'Filevine'- | 'Fillout'- | 'Finage'- | 'FinancialModelling'- | 'Finnhub'- | 'Finnworlds'- | 'Finout'- | 'Fintoc'- | 'Firebase'- | 'Firebolt'- | 'Firecrawl'- | 'FireHydrant'- | 'FireworksAI'- | 'FirstPromoter'- | 'Five9'- | 'Flagsmith'- | 'Fleetio'- | 'FlexeraCloudCost'- | 'Flexmail'- | 'Flexport'- | 'FloatApp'- | 'Flowlu'- | 'Flutterwave'- | 'FlyIo'- | 'Folk'- | 'Formbricks'- | 'Fortnox'- | 'Fourthwall'- | 'Framer'- | 'Fred'- | 'FreeAgent'- | 'Freightview'- | 'FreshBooks'- | 'Freshcaller'- | 'Freshchat'- | 'Freshdesk'- | 'Freshsales'- | 'Freshservice'- | 'Frill'- | 'Front'- | 'Frontegg'- | 'Fulcrum'- | 'FullStory'- | 'FusionAuth'- | 'G2'- | 'GainsightCs'- | 'GainsightPx'- | 'Gcore'- | 'GcpApigee'- | 'GcpArtifactRegistry'- | 'GcpBigtable'- | 'GcpChronicle'- | 'GcpCloudAssetInventory'- | 'GcpCloudBilling'- | 'GcpCloudBuild'- | 'GcpCloudDeploy'- | 'GcpCloudDns'- | 'GcpCloudFunctions'- | 'GcpCloudLogging'- | 'GcpCloudMonitoring'- | 'GcpCloudRun'- | 'GcpCloudSpanner'- | 'GcpCloudSql'- | 'GcpCloudTrace'- | 'GcpCloudWorkflows'- | 'GcpComputeEngine'- | 'GcpContainerAnalysis'- | 'GcpDataflow'- | 'GcpDataplex'- | 'GcpDataproc'- | 'GcpErrorReporting'- | 'GcpGke'- | 'GcpPubsub'- | 'GcpRecaptchaEnterprise'- | 'GcpRecommender'- | 'GcpSecurityCommandCenter'- | 'Gdelt'- | 'GenesysCloud'- | 'Gerrit'- | 'Getdx'- | 'GetStream'- | 'Ghost'- | 'Giphy'- | 'GitBook'- | 'Gitea'- | 'Gitguardian'- | 'Github'- | 'GitLab'- | 'Givebutter'- | 'Gladly'- | 'Glassfrog'- | 'Gleif'- | 'Gmail'- | 'GNews'- | 'GoCardless'- | 'Gojiberry'- | 'Goldcast'- | 'GoLogin'- | 'Gong'- | 'GoogleAdManager'- | 'GoogleAds'- | 'GoogleAdSense'- | 'GoogleAnalytics'- | 'GoogleCalendar'- | 'GoogleChat'- | 'GoogleClassroom'- | 'GoogleCloudStorage'- | 'GoogleDirectory'- | 'GoogleDrive'- | 'GoogleForms'- | 'GoogleMerchantCenter'- | 'GooglePageSpeedInsights'- | 'GooglePlayConsole'- | 'GooglePostmasterTools'- | 'GoogleSearchConsole'- | 'GoogleSheets'- | 'GoogleTasks'- | 'GoogleWebfonts'- | 'GoogleWorkspaceAdminReports'- | 'Gorgias'- | 'Grafana'- | 'Granola'- | 'Greenhouse'- | 'GreytHr'- | 'Gridly'- | 'Groq'- | 'Growi'- | 'GrowthBook'- | 'Guardian'- | 'Guesty'- | 'Gumloop'- | 'Gumroad'- | 'Guru'- | 'Gusto'- | 'Harness'- | 'HarnessCcm'- | 'HarnessSei'- | 'Harvest'- | 'Harvey'- | 'Hatchet'- | 'Healthchecks'- | 'Healthie'- | 'Heap'- | 'Height'- | 'Helicone'- | 'Hellobaton'- | 'HelpScout'- | 'Heroku'- | 'Hetzner'- | 'Hex'- | 'HeyGen'- | 'HiBob'- | 'HighLevel'- | 'Hightouch'- | 'Hitpay'- | 'Hivebrite'- | 'Holded'- | 'Honeybadger'- | 'Honeycomb'- | 'Hookdeck'- | 'HoorayHR'- | 'Hootsuite'- | 'Hostaway'- | 'HousecallPro'- | 'Hubplanner'- | 'Hubspot'- | 'HuggingFace'- | 'Humanitec'- | 'Humanitix'- | 'Huntr'- | 'Hyperspell'- | 'Hyros'- | 'Ikas'- | 'IlluminaBasespace'- | 'Imagga'- | 'ImfData'- | 'Impact'- | 'ImpactPartner'- | 'Imperva'- | 'IncidentIo'- | 'Infisical'- | 'Inflowinventory'- | 'InfluxdbCloud'- | 'InforNexus'- | 'Inngest'- | 'Insightful'- | 'Insightly'- | 'Instagram'- | 'Instana'- | 'Instantly'- | 'Instatus'- | 'Intercom'- | 'Interzoid'- | 'Inth'- | 'Intruder'- | 'Invoiced'- | 'Invoiceninja'- | 'IP2Whois'- | 'IronSourceAds'- | 'Iterable'- | 'Iyzico'- | 'JamfPro'- | 'Jellyfish'- | 'Jenkins'- | 'JfrogArtifactory'- | 'Jira'- | 'Jobber'- | 'JobNimbus'- | 'Jobtread'- | 'Jotform'- | 'JudgeMeReviews'- | 'Jumpcloud'- | 'JustCall'- | 'JustSift'- | 'K6Cloud'- | 'Kafka'- | 'Kajabi'- | 'Kalshi'- | 'Kameleoon'- | 'Kandji'- | 'KapaAI'- | 'Katana'- | 'KauflandMarketplace'- | 'Keka'- | 'Kernel'- | 'Kestra'- | 'Kick'- | 'Kickscale'- | 'Kickstarter'- | 'Kinde'- | 'Kion'- | 'Kisi'- | 'Kissmetrics'- | 'Klarna'- | 'Klaus'- | 'Klaviyo'- | 'Knock'- | 'Knowbe4'- | 'Kommo'- | 'Komodor'- | 'KongKonnect'- | 'Koyeb'- | 'Kubecost'- | 'Kustomer'- | 'KYVE'- | 'Labelbox'- | 'Lacework'- | 'Lago'- | 'LambdaLabs'- | 'Langfuse'- | 'LangSmith'- | 'Latitude'- | 'Lattice'- | 'LaunchDarkly'- | 'Lawmatics'- | 'Leadfeeder'- | 'Learnworlds'- | 'Leexi'- | 'Lemlist'- | 'LemonSqueezy'- | 'LessAnnoyingCRM'- | 'Lever'- | 'LexwareOffice'- | 'Liana'- | 'Lightdash'- | 'Lightfield'- | 'LightspeedRetail'- | 'Linear'- | 'Linearb'- | 'LingoDev'- | 'LinkedinAds'- | 'LinkedinPages'- | 'Linkrunner'- | 'Linnworks'- | 'Linode'- | 'Liveblocks'- | 'LlamaCloud'- | 'Lob'- | 'Lodgify'- | 'Logicmonitor'- | 'Logrocket'- | 'LogzIO'- | 'Lokalise'- | 'Looker'- | 'LoopReturns'- | 'Loops'- | 'Lovable'- | 'Luma'- | 'M3ter'- | 'Mailchimp'- | 'MailerLite'- | 'MailerSend'- | 'Mailgun'- | 'Mailjet'- | 'Mailosaur'- | 'Mailtrap'- | 'Mantle'- | 'Manychat'- | 'Marketo'- | 'Marketstack'- | 'Mastodon'- | 'Matomo'- | 'Maxio'- | 'Medusa'- | 'Meetup'- | 'Meltwater'- | 'Mem0'- | 'Memberful'- | 'Membrain'- | 'Mendeley'- | 'Mention'- | 'MercadoAds'- | 'MercadoPago'- | 'Mercury'- | 'Merge'- | 'MetaAds'- | 'Metabase'- | 'Metaplane'- | 'Meteostat'- | 'Metorial'- | 'Metricool'- | 'Metriport'- | 'Metronome'- | 'Mews'- | 'Mezmo'- | 'Microsoft365UsageReports'- | 'MicrosoftAdvertising'- | 'MicrosoftClarity'- | 'MicrosoftDataverse'- | 'MicrosoftDefenderCloudApps'- | 'MicrosoftDefenderEndpoint'- | 'MicrosoftDefenderForCloud'- | 'MicrosoftEntraId'- | 'MicrosoftExcel'- | 'MicrosoftIntune'- | 'MicrosoftLists'- | 'MicrosoftPurview'- | 'MicrosoftPurviewAudit'- | 'MicrosoftSentinel'- | 'MicrosoftTeams'- | 'MicrosoftTeamsCallRecords'- | 'Midtrans'- | 'MightyNetworks'- | 'Mindbody'- | 'Mintlify'- | 'Mirakl'- | 'Miro'- | 'Missive'- | 'MistralAI'- | 'MixMax'- | 'Mixpanel'- | 'Mode'- | 'Moesif'- | 'Mollie'- | 'Monday'- | 'Moneybird'- | 'MongoDB'- | 'Mono'- | 'MonteCarlo'- | 'Moodle'- | 'Motherduck'- | 'Motion'- | 'Moxie'- | 'MSG91'- | 'MSSQL'- | 'Mux'- | 'Mycase'- | 'MyHours'- | 'MySQL'- | 'N8n'- | 'NagerDate'- | 'Nasa'- | 'NationBuilder'- | 'Navan'- | 'NebiusAI'- | 'Neon'- | 'NeonCrm'- | 'Netlify'- | 'NetSuite'- | 'NewRelic'- | 'NewsApi'- | 'NewsData'- | 'NewYorkTimes'- | 'Nexhealth'- | 'Nexiopay'- | 'NextdoorAds'- | 'NinjaOneRMM'- | 'NoaaCdo'- | 'Nobl9'- | 'NoCRM'- | 'Nolt'- | 'Nops'- | 'Northflank'- | 'NorthpassLMS'- | 'Notion'- | 'NpmRegistry'- | 'Nuget'- | 'Nuntly'- | 'Nutshell'- | 'Nylas'- | 'Octolens'- | 'OctopusDeploy'- | 'Odoo'- | 'Oecd'- | 'Okendo'- | 'Okta'- | 'Omni'- | 'Omnisend'- | 'Oncehub'- | 'OneDrive'- | 'OneHundredMs'- | 'Onelogin'- | 'Onepagecrm'- | 'OnePassword'- | 'OneSignal'- | 'Onfleet'- | 'OpenAI'- | 'OpenAIAds'- | 'Openalex'- | 'OpenAQ'- | 'Opencorporates'- | 'OpenDataDc'- | 'OpenDental'- | 'OpenExchangeRates'- | 'OpenFDA'- | 'Openfec'- | 'OpenMeteo'- | 'OpenRouter'- | 'OpenWeather'- | 'OpinionStage'- | 'OpnPayments'- | 'Opsgenie'- | 'Opslevel'- | 'Optimizely'- | 'OPUSWatch'- | 'Oracle'- | 'OracleEbs'- | 'OracleFusion'- | 'Orb'- | 'Orbit'- | 'OrcaSecurity'- | 'Ortto'- | 'OttoMarket'- | 'Oura'- | 'Outbrain'- | 'Outlook'- | 'Outreach'- | 'Oveit'- | 'Ownerrez'- | 'PabblySubscriptionsBilling'- | 'Packagist'- | 'Paddle'- | 'Pagbank'- | 'PagerDuty'- | 'PandaDoc'- | 'Paperform'- | 'Papersign'- | 'Pardot'- | 'Partnerize'- | 'PartnerStack'- | 'Patreon'- | 'Pax8'- | 'Paychex'- | 'PayFit'- | 'Paylocity'- | 'Paymob'- | 'Paymongo'- | 'PayPal'- | 'Paystack'- | 'PeecAI'- | 'Pendo'- | 'Pennylane'- | 'Perigon'- | 'Perk'- | 'PersistIq'- | 'Persona'- | 'Personio'- | 'Pexels'- | 'PgAnalyze'- | 'Phonepe'- | 'Phyllo'- | 'Picqer'- | 'Pike13'- | 'Pinecone'- | 'Pingdom'- | 'Pingone'- | 'PinterestAds'- | 'PinterestOrganic'- | 'Pipedrive'- | 'Pipeliner'- | 'PivotalTracker'- | 'Piwik'- | 'Plaid'- | 'Plain'- | 'PlanetScaleMySQL'- | 'PlanetScalePostgres'- | 'Planhat'- | 'PlanningCenter'- | 'PlatformSh'- | 'Plausible'- | 'Plivo'- | 'Plunk'- | 'PluralsightFlow'- | 'Pocket'- | 'Podbean'- | 'Podium'- | 'Polar'- | 'Polygon'- | 'Polymarket'- | 'Poplar'- | 'Postgres'- | 'Postmark'- | 'Postscript'- | 'PowerBiAdmin'- | 'Practicepanther'- | 'PrefectCloud'- | 'Preset'- | 'PrestaShop'- | 'Pretix'- | 'Primetric'- | 'Printavo'- | 'Printify'- | 'Procore'- | 'Productboard'- | 'Productiv'- | 'Productive'- | 'Profound'- | 'PromptingCompany'- | 'PromptWatch'- | 'ProofpointTap'- | 'Propertyware'- | 'Pubnub'- | 'PulumiCloud'- | 'Pylon'- | 'PyPI'- | 'Qdrant'- | 'Qonto'- | 'Qualaroo'- | 'Qualtrics'- | 'QualysVmdr'- | 'Quay'- | 'QuickBooks'- | 'Railway'- | 'Railz'- | 'Raisely'- | 'Raken'- | 'RakutenAdvertising'- | 'Ramp'- | 'Rapid7Insightvm'- | 'Raygun'- | 'Razorpay'- | 'RB2B'- | 'RDStationMarketing'- | 'RecallAI'- | 'Recharge'- | 'Recreation'- | 'Recruitee'- | 'Recurly'- | 'Reddit'- | 'RedditAds'- | 'Redis'- | 'RedpandaCloud'- | 'Redshift'- | 'ReferralHero'- | 'Render'- | 'RentCast'- | 'RentManager'- | 'Repairshopr'- | 'Replicate'- | 'ReplyIo'- | 'Resend'- | 'RetailExpress'- | 'RetellAI'- | 'Retently'- | 'RevenueCat'- | 'Reverb'- | 'RevolutMerchant'- | 'RingCentral'- | 'Rippling'- | 'RKICovid'- | 'Roark'- | 'RocketChat'- | 'Rocketlane'- | 'RocketMatter'- | 'RoktAds'- | 'Rollbar'- | 'Rootly'- | 'Rss'- | 'Rubygems'- | 'RudderStack'- | 'Ruddr'- | 'RunPod'- | 'SafetyCulture'- | 'SageHR'- | 'SageIntacct'- | 'Sailthru'- | 'Salesflare'- | 'Salesforce'- | 'SalesforceMarketingCloud'- | 'SalesLoft'- | 'Salestrics'- | 'SamCart'- | 'Sanity'- | 'SapConcur'- | 'SapErp'- | 'SAPFieldglass'- | 'SapHana'- | 'SapSuccessFactors'- | 'SavvyCal'- | 'ScaleAI'- | 'Scaleway'- | 'Scalr'- | 'Schematic'- | 'SearchAds360'- | 'SecEdgar'- | 'Secoda'- | 'Secureframe'- | 'Segment'- | 'SelectStar'- | 'SemanticScholar'- | 'Semaphore'- | 'Semgrep'- | 'Semrush'- | 'SendGrid'- | 'Sendowl'- | 'SendPulse'- | 'Senseforce'- | 'Sentinelone'- | 'Sentry'- | 'Sequenzy'- | 'Serpstat'- | 'ServiceFusion'- | 'Servicem8'- | 'ServiceNow'- | 'Servicetitan'- | 'Servicetrade'- | 'Sevalla'- | 'Sevdesk'- | 'SevenShifts'- | 'SFTP'- | 'SharePoint'- | 'Sharetribe'- | 'Shipmail'- | 'Shippo'- | 'ShipStation'- | 'Shopify'- | 'Shopware'- | 'ShopWired'- | 'Shortcut'- | 'Shortio'- | 'Shutterstock'- | 'SideShift'- | 'SigmaComputing'- | 'SignNow'- | 'SigNoz'- | 'Sim'- | 'SimFin'- | 'Similarweb'- | 'SimonData'- | 'SimpleCast'- | 'Simplesat'- | 'Simpro'- | 'Sinch'- | 'Singlestore'- | 'Singular'- | 'Site24x7'- | 'Skio'- | 'Skyvern'- | 'Slack'- | 'Slash'- | 'Sleekplan'- | 'Sleuth'- | 'Smaily'- | 'SmartEngage'- | 'Smartlead'- | 'Smartlook'- | 'Smartreach'- | 'Smartrecruiters'- | 'Smartsheet'- | 'Smartwaiver'- | 'Smokeball'- | 'SnapchatAds'- | 'Snovio'- | 'Snowflake'- | 'Snowplow'- | 'Snyk'- | 'SocialPilot'- | 'SodaCloud'- | 'SolarwindsServiceDesk'- | 'SonarCloud'- | 'Sonarqube'- | 'SonatypeNexus'- | 'Sourcegraph'- | 'Spacelift'- | 'SparkPost'- | 'Speedcurve'- | 'SplitIo'- | 'SplunkObservabilityCloud'- | 'SpotifyAds'- | 'SpotIo'- | 'SpotlerCRM'- | 'Sprig'- | 'Sprinklr'- | 'SproutSocial'- | 'Squadcast'- | 'Square'- | 'Squarespace'- | 'StackOverflowForTeams'- | 'Starburst'- | 'Statsig'- | 'Statuscake'- | 'Statuspage'- | 'Stigg'- | 'StockData'- | 'Stockx'- | 'Strato'- | 'Strava'- | 'StreamElements'- | 'Streamlabs'- | 'Stripe'- | 'Stytch'- | 'Substack'- | 'SumoLogic'- | 'Sumsub'- | 'Supabase'- | 'Superwall'- | 'SurveyMonkey'- | 'SurveySparrow'- | 'Survicate'- | 'Svix'- | 'Swan'- | 'Swarmia'- | 'Swonkie'- | 'Synthesia'- | 'Systeme'- | 'Taboola'- | 'TackleIo'- | 'Tailscale'- | 'Talkdesk'- | 'Talkwalker'- | 'Tally'- | 'Tana'- | 'Tavus'- | 'TawkTo'- | 'Teachable'- | 'Teamcity'- | 'Teamtailor'- | 'TeamupFitness'- | 'Teamwork'- | 'Tebra'- | 'Telli'- | 'Telnyx'- | 'Tempo'- | 'TemporalIO'- | 'TenableVulnerabilityManagement'- | 'Tenjin'- | 'TeraBox'- | 'Ternary'- | 'TerraApi'- | 'TerraformCloud'- | 'Testrail'- | 'Thinkific'- | 'ThinkificCourses'- | 'Thoughtspot'- | 'Thousandeyes'- | 'Threads'- | 'ThriveLearning'- | 'Ticketmaster'- | 'TicketTailor'- | 'TickTick'- | 'TikTokAds'- | 'TiktokShop'- | 'Tile38'- | 'Timely'- | 'Tinybird'- | 'Tinyemail'- | 'TinyErp'- | 'Tipalti'- | 'TMDb'- | 'Toast'- | 'Todoist'- | 'TogetherAI'- | 'Toggl'- | 'Torii'- | 'TrackPMS'- | 'TradableBits'- | 'Transistor'- | 'TravisCI'- | 'Trello'- | 'Tremendous'- | 'TriggerDev'- | 'Trino'- | 'TripleWhale'- | 'TrunkIo'- | 'TrustPilot'- | 'Trustradius'- | 'Turso'- | 'TVMaze'- | 'TwelveData'- | 'TwelveLabs'- | 'Twenty'- | 'Twilio'- | 'Twitch'- | 'Twitter'- | 'TwitterAds'- | 'TwoC2p'- | 'TyntecSMS'- | 'Typeform'- | 'Typesense'- | 'Ubidots'- | 'UkCompaniesHouse'- | 'UkOns'- | 'Umami'- | 'UnComtrade'- | 'Unleash'- | 'Unstructured'- | 'Uploadcare'- | 'UpPromote'- | 'Upstash'- | 'Uptick'- | 'Uptimerobot'- | 'UsBea'- | 'UsBls'- | 'USCensus'- | 'UsEia'- | 'UserCom'- | 'Usersnap'- | 'Uservoice'- | 'UsTreasuryFiscalData'- | 'Vanta'- | 'Vantage'- | 'Vapi'- | 'Veeqo'- | 'Vellum'- | 'Vendr'- | 'Veracode'- | 'Vercel'- | 'Vespa'- | 'Virtuous'- | 'VismaEconomic'- | 'Vitally'- | 'Vonage'- | 'Vturb'- | 'Vultr'- | 'VWO'- | 'Waiteraid'- | 'WalmartMarketplace'- | 'Wasabi'- | 'Watchmode'- | 'Waydev'- | 'Wayfair'- | 'Webflow'- | 'WeightsAndBiases'- | 'WhatsappBusinessManagement'- | 'WhenIWork'- | 'WHMCS'- | 'WhoGho'- | 'Whop'- | 'WikipediaPageviews'- | 'Windmill'- | 'WindsorAi'- | 'WisprFlow'- | 'Wix'- | 'Wiz'- | 'Wompi'- | 'WooCommerce'- | 'Wordpress'- | 'Workable'- | 'Workato'- | 'Workday'- | 'Workflowmax'- | 'Workiz'- | 'WorkOS'- | 'Workramp'- | 'WorldBank'- | 'WPSOffice'- | 'Wrike'- | 'Writesonic'- | 'Wufoo'- | 'Xendit'- | 'Xero'- | 'Xmatters'- | 'Xsolla'- | 'YahooFinance'- | 'YandexMetrica'- | 'Ynab'- | 'Yoco'- | 'Yotpo'- | 'Younium'- | 'YouSign'- | 'YouTubeAnalytics'- | 'YoutubeData'- | 'ZalandoZdirect'- | 'ZapierSupportedStorage'- | 'ZapSign'- | 'Zellify'- | 'Zenchef'- | 'Zendesk'- | 'ZendeskSell'- | 'ZendeskSunshine'- | 'Zenduty'- | 'Zenefits'- | 'Zenloop'- | 'Zep'- | 'Zero'- | 'Zitadel'- | 'Zluri'- | 'ZohoAnalytics'- | 'ZohoBigin'- | 'ZohoBilling'- | 'ZohoBooks'- | 'ZohoCampaign'- | 'ZohoCRM'- | 'ZohoDesk'- | 'ZohoExpense'- | 'ZohoInventory'- | 'ZohoInvoice'- | 'ZonkaFeedback'- | 'Zoom'- | 'ZoomInfo'- | 'Zuora'- | 'Zylo'+ source: ExternalDataSourceTypeEnumApi}onBack: () => {value: true@@ -1999,11 +657,11 @@ export interface sourceWizardLogicActions {value: true}selectConnector: (- connector: SourceConfig | null,+ connector: SourceConfigResponseApi | null,accessMethod?: 'direct' | 'warehouse') => {accessMethod: 'direct' | 'warehouse' | undefined- connector: SourceConfig | null+ connector: SourceConfigResponseApi | null}setDatabaseSchemas: (schemas: ExternalDataSourceSyncSchema[]) => {schemas: ExternalDataSourceSyncSchema[]@@ -2011,8 +669,8 @@ export interface sourceWizardLogicActions {setExpandedSchemaGroupKeys: (expandedSchemaKeys: string[]) => {expandedSchemaKeys: string[]}- setInitialConnector: (connector: SourceConfig | null) => {- connector: SourceConfig | null+ setInitialConnector: (connector: SourceConfigResponseApi | null) => {+ connector: SourceConfigResponseApi | null}setIsLoading: (isLoading: boolean) => {isLoading: boolean@@ -2205,10 +863,10 @@ export interface sourceWizardLogicMeta {__keaTypeGenInternalSelectorTypes: {availableSources: (arg: any) => anyrequiredTables: (arg: any) => any- defaultSourceConnectionDetails: (selectedConnector: SourceConfig | null) => Record<string, unknown>- suggestedTablesMap: (selectedConnector: SourceConfig | null) => Record<string, string | null>+ defaultSourceConnectionDetails: (selectedConnector: SourceConfigResponseApi | null) => Record<string, unknown>+ suggestedTablesMap: (selectedConnector: SourceConfigResponseApi | null) => Record<string, string | null>breadcrumbs: (- selectedConnector: SourceConfig | null,+ selectedConnector: SourceConfigResponseApi | null,manualLinkingProvider: 'aws' | 'azure' | 'cloudflare-r2' | 'google-cloud' | null,manualConnectors: {name: string@@ -2218,9 +876,9 @@ export interface sourceWizardLogicMeta {hasWebhookSchemas: (databaseSchema: ExternalDataSourceSyncSchema[]) => booleanwebhookStepComplete: (webhookResult: WebhookCreateResult | null,- selectedConnector: SourceConfig | null+ selectedConnector: SourceConfigResponseApi | null) => boolean- isManualLinkingSelected: (selectedConnector: SourceConfig | null) => boolean+ isManualLinkingSelected: (selectedConnector: SourceConfigResponseApi | null) => booleanisDirectQueryMode: (source: {access_method: 'direct' | 'warehouse'@@ -2229,7 +887,7 @@ export interface sourceWizardLogicMeta {payload: Record<string, any>prefix: string},- selectedConnector: SourceConfig | null+ selectedConnector: SourceConfigResponseApi | null) => booleancanGoBack: (currentStep: number) => booleancanGoNext: (@@ -2260,11 +918,14 @@ export interface sourceWizardLogicMeta {} | null,sourceId: string | null) => string- showFooter: (selectedConnector: SourceConfig | null, isManualLinkFormVisible: boolean) => boolean | SourceConfig+ showFooter: (+ selectedConnector: SourceConfigResponseApi | null,+ isManualLinkFormVisible: boolean+ ) => boolean | SourceConfigResponseApiconnectors: (dataWarehouseSources: PaginatedResponse<ExternalDataSource> | null,availableSources: any- ) => SourceConfig[]+ ) => SourceConfigResponseApi[]isSelfManagedSource: (manualLinkingProvider: 'aws' | 'azure' | 'cloudflare-r2' | 'google-cloud' | null) => boolean@@ -2331,13 +992,13 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([path(['products', 'dataWarehouse', 'sourceWizardLogic']),props({} as SourceWizardLogicProps),actions({- selectConnector: (connector: SourceConfig | null, accessMethod?: 'warehouse' | 'direct') => ({+ selectConnector: (connector: SourceConfigResponseApi | null, accessMethod?: 'warehouse' | 'direct') => ({connector,accessMethod,}),- setInitialConnector: (connector: SourceConfig | null) => ({ connector }),+ setInitialConnector: (connector: SourceConfigResponseApi | null) => ({ connector }),toggleManualLinkFormVisible: (visible: boolean) => ({ visible }),- handleRedirect: (source: ExternalDataSourceType, searchParams?: any) => ({+ handleRedirect: (source: ExternalDataSourceTypeEnumApi, searchParams?: any) => ({source,searchParams,}),@@ -2454,7 +1115,7 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([},],selectedConnector: [- null as SourceConfig | null,+ null as SourceConfigResponseApi | null,{selectConnector: (_, { connector }) => connector,setInitialConnector: (_, { connector }) => connector,@@ -2700,7 +1361,8 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([try {return await api.externalDataSources.check_cdc_prerequisites({- source_type: (values.selectedConnector?.name || 'Postgres') as ExternalDataSourceType,+ source_type: (values.selectedConnector?.name ||+ 'Postgres') as ExternalDataSourceTypeEnumApi,...payload,cdc_management_mode: mode,tables: [],@@ -2737,7 +1399,8 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([try {return await api.externalDataSources.check_cdc_prerequisites({- source_type: (values.selectedConnector?.name || 'Postgres') as ExternalDataSourceType,+ source_type: (values.selectedConnector?.name ||+ 'Postgres') as ExternalDataSourceTypeEnumApi,...connectionPayload,cdc_management_mode: 'self_managed',// PostHog creates the slot itself — only verify the publication.@@ -2763,7 +1426,7 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([// the `resetSourceForm` listener writes these into form state.defaultSourceConnectionDetails: [(s) => [s.selectedConnector],- (selectedConnector: SourceConfig | null): Record<string, unknown> => {+ (selectedConnector: SourceConfigResponseApi | null): Record<string, unknown> => {if (!selectedConnector) {return { prefix: '', description: '', payload: {} }}@@ -2774,13 +1437,13 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([],suggestedTablesMap: [(s) => [s.selectedConnector],- (selectedConnector: SourceConfig | null): Record<string, string | null> => {+ (selectedConnector: SourceConfigResponseApi | null): Record<string, string | null> => {if (!selectedConnector?.suggestedTables) {return {}}return selectedConnector.suggestedTables.reduce(- (acc: Record<string, string | null>, suggested: SuggestedTable) => {+ (acc: Record<string, string | null>, suggested: SuggestedTableApi) => {acc[suggested.table] = suggested.tooltip ?? nullreturn acc},@@ -2791,7 +1454,7 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([breadcrumbs: [(s) => [s.selectedConnector, s.manualLinkingProvider, s.manualConnectors],(- selectedConnector: SourceConfig | null,+ selectedConnector: SourceConfigResponseApi | null,manualLinkingProvider: ManualLinkSourceType | null,manualConnectors: {name: string@@ -2825,7 +1488,7 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([],webhookStepComplete: [(s) => [s.webhookResult, s.selectedConnector],- (webhookResult: WebhookCreateResult | null, selectedConnector: SourceConfig | null): boolean => {+ (webhookResult: WebhookCreateResult | null, selectedConnector: SourceConfigResponseApi | null): boolean => {if (webhookResultHasNoPendingInputs(webhookResult)) {return true}@@ -2840,7 +1503,7 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([],isManualLinkingSelected: [(s) => [s.selectedConnector],- (selectedConnector: SourceConfig | null): boolean => !selectedConnector,+ (selectedConnector: SourceConfigResponseApi | null): boolean => !selectedConnector,],isDirectQueryMode: [(s) => [s.source, s.selectedConnector],@@ -2851,7 +1514,7 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([payload: Record<string, any>prefix: string},- selectedConnector: SourceConfig | null+ selectedConnector: SourceConfigResponseApi | null): boolean => source.access_method === 'direct' && supportsDirectQuery(selectedConnector?.name),],canGoBack: [@@ -3004,15 +1667,15 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([],showFooter: [(s) => [s.selectedConnector, s.isManualLinkFormVisible],- (selectedConnector: SourceConfig | null, isManualLinkFormVisible: boolean) =>+ (selectedConnector: SourceConfigResponseApi | null, isManualLinkFormVisible: boolean) =>selectedConnector || isManualLinkFormVisible,],connectors: [(s) => [s.dataWarehouseSources, s.availableSources],(sources: null | import('lib/api').PaginatedResponse<import('~/types').ExternalDataSource>,- availableSources: Record<string, SourceConfig>- ): SourceConfig[] => {+ availableSources: Record<string, SourceConfigResponseApi>+ ): SourceConfigResponseApi[] => {if (!availableSources) {return []}@@ -3616,7 +2279,7 @@ export const sourceWizardLogic = kea<sourceWizardLogicType>([},handleRedirect: async ({ source }) => {// By default, we assume the source is a valid external data source- if (externalDataSources.includes(source)) {+ if (Object.values(ExternalDataSourceTypeEnumApi).includes(source)) {actions.updateSource({source_type: source,})diff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardValidation.test.ts b/products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardValidation.test.tsindex 115ebd1cbdc1..4c44119bde91 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardValidation.test.ts+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardValidation.test.ts@@ -1,4 +1,4 @@-import type { SourceFieldConfig } from '~/queries/schema/schema-general'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'import { findOauthBranch, normalizeMultiValue } from '../../shared/components/forms/IntegrationAccountSelector'import { getErrorsForFields, missingUploadedFileKeys } from './sourceWizardLogic'diff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/tests/sourceCatalogLogic.test.ts b/products/data_warehouse/frontend/scenes/NewSourceScene/tests/sourceCatalogLogic.test.tsindex cb4c3d0346dc..f3b359344e29 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/tests/sourceCatalogLogic.test.ts+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/tests/sourceCatalogLogic.test.ts@@ -1,13 +1,14 @@import { featureFlagLogic } from 'lib/logic/featureFlagLogic'import { useMocks } from '~/mocks/jest'-import type { SourceConfig } from '~/queries/schema/schema-general'import { initKeaTests } from '~/test/init'+import type { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'+import { availableSourcesLogic } from '../availableSourcesLogic'import { sourceCatalogLogic } from '../sourceCatalogLogic'-const AVAILABLE_SOURCES: Record<string, SourceConfig> = {+const AVAILABLE_SOURCES: Record<string, SourceConfigResponseApi> = {// Featured, so it must lead the browse list even though `Stripe` sorts after `Mango`.Stripe: {name: 'Stripe',@@ -15,24 +16,29 @@ const AVAILABLE_SOURCES: Record<string, SourceConfig> = {caption: '',featured: true,fields: [],- } as unknown as SourceConfig,+ } as unknown as SourceConfigResponseApi,// `Apple` sorts alphabetically first but is unreleased, so connectable-first ordering must// still push it below the two available sources.- Zebra: { name: 'Zebra', label: 'Zebra', fields: [] } as unknown as SourceConfig,- Mango: { name: 'Mango', label: 'Mango', fields: [] } as unknown as SourceConfig,- Apple: { name: 'Apple', label: 'Apple', unreleasedSource: true, fields: [] } as unknown as SourceConfig,+ Zebra: { name: 'Zebra', label: 'Zebra', fields: [] } as unknown as SourceConfigResponseApi,+ Mango: { name: 'Mango', label: 'Mango', fields: [] } as unknown as SourceConfigResponseApi,+ Apple: { name: 'Apple', label: 'Apple', unreleasedSource: true, fields: [] } as unknown as SourceConfigResponseApi,// Connectable, and shares the "apple" token with the unreleased `Apple` above so a search for// "apple" fuzzy-matches both — used to assert connectable results outrank "Coming soon" ones.- ApplePay: { name: 'ApplePay', label: 'Apple Pay', fields: [] } as unknown as SourceConfig,+ ApplePay: { name: 'ApplePay', label: 'Apple Pay', fields: [] } as unknown as SourceConfigResponseApi,// Two sources in distinct categories, used to assert that a category-filtered search which only// matches a source in another category flags a cross-category hint instead of dead-ending.- Salesforce: { name: 'Salesforce', label: 'Salesforce', category: 'Sales', fields: [] } as unknown as SourceConfig,+ Salesforce: {+ name: 'Salesforce',+ label: 'Salesforce',+ category: 'Sales',+ fields: [],+ } as unknown as SourceConfigResponseApi,Datadog: {name: 'Datadog',label: 'Datadog',category: 'Engineering & monitoring',fields: [],- } as unknown as SourceConfig,+ } as unknown as SourceConfigResponseApi,}describe('sourceCatalogLogic', () => {diff --git a/products/data_warehouse/frontend/scenes/NewSourceScene/tests/sourceWizardLogic.test.ts b/products/data_warehouse/frontend/scenes/NewSourceScene/tests/sourceWizardLogic.test.tsindex 663ef9e78701..16e74b15636d 100644--- a/products/data_warehouse/frontend/scenes/NewSourceScene/tests/sourceWizardLogic.test.ts+++ b/products/data_warehouse/frontend/scenes/NewSourceScene/tests/sourceWizardLogic.test.ts@@ -2,10 +2,11 @@ import { expectLogic } from 'kea-test-utils'import api from 'lib/api'-import type { SourceConfig } from '~/queries/schema/schema-general'import { initKeaTests } from '~/test/init'import type { ExternalDataSourceSyncSchema, IncrementalField } from '~/types'+import type { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'+import {buildKeaFormDefaultFromSourceDetails,getDatabaseSchemaPayload,@@ -16,18 +17,29 @@ import {sourceWizardLogic,} from '../sourceWizardLogic'+function buildSourceConfig(overrides: Partial<SourceConfigResponseApi>): SourceConfigResponseApi {+ // Fills the fields the wizard endpoint always sends but no case here exercises, so each+ // fixture states only what it is about.+ return {+ name: 'Postgres',+ iconPath: '',+ caption: null,+ fields: [],+ supportsColumnSelection: false,+ versions: [],+ defaultVersion: '',+ deprecatedVersions: [],+ ...overrides,+ }+}+describe('sourceWizardLogic', () => {beforeEach(() => {initKeaTests()})it('shares a single wizard instance across references with the same props', () => {- const postgresSource = {- name: 'Postgres',- iconPath: '',- caption: null,- fields: [],- } as SourceConfig+ const postgresSource = buildSourceConfig({ name: 'Postgres' })const availableSources = { Postgres: postgresSource }const firstReference = sourceWizardLogic({ availableSources })const secondReference = sourceWizardLogic({ availableSources })@@ -50,12 +62,7 @@ describe('sourceWizardLogic', () => {// Regression test: onSubmit used to read `values.currentStep` again after onNext()// advanced it, so a single click on step 4 (webhook) fell through into the step-5// completion branch in the same call, skipping the progress step entirely.- const postgresSource = {- name: 'Postgres',- iconPath: '',- caption: null,- fields: [],- } as SourceConfig+ const postgresSource = buildSourceConfig({ name: 'Postgres' })const onComplete = jest.fn()const logic = sourceWizardLogic({ availableSources: { Postgres: postgresSource }, onComplete })const unmount = logic.mount()@@ -75,12 +82,7 @@ describe('sourceWizardLogic', () => {})it('does not hydrate the same source URL again after the wizard has started', () => {- const postgresSource = {- name: 'Postgres',- iconPath: '',- caption: null,- fields: [],- } as SourceConfig+ const postgresSource = buildSourceConfig({ name: 'Postgres' })expect(shouldHydrateSourceFromUrl(2, postgresSource, postgresSource, 'direct', 'direct')).toBe(false)expect(shouldHydrateSourceFromUrl(1, postgresSource, postgresSource, 'direct', 'direct')).toBe(true)@@ -157,10 +159,8 @@ describe('sourceWizardLogic', () => {it('returns defaults for text fields', async () => {const sourceWizardLogic = await import('../sourceWizardLogic')const res = sourceWizardLogic.buildKeaFormDefaultFromSourceDetails({- Test: {+ Test: buildSourceConfig({name: 'Stripe',- iconPath: '',- caption: null,fields: [{name: 'test_field',@@ -171,7 +171,7 @@ describe('sourceWizardLogic', () => {secret: false,},],- },+ }),})expect(res).toEqual({ prefix: '', description: '', payload: { test_field: '' } })@@ -180,10 +180,8 @@ describe('sourceWizardLogic', () => {it('returns defaults for pure select field', async () => {const sourceWizardLogic = await import('../sourceWizardLogic')const res = sourceWizardLogic.buildKeaFormDefaultFromSourceDetails({- Test: {+ Test: buildSourceConfig({name: 'Stripe',- iconPath: '',- caption: null,fields: [{name: 'test_field',@@ -194,7 +192,7 @@ describe('sourceWizardLogic', () => {defaultValue: 'value1',},],- },+ }),})expect(res).toEqual({ prefix: '', description: '', payload: { test_field: 'value1' } })@@ -203,10 +201,8 @@ describe('sourceWizardLogic', () => {it('returns an array default for a multiple select field', async () => {const sourceWizardLogic = await import('../sourceWizardLogic')const res = sourceWizardLogic.buildKeaFormDefaultFromSourceDetails({- Test: {+ Test: buildSourceConfig({name: 'GoogleSearchConsole',- iconPath: '',- caption: null,fields: [{name: 'search_types',@@ -221,7 +217,7 @@ describe('sourceWizardLogic', () => {defaultValue: 'web',},],- },+ }),})expect(res).toEqual({ prefix: '', description: '', payload: { search_types: ['web'] } })@@ -230,10 +226,8 @@ describe('sourceWizardLogic', () => {it('returns defaults for select field with fields', async () => {const sourceWizardLogic = await import('../sourceWizardLogic')const res = sourceWizardLogic.buildKeaFormDefaultFromSourceDetails({- Test: {+ Test: buildSourceConfig({name: 'Stripe',- iconPath: '',- caption: null,fields: [{name: 'test_field',@@ -259,7 +253,7 @@ describe('sourceWizardLogic', () => {defaultValue: 'value1',},],- },+ }),})expect(res).toEqual({@@ -272,10 +266,8 @@ describe('sourceWizardLogic', () => {it('returns defaults for switch group field - default disabled', async () => {const sourceWizardLogic = await import('../sourceWizardLogic')const res = sourceWizardLogic.buildKeaFormDefaultFromSourceDetails({- Test: {+ Test: buildSourceConfig({name: 'Stripe',- iconPath: '',- caption: null,fields: [{name: 'test_field',@@ -294,7 +286,7 @@ describe('sourceWizardLogic', () => {],},],- },+ }),})expect(res).toEqual({@@ -307,10 +299,8 @@ describe('sourceWizardLogic', () => {it('returns defaults for switch group field - default enabled', async () => {const sourceWizardLogic = await import('../sourceWizardLogic')const res = sourceWizardLogic.buildKeaFormDefaultFromSourceDetails({- Test: {+ Test: buildSourceConfig({name: 'Stripe',- iconPath: '',- caption: null,fields: [{name: 'test_field',@@ -329,7 +319,7 @@ describe('sourceWizardLogic', () => {],},],- },+ }),})expect(res).toEqual({@@ -775,12 +765,7 @@ describe('sourceWizardLogic', () => {// Reducer guards for permission_error rows (Stripe scope gating).describe('permission_error sync gating', () => {- const stripeSource = {- name: 'Stripe',- iconPath: '',- caption: null,- fields: [],- } as SourceConfig+ const stripeSource = buildSourceConfig({ name: 'Stripe' })const buildSchema = (overrides: Partial<ExternalDataSourceSyncSchema> = {}): ExternalDataSourceSyncSchema =>({@@ -964,12 +949,7 @@ describe('sourceWizardLogic', () => {// Onboarding one-click setup: autoConfigureTables opts every syncable table in so the user// can sync the whole source without touching the schema step.describe('autoConfigureTables', () => {- const stripeSource = {- name: 'Stripe',- iconPath: '',- caption: null,- fields: [],- } as SourceConfig+ const stripeSource = buildSourceConfig({ name: 'Stripe' })const apiSchema = (overrides: Partial<ExternalDataSourceSyncSchema> = {}): ExternalDataSourceSyncSchema =>({@@ -1055,12 +1035,7 @@ describe('sourceWizardLogic', () => {// Signals setup passes requiredTables to skip the schema step and sync just those tables.describe('requiredTables', () => {- const githubSource = {- name: 'Github',- iconPath: '',- caption: null,- fields: [],- } as SourceConfig+ const githubSource = buildSourceConfig({ name: 'Github' })const apiSchema = (table: string,@@ -1232,8 +1207,8 @@ describe('sourceWizardLogic', () => {// columns as default cursors; anything else falls back to full refresh instead of a cursor// that never advances (see resolveUpdateTrackedIncrementalField).describe('Supabase incremental defaults', () => {- const supabaseSource = { name: 'Supabase', iconPath: '', caption: null, fields: [] } as SourceConfig- const postgresSource = { name: 'Postgres', iconPath: '', caption: null, fields: [] } as SourceConfig+ const supabaseSource = buildSourceConfig({ name: 'Supabase' })+ const postgresSource = buildSourceConfig({ name: 'Postgres' })const apiSchema = (table: string,@@ -1267,7 +1242,7 @@ describe('sourceWizardLogic', () => {]const mountAndLoadSchemas = async (- source: SourceConfig+ source: SourceConfigResponseApi): Promise<{ logic: ReturnType<typeof sourceWizardLogic>; unmount: () => void }> => {const logic = sourceWizardLogic({ availableSources: { [source.name]: source } })const unmount = logic.mount()diff --git a/products/data_warehouse/frontend/scenes/SourceConnectScene/sourceConnectSceneLogic.test.ts b/products/data_warehouse/frontend/scenes/SourceConnectScene/sourceConnectSceneLogic.test.tsindex 0dff06d4403a..8f3c194867c5 100644--- a/products/data_warehouse/frontend/scenes/SourceConnectScene/sourceConnectSceneLogic.test.ts+++ b/products/data_warehouse/frontend/scenes/SourceConnectScene/sourceConnectSceneLogic.test.ts@@ -1,19 +1,20 @@import { router } from 'kea-router'import { useMocks } from '~/mocks/jest'-import type { SourceConfig } from '~/queries/schema/schema-general'import { initKeaTests } from '~/test/init'+import type { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'+import { availableSourcesLogic } from '../NewSourceScene/availableSourcesLogic'import { sourceConnectSceneLogic } from './sourceConnectSceneLogic'-const AVAILABLE_SOURCES: Record<string, SourceConfig> = {+const AVAILABLE_SOURCES: Record<string, SourceConfigResponseApi> = {Postgres: {name: 'Postgres',iconPath: '',caption: '',fields: [{ type: 'text', name: 'host', label: 'Host', required: true, placeholder: '' }],- } as unknown as SourceConfig,+ } as unknown as SourceConfigResponseApi,Hubspot: {name: 'Hubspot',iconPath: '',@@ -27,7 +28,7 @@ const AVAILABLE_SOURCES: Record<string, SourceConfig> = {kind: 'hubspot',},],- } as unknown as SourceConfig,+ } as unknown as SourceConfigResponseApi,Stripe: {name: 'Stripe',iconPath: '',@@ -69,7 +70,7 @@ const AVAILABLE_SOURCES: Record<string, SourceConfig> = {],},],- } as unknown as SourceConfig,+ } as unknown as SourceConfigResponseApi,}describe('sourceConnectSceneLogic', () => {diff --git a/products/data_warehouse/frontend/scenes/SourceConnectScene/sourceConnectSceneLogic.tsx b/products/data_warehouse/frontend/scenes/SourceConnectScene/sourceConnectSceneLogic.tsxindex a983b5648d0b..8528b4aa71f1 100644--- a/products/data_warehouse/frontend/scenes/SourceConnectScene/sourceConnectSceneLogic.tsx+++ b/products/data_warehouse/frontend/scenes/SourceConnectScene/sourceConnectSceneLogic.tsx@@ -9,10 +9,11 @@ import { Scene } from 'scenes/sceneTypes'import { urls } from 'scenes/urls'import { ApiConfig } from '~/lib/api'-import { SourceConfig, SourceFieldConfig } from '~/queries/schema/schema-general'import { Breadcrumb } from '~/types'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'import { externalDataSourcesStoreCredentialsCreate } from 'products/warehouse_sources/frontend/generated/api'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import type { SourceCredentialApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { availableSourcesLogic } from '../NewSourceScene/availableSourcesLogic'@@ -60,7 +61,7 @@ const buildCredentialsPayload = async (// Generated by kea-typegen. Update if you're an agent, ignore if you're human.export interface sourceConnectSceneLogicValues {- availableSources: Record<string, SourceConfig> | null // availableSourcesLogic+ availableSources: Record<string, SourceConfigResponseApi> | null // availableSourcesLogicavailableSourcesLoading: boolean // availableSourcesLogicbreadcrumbs: Breadcrumb[]credentialsForm: Record<string, any>@@ -76,7 +77,7 @@ export interface sourceConnectSceneLogicValues {isCredentialsFormValid: booleankind: string | nullshowCredentialsFormErrors: boolean- sourceConfig: SourceConfig | null+ sourceConfig: SourceConfigResponseApi | nullstoredCredential: SourceCredentialApi | null}@@ -129,10 +130,10 @@ export interface sourceConnectSceneLogicActions {export interface sourceConnectSceneLogicMeta {__keaTypeGenInternalSelectorTypes: {sourceConfig: (- availableSources: Record<string, SourceConfig> | null,+ availableSources: Record<string, SourceConfigResponseApi> | null,kind: string | null- ) => SourceConfig | null- breadcrumbs: (sourceConfig: SourceConfig | null) => Breadcrumb[]+ ) => SourceConfigResponseApi | null+ breadcrumbs: (sourceConfig: SourceConfigResponseApi | null) => Breadcrumb[]}}@@ -169,7 +170,10 @@ export const sourceConnectSceneLogic = kea<sourceConnectSceneLogicType>([selectors({sourceConfig: [(s) => [s.availableSources, s.kind],- (availableSources: Record<string, SourceConfig> | null, kind: string | null): SourceConfig | null => {+ (+ availableSources: Record<string, SourceConfigResponseApi> | null,+ kind: string | null+ ): SourceConfigResponseApi | null => {if (!availableSources || !kind) {return null}@@ -182,7 +186,7 @@ export const sourceConnectSceneLogic = kea<sourceConnectSceneLogicType>([],breadcrumbs: [(s) => [s.sourceConfig],- (sourceConfig: SourceConfig | null): Breadcrumb[] => [+ (sourceConfig: SourceConfigResponseApi | null): Breadcrumb[] => [{key: Scene.Sources,name: 'Sources',diff --git a/products/data_warehouse/frontend/scenes/SourceScene/tabs/WebhookTab.tsx b/products/data_warehouse/frontend/scenes/SourceScene/tabs/WebhookTab.tsxindex 717c14f8115f..6de3a36ccb14 100644--- a/products/data_warehouse/frontend/scenes/SourceScene/tabs/WebhookTab.tsx+++ b/products/data_warehouse/frontend/scenes/SourceScene/tabs/WebhookTab.tsx@@ -12,9 +12,11 @@ import { LemonCard } from 'lib/lemon-ui/LemonCard'import { LemonDialog } from 'lib/lemon-ui/LemonDialog'import { copyToClipboard } from 'lib/utils/copyToClipboard'-import { SourceConfig, SourceFieldConfig } from '~/queries/schema/schema-general'import { WebhookInfo } from '~/types'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'+import { sourceFieldToElement } from '../../../shared/components/forms/SourceForm'import {WebhookRefreshButton,@@ -203,7 +205,7 @@ function WebhookConfigurationSection({sourceConfig,formLogicProps,}: {- sourceConfig: SourceConfig+ sourceConfig: SourceConfigResponseApiformLogicProps: { id: string }}): JSX.Element {const { webhookFieldInputs, isWebhookFieldInputsSubmitting } = useValues(webhookTabLogic(formLogicProps))diff --git a/products/data_warehouse/frontend/scenes/SourceScene/tabs/sourceSettingsLogic.test.ts b/products/data_warehouse/frontend/scenes/SourceScene/tabs/sourceSettingsLogic.test.tsindex a89da30dedb4..c7c92951ba2a 100644--- a/products/data_warehouse/frontend/scenes/SourceScene/tabs/sourceSettingsLogic.test.ts+++ b/products/data_warehouse/frontend/scenes/SourceScene/tabs/sourceSettingsLogic.test.ts@@ -1,6 +1,6 @@-import type { SourceFieldConfig } from '~/queries/schema/schema-general'import type { ExternalDataSource, ExternalDataSourceSchema } from '~/types'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'import { clampSyncFrequency } from 'products/data_warehouse/frontend/utils'import {diff --git a/products/data_warehouse/frontend/scenes/SourceScene/tabs/sourceSettingsLogic.ts b/products/data_warehouse/frontend/scenes/SourceScene/tabs/sourceSettingsLogic.tsindex ab8c98f33b6f..d899b90976c1 100644--- a/products/data_warehouse/frontend/scenes/SourceScene/tabs/sourceSettingsLogic.ts+++ b/products/data_warehouse/frontend/scenes/SourceScene/tabs/sourceSettingsLogic.ts@@ -26,7 +26,6 @@ import { objectsEqual } from 'lib/utils/objects'import { pluralize } from 'lib/utils/strings'import { urls } from 'scenes/urls'-import { SourceConfig, SourceFieldConfig } from '~/queries/schema/schema-general'import {DataWarehouseSyncInterval,ExternalDataJob,@@ -37,7 +36,9 @@ import {} from '~/types'import { groupTablesBySchema } from 'products/data_warehouse/frontend/shared/components/forms/schemaGroupingUtils'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'import { SYNC_FREQUENCY_ORDER, SyncTypeLabelMap, clampSyncFrequency } from 'products/data_warehouse/frontend/utils'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { sourcesDataLogic } from '../../../shared/logics/sourcesDataLogic'import { availableSourcesLogic } from '../../NewSourceScene/availableSourcesLogic'@@ -46,7 +47,7 @@ import { sourceSceneLogic } from '../SourceScene'export interface SourceSettingsLogicProps {id: string- availableSources?: Record<string, SourceConfig>+ availableSources?: Record<string, SourceConfigResponseApi>}export interface CdcStatus {@@ -392,7 +393,7 @@ function reportBulkResult(verb: string, total: number, failed: number, skipped:// Generated by kea-typegen. Update if you're an agent, ignore if you're human.export interface sourceSettingsLogicValues {- availableSources: Record<string, SourceConfig> | null // availableSourcesLogic+ availableSources: Record<string, SourceConfigResponseApi> | null // availableSourcesLogicbulkEnableLoading: booleancanLoadMoreJobs: booleancdcStatus: CdcStatus | null@@ -432,7 +433,7 @@ export interface sourceSettingsLogicValues {sourceConfigTouched: booleansourceConfigTouches: Record<string, boolean>sourceConfigValidationErrors: DeepPartialMap<Record<string, any>, ValidationErrorType>- sourceFieldConfig: SourceConfig | null+ sourceFieldConfig: SourceConfigResponseApi | nullsourceId: stringsourceLoading: booleanstatusFilter: string | null@@ -677,8 +678,8 @@ export interface sourceSettingsLogicMeta {__keaTypeGenInternalSelectorTypes: {sourceFieldConfig: (source: ExternalDataSource | null,- availableSources: Record<string, SourceConfig> | null- ) => SourceConfig | null+ availableSources: Record<string, SourceConfigResponseApi> | null+ ) => SourceConfigResponseApi | nullinProgressRowsBySchema: (jobs: ExternalDataJob[]) => Record<string, number>filteredSchemas: (source: ExternalDataSource | null,@@ -960,7 +961,7 @@ export const sourceSettingsLogic = kea<sourceSettingsLogicType>([selectors({sourceFieldConfig: [(s) => [s.source, s.availableSources],- (source: ExternalDataSource | null, availableSources: Record<string, SourceConfig> | null) => {+ (source: ExternalDataSource | null, availableSources: Record<string, SourceConfigResponseApi> | null) => {if (!source || !availableSources) {return null}diff --git a/products/data_warehouse/frontend/scenes/SourceScene/tabs/webhookTabLogic.ts b/products/data_warehouse/frontend/scenes/SourceScene/tabs/webhookTabLogic.tsindex 819365372962..0a84fafe8ae5 100644--- a/products/data_warehouse/frontend/scenes/SourceScene/tabs/webhookTabLogic.ts+++ b/products/data_warehouse/frontend/scenes/SourceScene/tabs/webhookTabLogic.ts@@ -8,9 +8,10 @@ import { lemonToast } from '@posthog/lemon-ui'import api from 'lib/api'-import { SourceConfig } from '~/queries/schema/schema-general'import { ExternalDataSource, WebhookInfo } from '~/types'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'+import type { WebhookCreateResult } from '../../../shared/components/forms/WebhookSetupForm'import { getErrorsForFields } from '../../NewSourceScene/sourceWizardLogic'import { sourceSettingsLogic } from './sourceSettingsLogic'@@ -45,7 +46,7 @@ export interface webhookTabLogicValues {}[]showWebhookFieldInputsErrors: booleansource: ExternalDataSource | null- sourceConfig: SourceConfig | null+ sourceConfig: SourceConfigResponseApi | nullwebhookCreating: booleanwebhookDeleting: booleanwebhookFieldInputs: Record<string, any>@@ -144,7 +145,7 @@ export interface webhookTabLogicMeta {key: string__keaTypeGenInternalSelectorTypes: {source: (arg: ExternalDataSource | null) => ExternalDataSource | null- sourceConfig: (arg: SourceConfig | null) => SourceConfig | null+ sourceConfig: (arg: SourceConfigResponseApi | null) => SourceConfigResponseApi | nullinternalStateLabel: (webhookInfo: WebhookInfo | null) => {label: stringtagType: 'danger' | 'default' | 'success' | 'warning'@@ -244,7 +245,7 @@ export const webhookTabLogic = kea<webhookTabLogicType>([availableSources: {},}).selectors.sourceFieldConfig(state),],- (sourceFieldConfig: SourceConfig | null): SourceConfig | null => sourceFieldConfig,+ (sourceFieldConfig: SourceConfigResponseApi | null): SourceConfigResponseApi | null => sourceFieldConfig,],internalStateLabel: [(s) => [s.webhookInfo],diff --git a/products/data_warehouse/frontend/shared/components/DataWarehouseWizardBlock.tsx b/products/data_warehouse/frontend/shared/components/DataWarehouseWizardBlock.tsxindex 8776c8a89c57..89252ee2910a 100644--- a/products/data_warehouse/frontend/shared/components/DataWarehouseWizardBlock.tsx+++ b/products/data_warehouse/frontend/shared/components/DataWarehouseWizardBlock.tsx@@ -1,12 +1,18 @@import { CommandBlock } from 'lib/components/CommandBlock/CommandBlock'import { useWizardCommand } from 'scenes/onboarding/shared/useWizardCommand'-import { ExternalDataSourceType } from '~/queries/schema/schema-general'+import { ExternalDataSourceTypeEnumApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { SourceIcon } from './SourceIcon'// Database sources the warehouse wizard can detect and connect from a codebase.-const WIZARD_DETECTABLE_SOURCES: ExternalDataSourceType[] = ['Postgres', 'MySQL', 'Supabase', 'MongoDB', 'BigQuery']+const WIZARD_DETECTABLE_SOURCES: ExternalDataSourceTypeEnumApi[] = [+ 'Postgres',+ 'MySQL',+ 'Supabase',+ 'MongoDB',+ 'BigQuery',+]export function DataWarehouseWizardBlock(): JSX.Element {const { wizardCommand, isCloudOrDev } = useWizardCommand('warehouse')diff --git a/products/data_warehouse/frontend/shared/components/InlineSourceSetup.tsx b/products/data_warehouse/frontend/shared/components/InlineSourceSetup.tsxindex 5d1b51294985..58c66a764705 100644--- a/products/data_warehouse/frontend/shared/components/InlineSourceSetup.tsx+++ b/products/data_warehouse/frontend/shared/components/InlineSourceSetup.tsx@@ -5,7 +5,10 @@ import { useEffect, useState } from 'react'import { IconDatabase, IconPlus } from '@posthog/icons'import { LemonButton, LemonCard, LemonInput, LemonSkeleton } from '@posthog/lemon-ui'-import { ExternalDataSourceType, SourceConfig } from '~/queries/schema/schema-general'+import {+ ExternalDataSourceTypeEnumApi,+ SourceConfigResponseApi,+} from 'products/warehouse_sources/frontend/generated/api.schemas'import { availableSourcesLogic } from '../../scenes/NewSourceScene/availableSourcesLogic'import { AvailableSourcesError, NewSourcesWizard } from '../../scenes/NewSourceScene/NewSourceScene'@@ -16,7 +19,7 @@ import { SourceIcon } from './SourceIcon'export type InlineSourceSetupView = 'selection' | 'connecting'interface SourceItem {- id: ExternalDataSourceType+ id: ExternalDataSourceTypeEnumApilabel: string}@@ -37,8 +40,8 @@ export interface InlineSourceSetupProps {interface InternalInlineSourceSetupProps extends InlineSourceSetupProps {currentView: InlineSourceSetupView- selectedSource: ExternalDataSourceType | null- onSourceSelect: (sourceId: ExternalDataSourceType) => void+ selectedSource: ExternalDataSourceTypeEnumApi | null+ onSourceSelect: (sourceId: ExternalDataSourceTypeEnumApi) => voidonBack: () => voidonFormSuccess: () => void}@@ -63,7 +66,7 @@ function InternalInlineSourceSetup({const [searchQuery, setSearchQuery] = useState('')// Filter out unreleased sources- const availableConnectors = connectors.filter((c: SourceConfig) => !c.unreleasedSource)+ const availableConnectors = connectors.filter((c: SourceConfigResponseApi) => !c.unreleasedSource)// Resume an OAuth round-trip: an OAuth source redirects the whole page to the provider and// back to this onboarding URL with ?kind=<source>. On mount, re-open the wizard for that@@ -84,20 +87,22 @@ function InternalInlineSourceSetup({replace(location.pathname, restParams)// oxlint-disable-next-line react-hooks/exhaustive-deps}, [])- const featuredSources = availableConnectors.filter((c: SourceConfig) => c.featured)- const hiddenSources = availableConnectors.filter((c: SourceConfig) => !c.featured)+ const featuredSources = availableConnectors.filter((c: SourceConfigResponseApi) => c.featured)+ const hiddenSources = availableConnectors.filter((c: SourceConfigResponseApi) => !c.featured)const trimmedQuery = searchQuery.trim().toLowerCase()const isSearching = trimmedQuery.length > 0// While searching, match across every source — the featured/expand split only applies// to the default (unsearched) view.const sourcesToShow = isSearching- ? availableConnectors.filter((c: SourceConfig) => (c.label ?? c.name).toLowerCase().includes(trimmedQuery))+ ? availableConnectors.filter((c: SourceConfigResponseApi) =>+ (c.label ?? c.name).toLowerCase().includes(trimmedQuery)+ ): expanded? availableConnectors: featuredSources- const sourceItems: SourceItem[] = sourcesToShow.map((source: SourceConfig) => ({+ const sourceItems: SourceItem[] = sourcesToShow.map((source: SourceConfigResponseApi) => ({id: source.name,label: source.label ?? source.name,}))@@ -179,7 +184,7 @@ function InternalInlineSourceSetup({<NewSourcesWizardhideBackButtononComplete={onFormSuccess}- allowedSources={availableConnectors.map((c: SourceConfig) => c.name)}+ allowedSources={availableConnectors.map((c: SourceConfigResponseApi) => c.name)}initialSource={selectedSource}autoConfigureTables={autoConfigureTables}/>@@ -195,7 +200,7 @@ export function InlineSourceSetup(props: InlineSourceSetupProps): JSX.Element {const { onClear } = useActions(sourceWizardLogic)const [currentView, setCurrentView] = useState<InlineSourceSetupView>('selection')- const [selectedSource, setSelectedSource] = useState<ExternalDataSourceType | null>(null)+ const [selectedSource, setSelectedSource] = useState<ExternalDataSourceTypeEnumApi | null>(null)// Defined once here and bound as the logic's `onComplete` below, so the wizard's step-5// completion listener always sees this same callback — never the logic's unbound default —@@ -208,7 +213,7 @@ export function InlineSourceSetup(props: InlineSourceSetupProps): JSX.Element {props.onComplete?.()}- const handleSourceSelect = (sourceId: ExternalDataSourceType): void => {+ const handleSourceSelect = (sourceId: ExternalDataSourceTypeEnumApi): void => {setSelectedSource(sourceId)setCurrentView('connecting')}diff --git a/products/data_warehouse/frontend/shared/components/SourceReleaseTag.tsx b/products/data_warehouse/frontend/shared/components/SourceReleaseTag.tsxindex 56d572adf8a2..15991b10d586 100644--- a/products/data_warehouse/frontend/shared/components/SourceReleaseTag.tsx+++ b/products/data_warehouse/frontend/shared/components/SourceReleaseTag.tsx@@ -2,10 +2,10 @@ import { LemonTag } from '@posthog/lemon-ui'import { Tooltip } from 'lib/lemon-ui/Tooltip'-import { SourceConfig } from '~/queries/schema/schema-general'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'export interface SourceReleaseTagProps {- releaseStatus?: SourceConfig['releaseStatus']+ releaseStatus?: SourceConfigResponseApi['releaseStatus']}export function SourceReleaseTag({ releaseStatus }: SourceReleaseTagProps): JSX.Element | null {diff --git a/products/data_warehouse/frontend/shared/components/forms/IntegrationAccountSelector.tsx b/products/data_warehouse/frontend/shared/components/forms/IntegrationAccountSelector.tsxindex 504fe2a1bf94..d512c320c4b2 100644--- a/products/data_warehouse/frontend/shared/components/forms/IntegrationAccountSelector.tsx+++ b/products/data_warehouse/frontend/shared/components/forms/IntegrationAccountSelector.tsx@@ -13,7 +13,7 @@ import type { LemonInputSelectOption } from 'lib/lemon-ui/LemonInputSelect/Lemonimport { LemonMarkdown } from 'lib/lemon-ui/LemonMarkdown'import { eventUsageLogic } from 'lib/utils/eventUsageLogic'-import type { SourceFieldConfig } from '~/queries/schema/schema-general'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'import { InputSuggestion, InputWithSuggestionsDropdown } from './InputWithSuggestionsDropdown'diff --git a/products/data_warehouse/frontend/shared/components/forms/IntegrationChoice.tsx b/products/data_warehouse/frontend/shared/components/forms/IntegrationChoice.tsxindex 44be7aeb50ff..e4a4488dd879 100644--- a/products/data_warehouse/frontend/shared/components/forms/IntegrationChoice.tsx+++ b/products/data_warehouse/frontend/shared/components/forms/IntegrationChoice.tsx@@ -7,12 +7,12 @@ import {} from 'lib/components/CyclotronJob/integrations/IntegrationChoice'import { urls } from 'scenes/urls'-import { SourceConfig } from '~/queries/schema/schema-general'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { sourceWizardLogic } from '../../../scenes/NewSourceScene/sourceWizardLogic'export type SourceIntegrationChoiceProps = IntegrationConfigureProps & {- sourceConfig: SourceConfig+ sourceConfig: SourceConfigResponseApi}export function SourceIntegrationChoice({diff --git a/products/data_warehouse/frontend/shared/components/forms/SourceForm.test.tsx b/products/data_warehouse/frontend/shared/components/forms/SourceForm.test.tsxindex 58ef9c18ee26..131992319ab4 100644--- a/products/data_warehouse/frontend/shared/components/forms/SourceForm.test.tsx+++ b/products/data_warehouse/frontend/shared/components/forms/SourceForm.test.tsx@@ -3,15 +3,15 @@ import '@testing-library/jest-dom'import { cleanup, render, screen } from '@testing-library/react'import {- SourceConfig,- SourceFieldInputConfig,- SourceFieldSelectConfig,- SourceFieldSwitchGroupConfig,-} from '~/queries/schema/schema-general'+ SourceConfigResponseApi,+ SourceFieldInputConfigApi,+ SourceFieldSelectConfigApi,+ SourceFieldSwitchGroupConfigApi,+} from 'products/warehouse_sources/frontend/generated/api.schemas'import { sourceFieldToElement } from './SourceForm'-const SELECT_FIELD: SourceFieldSelectConfig = {+const SELECT_FIELD: SourceFieldSelectConfigApi = {type: 'select',name: 'response_types',label: 'Responses to sync',@@ -24,9 +24,9 @@ const SELECT_FIELD: SourceFieldSelectConfig = {caption: 'Changing this triggers a full refresh of the responses table.',}-const SOURCE_CONFIG = { name: 'Typeform', fields: [] } as unknown as SourceConfig+const SOURCE_CONFIG = { name: 'Typeform', fields: [] } as unknown as SourceConfigResponseApi-const SWITCH_GROUP_FIELD: SourceFieldSwitchGroupConfig = {+const SWITCH_GROUP_FIELD: SourceFieldSwitchGroupConfigApi = {type: 'switch-group',name: 'custom_properties',label: 'Customize synced properties',@@ -56,7 +56,7 @@ const switchGroupState = (storedGroupValue: any, formValue?: any): { checked: boreturn { checked: toggle.props.checked, childrenVisible: !!children.find((child: any) => child?.props?.name) }}-const CONNECTION_STRING_FIELD: SourceFieldInputConfig = {+const CONNECTION_STRING_FIELD: SourceFieldInputConfigApi = {type: 'text',name: 'connection_string',label: 'Connection string (optional)',@@ -65,7 +65,7 @@ const CONNECTION_STRING_FIELD: SourceFieldInputConfig = {secret: true,}-const POSTGRES_CONFIG = { name: 'Postgres', fields: [] } as unknown as SourceConfig+const POSTGRES_CONFIG = { name: 'Postgres', fields: [] } as unknown as SourceConfigResponseApi// Renders the connection string field at a given value and reports whether it tells the user the// string didn't parse.diff --git a/products/data_warehouse/frontend/shared/components/forms/SourceForm.tsx b/products/data_warehouse/frontend/shared/components/forms/SourceForm.tsxindex 9cb2ca433bee..55333a8d029b 100644--- a/products/data_warehouse/frontend/shared/components/forms/SourceForm.tsx+++ b/products/data_warehouse/frontend/shared/components/forms/SourceForm.tsx@@ -26,7 +26,8 @@ import { lemonToast } from 'lib/lemon-ui/LemonToast'import { featureFlagLogic } from 'lib/logic/featureFlagLogic'import { organizationLogic } from 'scenes/organizationLogic'-import { SourceConfig, SourceFieldConfig } from '~/queries/schema/schema-general'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { availableSourcesLogic } from '../../../scenes/NewSourceScene/availableSourcesLogic'import {@@ -47,7 +48,7 @@ import { supportsDirectQuery } from './schemaGroupingUtils'const NO_OP_SET_VALUE = (): void => undefinedexport interface SourceFormProps {- sourceConfig: SourceConfig+ sourceConfig: SourceConfigResponseApishowPrefix?: booleanshowDescription?: booleanshowAccessMethodSelector?: boolean@@ -141,7 +142,7 @@ export function SourceAccessMethodSelector({export const sourceFieldToElement = (field: SourceFieldConfig,- sourceConfig: SourceConfig,+ sourceConfig: SourceConfigResponseApi,lastValue?: any,isUpdateMode?: boolean,setSourceConnectionDetailsValue?: (key: FieldName, value: any) => void,@@ -388,9 +389,9 @@ export const sourceFieldToElement = (integrationField={field.integrationField}integrationKind={field.integrationKind}sourceType={sourceConfig.name}- placeholder={field.placeholder}- caption={field.caption}- multiple={field.multiple}+ placeholder={field.placeholder ?? undefined}+ caption={field.caption ?? undefined}+ multiple={field.multiple ?? undefined}legacySingleField={legacySingleField}oauthBranch={findOauthBranch(sourceConfig.fields, field.integrationField)}/>@@ -404,7 +405,7 @@ export const sourceFieldToElement = (<div className="bg-fill-input p-2 border rounded-[var(--radius)]"><LemonFileInputvalue={value}- accept={field.fileFormat.format}+ accept={field.fileFormat.format ?? '.json'}multiple={false}onChange={onChange}/>@@ -425,19 +426,24 @@ export const sourceFieldToElement = ()}+ // Every other field type returned above, so what is left renders as a plain input.+ const inputField = field+return (<LemonField- key={field.name}- name={field.name}- label={field.label}- help={field.caption ? <LemonMarkdown className="text-xs">{field.caption}</LemonMarkdown> : undefined}+ key={inputField.name}+ name={inputField.name}+ label={inputField.label}+ help={+ inputField.caption ? <LemonMarkdown className="text-xs">{inputField.caption}</LemonMarkdown> : undefined+ }>{({ value, onChange }) => (<LemonInputclassName="ph-ignore-input"- data-attr={field.name}- placeholder={field.placeholder}- type={field.type as 'text'}+ data-attr={inputField.name}+ placeholder={inputField.placeholder}+ type={inputField.type as 'text'}value={value || ''}onChange={onChange}/>diff --git a/products/data_warehouse/frontend/shared/components/forms/WebhookSetupForm.test.tsx b/products/data_warehouse/frontend/shared/components/forms/WebhookSetupForm.test.tsxindex 0255c619db7e..046f2b57b3bd 100644--- a/products/data_warehouse/frontend/shared/components/forms/WebhookSetupForm.test.tsx+++ b/products/data_warehouse/frontend/shared/components/forms/WebhookSetupForm.test.tsx@@ -2,21 +2,21 @@ import '@testing-library/jest-dom'import { cleanup, fireEvent, render, screen } from '@testing-library/react'-import { SourceConfig } from '~/queries/schema/schema-general'+import type { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { WebhookSetupForm } from './WebhookSetupForm'const FAILED_RESULT = { success: false, webhook_url: 'https://example.com/hook', error: 'Store rejected the request' }function renderFallback(- sourceConfig: Partial<SourceConfig>,+ sourceConfig: Partial<SourceConfigResponseApi>,onCreateWebhook: () => void = jest.fn(),autoCreationBlockedReason?: string): void {render(<WebhookSetupFormsourceName="WooCommerce"- sourceConfig={{ name: 'WooCommerce', fields: [], ...sourceConfig } as unknown as SourceConfig}+ sourceConfig={{ name: 'WooCommerce', fields: [], ...sourceConfig } as unknown as SourceConfigResponseApi}webhookResult={FAILED_RESULT}webhookCreating={false}autoCreationBlockedReason={autoCreationBlockedReason}diff --git a/products/data_warehouse/frontend/shared/components/forms/WebhookSetupForm.tsx b/products/data_warehouse/frontend/shared/components/forms/WebhookSetupForm.tsxindex 6abacd336b1c..f079b46bfc23 100644--- a/products/data_warehouse/frontend/shared/components/forms/WebhookSetupForm.tsx+++ b/products/data_warehouse/frontend/shared/components/forms/WebhookSetupForm.tsx@@ -9,7 +9,8 @@ import { LemonMarkdown } from 'lib/lemon-ui/LemonMarkdown'import { Link } from 'lib/lemon-ui/Link'import { copyToClipboard } from 'lib/utils/copyToClipboard'-import { SourceConfig, SourceFieldConfig } from '~/queries/schema/schema-general'+import type { SourceFieldConfig } from 'products/data_warehouse/frontend/types'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { sourceFieldToElement } from './SourceForm'@@ -28,7 +29,7 @@ export interface WebhookCreateResult {interface WebhookSetupFormProps {sourceName: string- sourceConfig?: SourceConfig | null+ sourceConfig?: SourceConfigResponseApi | nullwebhookTables?: { name: string; label?: string | null }[]webhookResult?: WebhookCreateResult | nullwebhookCreating: booleandiff --git a/products/data_warehouse/frontend/shared/logics/sourceManagementLogic.ts b/products/data_warehouse/frontend/shared/logics/sourceManagementLogic.tsindex f9969fa89286..d1c7bfa57e7e 100644--- a/products/data_warehouse/frontend/shared/logics/sourceManagementLogic.ts+++ b/products/data_warehouse/frontend/shared/logics/sourceManagementLogic.ts@@ -30,11 +30,9 @@ import {} from '~/types'import type { PaginatedResponse } from '../../../../../frontend/src/lib/api'-import type {- DatabaseSchemaQueryResponse,- SourceConfig,-} from '../../../../../frontend/src/queries/schema/schema-general'+import type { DatabaseSchemaQueryResponse } from '../../../../../frontend/src/queries/schema/schema-general'import type { ExternalDataSourceRevenueAnalyticsConfig } from '../../../../../frontend/src/types'+import type { SourceConfigResponseApi } from '../../../../warehouse_sources/frontend/generated/api.schemas'import { availableSourcesLogic } from '../../scenes/NewSourceScene/availableSourcesLogic'import { joinsLogic } from './joinsLogic'import { sourcesDataLogic } from './sourcesDataLogic'@@ -68,7 +66,7 @@ const shouldPollSources = (): boolean => SOURCE_LIST_PATHS.includes(router.value// Generated by kea-typegen. Update if you're an agent, ignore if you're human.export interface sourceManagementLogicValues {- availableSources: Record<string, SourceConfig> | null // availableSourcesLogic+ availableSources: Record<string, SourceConfigResponseApi> | null // availableSourcesLogicdataWarehouseTables: DatabaseSchemaDataWarehouseTable[] // databaseTableListLogicdatabase: Required<DatabaseSchemaQueryResponse> | null // databaseTableListLogicdatabaseLoading: boolean // databaseTableListLogic@@ -215,7 +213,7 @@ export interface sourceManagementLogicMeta {filteredDirectSources: (directSources: ExternalDataSource[], directSearchTerm: string) => ExternalDataSource[]managedSourcesFuse: (managedSources: ExternalDataSource[],- availableSources: Record<string, SourceConfig> | null+ availableSources: Record<string, SourceConfigResponseApi> | null) => Fuse<ExternalDataSource>filteredManagedSources: (managedSources: ExternalDataSource[],@@ -403,7 +401,7 @@ export const sourceManagementLogic = kea<sourceManagementLogicType>([(s) => [s.managedSources, s.availableSources],(managedSources: ExternalDataSource[],- availableSources: Record<string, import('~/queries/schema').SourceConfig> | null+ availableSources: Record<string, SourceConfigResponseApi> | null): Fuse<ExternalDataSource> =>createFuse(managedSources, {keys: [diff --git a/products/data_warehouse/frontend/types.ts b/products/data_warehouse/frontend/types.tsindex 5b2db43ca2c2..199755ba036f 100644--- a/products/data_warehouse/frontend/types.ts+++ b/products/data_warehouse/frontend/types.ts@@ -1,8 +1,17 @@import { DatabaseSchemaDataWarehouseTable } from '~/queries/schema/schema-general'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'+export type DataWarehouseTableForInsight = DatabaseSchemaDataWarehouseTable & {id_field?: stringtimestamp_field?: stringdistinct_id_field?: stringaggregation_target_field?: string}++/**+ * One entry of a source config's field list. Orval inlines this union in every place the+ * schema uses it, so there is no generated name to import; derive it from the response type+ * instead of restating the member list.+ */+export type SourceFieldConfig = SourceConfigResponseApi['fields'][number]diff --git a/products/signals/frontend/inbox/components/config/DataSourceSetup.tsx b/products/signals/frontend/inbox/components/config/DataSourceSetup.tsxindex 91ffa02a0b5a..663f2391533a 100644--- a/products/signals/frontend/inbox/components/config/DataSourceSetup.tsx+++ b/products/signals/frontend/inbox/components/config/DataSourceSetup.tsx@@ -3,12 +3,11 @@ import { useEffect } from 'react'import { LemonButton, LemonSkeleton } from '@posthog/lemon-ui'-import { SourceConfig } from '~/queries/schema/schema-general'-import { availableSourcesLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/availableSourcesLogic'import { sourceWizardLogic } from 'products/data_warehouse/frontend/scenes/NewSourceScene/sourceWizardLogic'import SourceForm from 'products/data_warehouse/frontend/shared/components/forms/SourceForm'import { SourceIcon } from 'products/data_warehouse/frontend/shared/components/SourceIcon'+import { SourceConfigResponseApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import { WAREHOUSE_SOURCE_SETUP, WarehouseBackedSource } from '../../signalSourcesLogic'@@ -27,7 +26,7 @@ export function DataSourceSetup({return <LemonSkeleton />}- const sourceConfig = Object.values(availableSources).find((s: SourceConfig) => s.name === dwSourceType)+ const sourceConfig = Object.values(availableSources).find((s: SourceConfigResponseApi) => s.name === dwSourceType)if (!sourceConfig) {return <div>Source not found</div>}@@ -46,7 +45,7 @@ export function DataSourceSetup({)}-function DataSourceSetupForm({ sourceConfig }: { sourceConfig: SourceConfig }): JSX.Element {+function DataSourceSetupForm({ sourceConfig }: { sourceConfig: SourceConfigResponseApi }): JSX.Element {const { isLoading, canGoNext } = useValues(sourceWizardLogic)const { setInitialConnector, onSubmit } = useActions(sourceWizardLogic)diff --git a/products/signals/frontend/inbox/signalSourcesLogic.ts b/products/signals/frontend/inbox/signalSourcesLogic.tsindex 40d922e4b50e..572f064b04ab 100644--- a/products/signals/frontend/inbox/signalSourcesLogic.ts+++ b/products/signals/frontend/inbox/signalSourcesLogic.ts@@ -12,7 +12,6 @@ import type { FeatureFlagsSet } from 'lib/logic/featureFlagLogic'import { teamLogic } from 'scenes/teamLogic'import { productEnablementCreate } from '~/generated/core/api'-import { ExternalDataSourceType } from '~/queries/schema/schema-general'import { ExternalDataSource, ExternalDataSourceSchema, TeamPublicType, TeamType } from '~/types'import { sourcesDataLogic } from 'products/data_warehouse/frontend/shared/logics/sourcesDataLogic'@@ -25,6 +24,7 @@ import { eventDefinitionsList } from 'products/event_definitions/frontend/generaimport { visionScannersList, visionScannersPartialUpdate } from 'products/replay_vision/frontend/generated/api'import type { ReplayScannerApi } from 'products/replay_vision/frontend/generated/api.schemas'import { SignalSourceProduct, SignalSourceType } from 'products/signals/frontend/inbox/types'+import { ExternalDataSourceTypeEnumApi } from 'products/warehouse_sources/frontend/generated/api.schemas'import type { SignalSourceTypeApi } from '../generated/api.schemas'import type { AgentRosterSource } from './components/config/agentRosterMeta'@@ -91,7 +91,7 @@ type WarehouseSourceCompletion =export const WAREHOUSE_SOURCE_SETUP: Record<WarehouseBackedSource,{- dwSourceType: ExternalDataSourceType+ dwSourceType: ExternalDataSourceTypeEnumApirequiredTables: string[]completion: WarehouseSourceCompletion}diff --git a/products/warehouse_sources/backend/facade/source_config.py b/products/warehouse_sources/backend/facade/source_config.pynew file mode 100644index 000000000000..72a355eb401e--- /dev/null+++ b/products/warehouse_sources/backend/facade/source_config.py@@ -0,0 +1,374 @@+"""Source of truth for the data warehouse source-config contract.++Every import source describes its setup form with these models. The wizard endpoint and+the public catalog endpoint serialize them, and the frontend types are generated from+this module by drf-spectacular and Orval (``hogli build:openapi``). Change a model here+and rerun that command; do not hand-write the TypeScript counterparts.++Field names stay camelCase because they cross the wire to the frontend unchanged.+"""++from enum import StrEnum+from typing import Annotated, Any, Literal, Union++from pydantic import BaseModel, ConfigDict, Field, RootModel+from pydantic.json_schema import WithJsonSchema++from products.warehouse_sources.backend.facade.types import ExternalDataSourceType++__all__ = [+ "DataWarehouseSourceCategory",+ "ReleaseStatus",+ "SourceConfig",+ "SourceConfigMapResponse",+ "SourceConfigResponse",+ "SourceDocumentedTable",+ "SourceFieldConfig",+ "SourceFieldFileUploadConfig",+ "SourceFieldFileUploadJsonFormatConfig",+ "SourceFieldInputConfig",+ "SourceFieldInputConfigType",+ "SourceFieldOauthAccountSelectConfig",+ "SourceFieldOauthConfig",+ "SourceFieldSSHTunnelConfig",+ "SourceFieldSelectConfig",+ "SourceFieldSelectConfigConverter",+ "SourceFieldSelectConfigOption",+ "SourceFieldSwitchGroupConfig",+ "SourceVersionDeprecation",+ "SuggestedTable",+]+++def _require_type_field(schema: dict[str, Any]) -> None:+ """Keep the `type` discriminant required even though it has a default.++ Pydantic drops defaulted fields from `required`. The generated TS would then mark+ `type` optional and could not narrow the field-config union on it.+ """+ if "type" not in schema["properties"]:+ return+ required = {*schema.get("required", []), "type"}+ schema["required"] = [name for name in schema["properties"] if name in required]+++_WIRE_MODEL_CONFIG = ConfigDict(extra="forbid", json_schema_extra=_require_type_field)+++class DataWarehouseSourceCategory(StrEnum):+ DATABASES = "Databases"+ FILE_STORAGE = "File storage"+ ADVERTISING = "Advertising"+ MARKETING___EMAIL = "Marketing & email"+ CRM = "CRM"+ SALES = "Sales"+ CUSTOMER_SUPPORT = "Customer support"+ PAYMENTS___BILLING = "Payments & billing"+ FINANCE___ACCOUNTING = "Finance & accounting"+ ANALYTICS = "Analytics"+ ENGINEERING___MONITORING = "Engineering & monitoring"+ PRODUCTIVITY = "Productivity"+ HR___RECRUITING = "HR & recruiting"+ COMMUNICATION = "Communication"+ E_COMMERCE = "E-commerce"+++class ReleaseStatus(StrEnum):+ ALPHA = "alpha"+ BETA = "beta"+ GA = "ga"+++class SourceFieldInputConfigType(StrEnum):+ TEXT = "text"+ EMAIL = "email"+ SEARCH = "search"+ URL = "url"+ PASSWORD = "password"+ TIME = "time"+ NUMBER = "number"+ TEXTAREA = "textarea"+++class SourceFieldSelectConfigConverter(StrEnum):+ STR_TO_INT = "str_to_int"+ STR_TO_BOOL = "str_to_bool"+ STR_TO_OPTIONAL_INT = "str_to_optional_int"+++class SourceFieldSSHTunnelConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ label: str+ name: str+ type: Literal["ssh-tunnel"] = "ssh-tunnel"+++class SourceFieldOauthConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ kind: str+ label: str+ name: str+ required: bool+ requiredScopes: str | None = None+ type: Literal["oauth"] = "oauth"+++class SourceFieldOauthAccountSelectConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ caption: str | None = None+ hidden: bool | None = Field(+ default=None,+ description=(+ "Keep the field in the config tree (so its value parses and survives"+ " job_inputs redaction) without rendering it in the source form. Used for"+ " legacy fields that a newer field supersedes."+ ),+ )+ integrationField: str = Field(+ ...,+ description=("Name of the OAuth integration id field this account selector reads from."),+ )+ integrationKind: str = Field(+ ...,+ description="Integration kind to validate and route the account fetch through.",+ )+ label: str+ multiple: bool | None = Field(+ default=None,+ description=("Allow selecting multiple values; the field's payload value becomes string[]."),+ )+ name: str+ placeholder: str | None = None+ required: bool | None = None+ type: Literal["oauth-account-select"] = "oauth-account-select"+++class SourceFieldInputConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ caption: str | None = None+ label: str+ name: str+ placeholder: str+ required: bool+ secret: bool = Field(+ ...,+ description=(+ "Marks this field as containing sensitive data. The value is stripped from"+ " API responses regardless of the rendering `type` (so a multi-line PEM"+ " blob can use `textarea` and still be redacted). Required: source authors"+ " must explicitly classify every field."+ ),+ )+ # Spelled out as a `Literal` of the enum members because pydantic infers a+ # discriminated union only from `Literal` discriminator fields. The stored value is+ # still a `SourceFieldInputConfigType` member.+ type: Literal[+ SourceFieldInputConfigType.TEXT,+ SourceFieldInputConfigType.EMAIL,+ SourceFieldInputConfigType.SEARCH,+ SourceFieldInputConfigType.URL,+ SourceFieldInputConfigType.PASSWORD,+ SourceFieldInputConfigType.TIME,+ SourceFieldInputConfigType.NUMBER,+ SourceFieldInputConfigType.TEXTAREA,+ ]+++class SourceFieldFileUploadJsonFormatConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ format: Literal[".json"] = ".json"+ keys: Literal["*"] | list[str]+++class SourceFieldFileUploadConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ fileFormat: SourceFieldFileUploadJsonFormatConfig+ label: str+ name: str+ required: bool+ type: Literal["file-upload"] = "file-upload"+++class SourceFieldSelectConfigOption(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ fields: list["SourceFieldConfig"] | None = None+ label: str+ value: str+++class SourceFieldSelectConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ caption: str | None = None+ converter: SourceFieldSelectConfigConverter | None = None+ defaultValue: str+ label: str+ multiple: bool | None = Field(+ default=None,+ description=("Allow selecting multiple values; the field's payload value becomes string[]."),+ )+ name: str+ options: list[SourceFieldSelectConfigOption]+ required: bool+ type: Literal["select"] = "select"+++class SourceFieldSwitchGroupConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ caption: str | None = None+ default: str | float | bool+ fields: list["SourceFieldConfig"]+ label: str+ name: str+ type: Literal["switch-group"] = "switch-group"+++# `SourceFieldInputConfig` accepts several `type` values and the other variants accept+# one each. Pydantic maps every value to its variant, so the generated schema narrows on+# `type` instead of making the reader try each variant in turn.+SourceFieldConfig = Annotated[+ Union[+ SourceFieldInputConfig,+ SourceFieldSwitchGroupConfig,+ SourceFieldSelectConfig,+ SourceFieldOauthConfig,+ SourceFieldOauthAccountSelectConfig,+ SourceFieldFileUploadConfig,+ SourceFieldSSHTunnelConfig,+ ],+ Field(discriminator="type"),+]++SourceFieldSelectConfigOption.model_rebuild()+SourceFieldSelectConfig.model_rebuild()+SourceFieldSwitchGroupConfig.model_rebuild()+++# Pydantic publishes an enum as its own schema component, which would put a second copy+# of the source type list next to the one the DRF serializers already publish. Emitting+# the values inline instead lets drf-spectacular's enum post-processing match them by+# hash and point both at the single `ExternalDataSourceTypeEnum` component.+InlinedExternalDataSourceType = Annotated[+ ExternalDataSourceType,+ WithJsonSchema({"type": "string", "enum": ExternalDataSourceType.values}),+]+++class SuggestedTable(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ table: str+ tooltip: str | None = None+++class SourceConfig(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ caption: str | None = None+ category: DataWarehouseSourceCategory | None = Field(+ default=None,+ description=(+ "Catalog bucket this source is grouped under in the new-source wizard."+ " Optional at the type level so partial/in-progress sources don't break,"+ " but every registered source must set one (enforced by a test)."+ ),+ )+ disabledReason: str | None = None+ docsUrl: str | None = None+ existingSource: bool | None = None+ featureFlag: str | None = None+ featured: bool | None = Field(+ default=False,+ description=("Whether this source should be prominently displayed in onboarding flows"),+ )+ fields: list[SourceFieldConfig]+ iconClassName: str | None = None+ iconPath: str+ keywords: list[str] | None = Field(+ default=None,+ description=(+ "Extra search terms (alternate spellings, acronyms) for the catalog search,"+ ' e.g. GoogleAnalytics → ["ga4", "ga"]. Matched alongside'+ " name/label/category."+ ),+ )+ label: str | None = None+ name: InlinedExternalDataSourceType+ permissionsCaption: str | None = None+ releaseStatus: ReleaseStatus | None = None+ suggestedTables: list[SuggestedTable] | None = Field(+ default=[],+ description="Tables to suggest enabling, with optional tooltip explaining why",+ )+ supportsColumnSelection: bool | None = Field(+ default=False,+ description=(+ "Whether the source-creation wizard should expose the per-column projection"+ " picker. Mirrors `SQLSource.supports_column_selection` so the wizard"+ " doesn't show a picker for drivers that ignore `enabled_columns` at sync"+ " time."+ ),+ )+ unreleasedSource: bool | None = None+ webhookFields: list[SourceFieldConfig] | None = None+ webhookManualOnly: bool | None = Field(+ default=None,+ description=(+ "If true, the source does not support automatic webhook registration via"+ " API (e.g. Slack, where the user must paste the URL into the source's app"+ " settings). Adjusts the setup UI copy to avoid promising automatic"+ " registration."+ ),+ )+ webhookSetupCaption: str | None = None+++class SourceVersionDeprecation(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ version: str+ sunsetAt: str | None = Field(+ default=None,+ description="ISO date the vendor stops serving this version, or null when no date is announced.",+ )+++class SourceDocumentedTable(BaseModel):+ model_config = _WIRE_MODEL_CONFIG+ name: str+ label: str+ description: str | None = None+ sync_methods: list[str]+ incremental_fields: list[str]+ primary_keys: list[str]+++class SourceConfigResponse(SourceConfig):+ """A `SourceConfig` plus the runtime metadata the two catalog endpoints add per source."""++ supportsColumnSelection: bool = Field(+ ...,+ description=(+ "Whether the source-creation wizard should expose the per-column projection"+ " picker. Mirrors `SQLSource.supports_column_selection` so the wizard"+ " doesn't show a picker for drivers that ignore `enabled_columns` at sync"+ " time."+ ),+ )+ versions: list[str] = Field(..., description="Vendor API version labels this source supports.")+ defaultVersion: str = Field(..., description="Version used when a source instance pins none.")+ apiDocsUrl: str | None = Field(+ default=None,+ description="Vendor API docs or changelog URL, or null when the vendor publishes none.",+ )+ deprecatedVersions: list[SourceVersionDeprecation]+ tables: list[SourceDocumentedTable] | None = Field(+ default=None,+ description=(+ "Credential-free documented table catalog, empty for SQL and file sources"+ " with user-defined schemas. The public endpoint sets it; the wizard omits"+ " it to keep its payload small."+ ),+ )+++class SourceConfigMapResponse(RootModel[dict[str, SourceConfigResponse]]):+ """Map of source type identifier to its config, as both catalog endpoints return it."""++ root: dict[str, SourceConfigResponse]diff --git a/products/warehouse_sources/backend/presentation/views/external_data_source.py b/products/warehouse_sources/backend/presentation/views/external_data_source.pyindex 7c9af17167c5..9074917a5f5c 100644--- a/products/warehouse_sources/backend/presentation/views/external_data_source.py+++ b/products/warehouse_sources/backend/presentation/views/external_data_source.py@@ -119,6 +119,7 @@ from products.warehouse_sources.backend.facade.models import (sync_old_schemas_with_new_schemas,update_sync_type_config_keys,)+from products.warehouse_sources.backend.facade.source_config import SourceConfigMapResponsefrom products.warehouse_sources.backend.facade.source_management import (DATABASE_HOST_NOT_ALLOWED_GUIDANCE,DEFAULT_LAG_CRITICAL_THRESHOLD_MB,@@ -4898,6 +4899,7 @@ class ExternalDataSourceViewSet(TeamAndOrgViewSetMixin, AccessControlViewSetMixi),)],+ responses={200: SourceConfigMapResponse},)@action(methods=["GET"], detail=False)def wizard(self, request: Request, *arg: Any, **kwargs: Any):diff --git a/products/warehouse_sources/backend/presentation/views/public_source_configs.py b/products/warehouse_sources/backend/presentation/views/public_source_configs.pyindex 41c963384eda..52f867e23904 100644--- a/products/warehouse_sources/backend/presentation/views/public_source_configs.py+++ b/products/warehouse_sources/backend/presentation/views/public_source_configs.py@@ -6,8 +6,7 @@ from rest_framework import permissions, status, viewsetsfrom rest_framework.request import Requestfrom rest_framework.response import Response-from posthog.schema import SourceConfig-+from products.warehouse_sources.backend.facade.source_config import SourceConfigMapResponsefrom products.warehouse_sources.backend.facade.source_management import SourceRegistrylogger = structlog.get_logger(__name__)@@ -64,7 +63,7 @@ class PublicSourceConfigViewSet(viewsets.ViewSet):permission_classes = [permissions.AllowAny]@extend_schema(- responses={200: dict[str, SourceConfig]},+ responses={200: SourceConfigMapResponse},description=("Returns a map of source type identifiers to their full SourceConfig. Each entry is ""augmented with `supportsColumnSelection`, a `tables` array (the credential-free "diff --git a/products/warehouse_sources/backend/tests/api/test_public_source_configs.py b/products/warehouse_sources/backend/tests/api/test_public_source_configs.pyindex 1daec67e94a4..65f8607a302b 100644--- a/products/warehouse_sources/backend/tests/api/test_public_source_configs.py+++ b/products/warehouse_sources/backend/tests/api/test_public_source_configs.py@@ -2,21 +2,16 @@ from posthog.test.base import APIBaseTestfrom rest_framework import status+from products.warehouse_sources.backend.facade.source_config import SourceConfigMapResponse+class TestPublicSourceConfigs(APIBaseTest):def test_list_returns_source_configs(self):response = self.client.get("/api/public_source_configs/")assert response.status_code == status.HTTP_200_OK- data = response.json()- assert isinstance(data, dict)- assert len(data) > 0-- first_config = next(iter(data.values()))- assert "name" in first_config- assert "label" in first_config- assert "iconPath" in first_config- assert "fields" in first_config+ catalog = SourceConfigMapResponse.model_validate_json(response.content).root+ assert len(catalog) > 0def test_matches_wizard_response(self):"""Public endpoint returns the same data as the authenticated /wizard endpoint, plus thediff --git a/products/warehouse_sources/frontend/generated/api.schemas.ts b/products/warehouse_sources/frontend/generated/api.schemas.tsindex 5ad6ba20d593..ddb13d9a148e 100644--- a/products/warehouse_sources/frontend/generated/api.schemas.ts+++ b/products/warehouse_sources/frontend/generated/api.schemas.ts@@ -13264,6 +13264,247 @@ export interface SourceCredentialApi {expires_at: string}+export type DataWarehouseSourceCategoryApi =+ (typeof DataWarehouseSourceCategoryApi)[keyof typeof DataWarehouseSourceCategoryApi]++export const DataWarehouseSourceCategoryApi = {+ Databases: 'Databases',+ FileStorage: 'File storage',+ Advertising: 'Advertising',+ MarketingEmail: 'Marketing & email',+ Crm: 'CRM',+ Sales: 'Sales',+ CustomerSupport: 'Customer support',+ PaymentsBilling: 'Payments & billing',+ FinanceAccounting: 'Finance & accounting',+ Analytics: 'Analytics',+ EngineeringMonitoring: 'Engineering & monitoring',+ Productivity: 'Productivity',+ HRRecruiting: 'HR & recruiting',+ Communication: 'Communication',+ ECommerce: 'E-commerce',+} as const++export type SourceFieldInputConfigTypeEnumApi =+ (typeof SourceFieldInputConfigTypeEnumApi)[keyof typeof SourceFieldInputConfigTypeEnumApi]++export const SourceFieldInputConfigTypeEnumApi = {+ Text: 'text',+ Email: 'email',+ Search: 'search',+ Url: 'url',+ Password: 'password',+ Time: 'time',+ Number: 'number',+ Textarea: 'textarea',+} as const++export interface SourceFieldInputConfigApi {+ caption?: string | null+ label: string+ name: string+ placeholder: string+ required: boolean+ /** Marks this field as containing sensitive data. The value is stripped from API responses regardless of the rendering `type` (so a multi-line PEM blob can use `textarea` and still be redacted). Required: source authors must explicitly classify every field. */+ secret: boolean+ type: SourceFieldInputConfigTypeEnumApi+}++export type SourceFieldSelectConfigConverterApi =+ (typeof SourceFieldSelectConfigConverterApi)[keyof typeof SourceFieldSelectConfigConverterApi]++export const SourceFieldSelectConfigConverterApi = {+ StrToInt: 'str_to_int',+ StrToBool: 'str_to_bool',+ StrToOptionalInt: 'str_to_optional_int',+} as const++export interface SourceFieldOauthConfigApi {+ kind: string+ label: string+ name: string+ required: boolean+ requiredScopes?: string | null+ type: 'oauth'+}++export interface SourceFieldOauthAccountSelectConfigApi {+ caption?: string | null+ /** Keep the field in the config tree (so its value parses and survives job_inputs redaction) without rendering it in the source form. Used for legacy fields that a newer field supersedes. */+ hidden?: boolean | null+ /** Name of the OAuth integration id field this account selector reads from. */+ integrationField: string+ /** Integration kind to validate and route the account fetch through. */+ integrationKind: string+ label: string+ /** Allow selecting multiple values; the field's payload value becomes string[]. */+ multiple?: boolean | null+ name: string+ placeholder?: string | null+ required?: boolean | null+ type: 'oauth-account-select'+}++export interface SourceFieldFileUploadJsonFormatConfigApi {+ format?: '.json'+ keys: '*' | string[]+}++export interface SourceFieldFileUploadConfigApi {+ fileFormat: SourceFieldFileUploadJsonFormatConfigApi+ label: string+ name: string+ required: boolean+ type: 'file-upload'+}++export interface SourceFieldSSHTunnelConfigApi {+ label: string+ name: string+ type: 'ssh-tunnel'+}++export interface SourceFieldSelectConfigOptionApi {+ fields?:+ | (+ | SourceFieldInputConfigApi+ | SourceFieldSwitchGroupConfigApi+ | SourceFieldSelectConfigApi+ | SourceFieldOauthConfigApi+ | SourceFieldOauthAccountSelectConfigApi+ | SourceFieldFileUploadConfigApi+ | SourceFieldSSHTunnelConfigApi+ )[]+ | null+ label: string+ value: string+}++export interface SourceFieldSelectConfigApi {+ caption?: string | null+ converter?: SourceFieldSelectConfigConverterApi | null+ defaultValue: string+ label: string+ /** Allow selecting multiple values; the field's payload value becomes string[]. */+ multiple?: boolean | null+ name: string+ options: SourceFieldSelectConfigOptionApi[]+ required: boolean+ type: 'select'+}++export interface SourceFieldSwitchGroupConfigApi {+ caption?: string | null+ default: string | number | boolean+ fields: (+ | SourceFieldInputConfigApi+ | SourceFieldSwitchGroupConfigApi+ | SourceFieldSelectConfigApi+ | SourceFieldOauthConfigApi+ | SourceFieldOauthAccountSelectConfigApi+ | SourceFieldFileUploadConfigApi+ | SourceFieldSSHTunnelConfigApi+ )[]+ label: string+ name: string+ type: 'switch-group'+}++export type ReleaseStatusApi = (typeof ReleaseStatusApi)[keyof typeof ReleaseStatusApi]++export const ReleaseStatusApi = {+ Alpha: 'alpha',+ Beta: 'beta',+ Ga: 'ga',+} as const++export interface SuggestedTableApi {+ table: string+ tooltip?: string | null+}++export interface SourceVersionDeprecationApi {+ version: string+ /** ISO date the vendor stops serving this version, or null when no date is announced. */+ sunsetAt?: string | null+}++export interface SourceDocumentedTableApi {+ name: string+ label: string+ description?: string | null+ sync_methods: string[]+ incremental_fields: string[]+ primary_keys: string[]+}++/**+ * A `SourceConfig` plus the runtime metadata the two catalog endpoints add per source.+ */+export interface SourceConfigResponseApi {+ caption?: string | null+ /** Catalog bucket this source is grouped under in the new-source wizard. Optional at the type level so partial/in-progress sources don't break, but every registered source must set one (enforced by a test). */+ category?: DataWarehouseSourceCategoryApi | null+ disabledReason?: string | null+ docsUrl?: string | null+ existingSource?: boolean | null+ featureFlag?: string | null+ /** Whether this source should be prominently displayed in onboarding flows */+ featured?: boolean | null+ fields: (+ | SourceFieldInputConfigApi+ | SourceFieldSwitchGroupConfigApi+ | SourceFieldSelectConfigApi+ | SourceFieldOauthConfigApi+ | SourceFieldOauthAccountSelectConfigApi+ | SourceFieldFileUploadConfigApi+ | SourceFieldSSHTunnelConfigApi+ )[]+ iconClassName?: string | null+ iconPath: string+ /** Extra search terms (alternate spellings, acronyms) for the catalog search, e.g. GoogleAnalytics → ["ga4", "ga"]. Matched alongside name/label/category. */+ keywords?: string[] | null+ label?: string | null+ name: ExternalDataSourceTypeEnumApi+ permissionsCaption?: string | null+ releaseStatus?: ReleaseStatusApi | null+ /** Tables to suggest enabling, with optional tooltip explaining why */+ suggestedTables?: SuggestedTableApi[] | null+ /** Whether the source-creation wizard should expose the per-column projection picker. Mirrors `SQLSource.supports_column_selection` so the wizard doesn't show a picker for drivers that ignore `enabled_columns` at sync time. */+ supportsColumnSelection: boolean+ unreleasedSource?: boolean | null+ webhookFields?:+ | (+ | SourceFieldInputConfigApi+ | SourceFieldSwitchGroupConfigApi+ | SourceFieldSelectConfigApi+ | SourceFieldOauthConfigApi+ | SourceFieldOauthAccountSelectConfigApi+ | SourceFieldFileUploadConfigApi+ | SourceFieldSSHTunnelConfigApi+ )[]+ | null+ /** If true, the source does not support automatic webhook registration via API (e.g. Slack, where the user must paste the URL into the source's app settings). Adjusts the setup UI copy to avoid promising automatic registration. */+ webhookManualOnly?: boolean | null+ webhookSetupCaption?: string | null+ /** Vendor API version labels this source supports. */+ versions: string[]+ /** Version used when a source instance pins none. */+ defaultVersion: string+ /** Vendor API docs or changelog URL, or null when the vendor publishes none. */+ apiDocsUrl?: string | null+ deprecatedVersions: SourceVersionDeprecationApi[]+ /** Credential-free documented table catalog, empty for SQL and file sources with user-defined schemas. The public endpoint sets it; the wizard omits it to keep its payload small. */+ tables?: SourceDocumentedTableApi[] | null+}++/**+ * Map of source type identifier to its config, as both catalog endpoints return it.+ */+export interface SourceConfigMapResponseApi {+ [key: string]: SourceConfigResponseApi+}+export interface WarehouseColumnStatisticsApi {readonly id: string/** ID of the data warehouse table this column belongs to. */diff --git a/products/warehouse_sources/frontend/generated/api.ts b/products/warehouse_sources/frontend/generated/api.tsindex 735d4c60d741..405f4512ac09 100644--- a/products/warehouse_sources/frontend/generated/api.ts+++ b/products/warehouse_sources/frontend/generated/api.ts@@ -42,6 +42,7 @@ import type {PatchedExternalDataSchemaApi,PatchedExternalDataSourceSerializersApi,SchemaDestinationsApi,+ SourceConfigMapResponseApi,SourceConnectLinkApi,SourceCredentialApi,SourceCredentialCreateApi,@@ -1365,8 +1366,8 @@ export const externalDataSourcesWizardRetrieve = async (projectId: string,params?: ExternalDataSourcesWizardRetrieveParams,options?: RequestInit-): Promise<void> => {- return apiMutator<void>(getExternalDataSourcesWizardRetrieveUrl(projectId, params), {+): Promise<SourceConfigMapResponseApi> => {+ return apiMutator<SourceConfigMapResponseApi>(getExternalDataSourcesWizardRetrieveUrl(projectId, params), {...options,method: 'GET',})diff --git a/services/mcp/src/api/generated.ts b/services/mcp/src/api/generated.tsindex a64adc309bf2..d2cb2fd07077 100644--- a/services/mcp/src/api/generated.ts+++ b/services/mcp/src/api/generated.ts@@ -24126,6 +24126,27 @@ export namespace Schemas {readonly user_access_level: string | null;}+ export type DataWarehouseSourceCategory = typeof DataWarehouseSourceCategory[keyof typeof DataWarehouseSourceCategory];+++ export const DataWarehouseSourceCategory = {+ Databases: 'Databases',+ FileStorage: 'File storage',+ Advertising: 'Advertising',+ MarketingEmail: 'Marketing & email',+ Crm: 'CRM',+ Sales: 'Sales',+ CustomerSupport: 'Customer support',+ PaymentsBilling: 'Payments & billing',+ FinanceAccounting: 'Finance & accounting',+ Analytics: 'Analytics',+ EngineeringMonitoring: 'Engineering & monitoring',+ Productivity: 'Productivity',+ HRRecruiting: 'HR & recruiting',+ Communication: 'Communication',+ ECommerce: 'E-commerce',+ } as const;+/*** * `web` - web* * `api` - api@@ -78565,6 +78586,15 @@ export namespace Schemas {rejection_reason?: string;}+ export type ReleaseStatus = typeof ReleaseStatus[keyof typeof ReleaseStatus];+++ export const ReleaseStatus = {+ Alpha: 'alpha',+ Beta: 'beta',+ Ga: 'ga',+ } as const;+/*** Request body for `remember`.*/@@ -83209,6 +83239,180 @@ export namespace Schemas {Snowflake: 'Snowflake',} as const;+ export type SourceFieldInputConfigTypeEnum = typeof SourceFieldInputConfigTypeEnum[keyof typeof SourceFieldInputConfigTypeEnum];+++ export const SourceFieldInputConfigTypeEnum = {+ Text: 'text',+ Email: 'email',+ Search: 'search',+ Url: 'url',+ Password: 'password',+ Time: 'time',+ Number: 'number',+ Textarea: 'textarea',+ } as const;++ export interface SourceFieldInputConfig {+ caption?: string | null;+ label: string;+ name: string;+ placeholder: string;+ required: boolean;+ /** Marks this field as containing sensitive data. The value is stripped from API responses regardless of the rendering `type` (so a multi-line PEM blob can use `textarea` and still be redacted). Required: source authors must explicitly classify every field. */+ secret: boolean;+ type: SourceFieldInputConfigTypeEnum;+ }++ export type SourceFieldSelectConfigConverter = typeof SourceFieldSelectConfigConverter[keyof typeof SourceFieldSelectConfigConverter];+++ export const SourceFieldSelectConfigConverter = {+ StrToInt: 'str_to_int',+ StrToBool: 'str_to_bool',+ StrToOptionalInt: 'str_to_optional_int',+ } as const;++ export interface SourceFieldOauthConfig {+ kind: string;+ label: string;+ name: string;+ required: boolean;+ requiredScopes?: string | null;+ type: 'oauth';+ }++ export interface SourceFieldOauthAccountSelectConfig {+ caption?: string | null;+ /** Keep the field in the config tree (so its value parses and survives job_inputs redaction) without rendering it in the source form. Used for legacy fields that a newer field supersedes. */+ hidden?: boolean | null;+ /** Name of the OAuth integration id field this account selector reads from. */+ integrationField: string;+ /** Integration kind to validate and route the account fetch through. */+ integrationKind: string;+ label: string;+ /** Allow selecting multiple values; the field's payload value becomes string[]. */+ multiple?: boolean | null;+ name: string;+ placeholder?: string | null;+ required?: boolean | null;+ type: 'oauth-account-select';+ }++ export interface SourceFieldFileUploadJsonFormatConfig {+ format?: '.json';+ keys: '*' | string[];+ }++ export interface SourceFieldFileUploadConfig {+ fileFormat: SourceFieldFileUploadJsonFormatConfig;+ label: string;+ name: string;+ required: boolean;+ type: 'file-upload';+ }++ export interface SourceFieldSSHTunnelConfig {+ label: string;+ name: string;+ type: 'ssh-tunnel';+ }++ export interface SourceFieldSelectConfigOption {+ fields?: (SourceFieldInputConfig | SourceFieldSwitchGroupConfig | SourceFieldSelectConfig | SourceFieldOauthConfig | SourceFieldOauthAccountSelectConfig | SourceFieldFileUploadConfig | SourceFieldSSHTunnelConfig)[] | null;+ label: string;+ value: string;+ }++ export interface SourceFieldSelectConfig {+ caption?: string | null;+ converter?: SourceFieldSelectConfigConverter | null;+ defaultValue: string;+ label: string;+ /** Allow selecting multiple values; the field's payload value becomes string[]. */+ multiple?: boolean | null;+ name: string;+ options: SourceFieldSelectConfigOption[];+ required: boolean;+ type: 'select';+ }++ export interface SourceFieldSwitchGroupConfig {+ caption?: string | null;+ default: string | number | boolean;+ fields: (SourceFieldInputConfig | SourceFieldSwitchGroupConfig | SourceFieldSelectConfig | SourceFieldOauthConfig | SourceFieldOauthAccountSelectConfig | SourceFieldFileUploadConfig | SourceFieldSSHTunnelConfig)[];+ label: string;+ name: string;+ type: 'switch-group';+ }++ export interface SuggestedTable {+ table: string;+ tooltip?: string | null;+ }++ export interface SourceVersionDeprecation {+ version: string;+ /** ISO date the vendor stops serving this version, or null when no date is announced. */+ sunsetAt?: string | null;+ }++ export interface SourceDocumentedTable {+ name: string;+ label: string;+ description?: string | null;+ sync_methods: string[];+ incremental_fields: string[];+ primary_keys: string[];+ }++ /**+ * A `SourceConfig` plus the runtime metadata the two catalog endpoints add per source.+ */+ export interface SourceConfigResponse {+ caption?: string | null;+ /** Catalog bucket this source is grouped under in the new-source wizard. Optional at the type level so partial/in-progress sources don't break, but every registered source must set one (enforced by a test). */+ category?: DataWarehouseSourceCategory | null;+ disabledReason?: string | null;+ docsUrl?: string | null;+ existingSource?: boolean | null;+ featureFlag?: string | null;+ /** Whether this source should be prominently displayed in onboarding flows */+ featured?: boolean | null;+ fields: (SourceFieldInputConfig | SourceFieldSwitchGroupConfig | SourceFieldSelectConfig | SourceFieldOauthConfig | SourceFieldOauthAccountSelectConfig | SourceFieldFileUploadConfig | SourceFieldSSHTunnelConfig)[];+ iconClassName?: string | null;+ iconPath: string;+ /** Extra search terms (alternate spellings, acronyms) for the catalog search, e.g. GoogleAnalytics → ["ga4", "ga"]. Matched alongside name/label/category. */+ keywords?: string[] | null;+ label?: string | null;+ name: ExternalDataSourceTypeEnum;+ permissionsCaption?: string | null;+ releaseStatus?: ReleaseStatus | null;+ /** Tables to suggest enabling, with optional tooltip explaining why */+ suggestedTables?: SuggestedTable[] | null;+ /** Whether the source-creation wizard should expose the per-column projection picker. Mirrors `SQLSource.supports_column_selection` so the wizard doesn't show a picker for drivers that ignore `enabled_columns` at sync time. */+ supportsColumnSelection: boolean;+ unreleasedSource?: boolean | null;+ webhookFields?: (SourceFieldInputConfig | SourceFieldSwitchGroupConfig | SourceFieldSelectConfig | SourceFieldOauthConfig | SourceFieldOauthAccountSelectConfig | SourceFieldFileUploadConfig | SourceFieldSSHTunnelConfig)[] | null;+ /** If true, the source does not support automatic webhook registration via API (e.g. Slack, where the user must paste the URL into the source's app settings). Adjusts the setup UI copy to avoid promising automatic registration. */+ webhookManualOnly?: boolean | null;+ webhookSetupCaption?: string | null;+ /** Vendor API version labels this source supports. */+ versions: string[];+ /** Version used when a source instance pins none. */+ defaultVersion: string;+ /** Vendor API docs or changelog URL, or null when the vendor publishes none. */+ apiDocsUrl?: string | null;+ deprecatedVersions: SourceVersionDeprecation[];+ /** Credential-free documented table catalog, empty for SQL and file sources with user-defined schemas. The public endpoint sets it; the wizard omits it to keep its payload small. */+ tables?: SourceDocumentedTable[] | null;+ }++ /**+ * Map of source type identifier to its config, as both catalog endpoints return it.+ */+ export interface SourceConfigMapResponse {[key: string]: SourceConfigResponse}+export interface SourceConnectLink {/** The source type the link is for. */source_type: string;diff --git a/services/mcp/src/tools/generated/warehouse_sources.ts b/services/mcp/src/tools/generated/warehouse_sources.tsindex a773b27fa507..23a5836c86f8 100644--- a/services/mcp/src/tools/generated/warehouse_sources.ts+++ b/services/mcp/src/tools/generated/warehouse_sources.ts@@ -999,12 +999,15 @@ const ExternalDataSourcesWizardSchema = () => {})}-const externalDataSourcesWizard = (): ToolBase<ReturnType<typeof ExternalDataSourcesWizardSchema>, unknown> => ({+const externalDataSourcesWizard = (): ToolBase<+ ReturnType<typeof ExternalDataSourcesWizardSchema>,+ Schemas.SourceConfigMapResponse+> => ({name: 'external-data-sources-wizard',schema: ExternalDataSourcesWizardSchema(),handler: async (context: Context, params: z.infer<ReturnType<typeof ExternalDataSourcesWizardSchema>>) => {const projectId = await context.stateManager.getProjectId()- const result = await context.api.request<unknown>({+ const result = await context.api.request<Schemas.SourceConfigMapResponse>({method: 'GET',path: `/api/projects/${encodeURIComponent(String(projectId))}/external_data_sources/wizard/`,query: {