diff --git a/src/platform/workflow/templates/repositories/workflowTemplatesStore.ts b/src/platform/workflow/templates/repositories/workflowTemplatesStore.ts index a1076c88d2..5ea52c8ede 100644 --- a/src/platform/workflow/templates/repositories/workflowTemplatesStore.ts +++ b/src/platform/workflow/templates/repositories/workflowTemplatesStore.ts @@ -237,7 +237,17 @@ export const useWorkflowTemplatesStore = defineStore( } ) - return allTemplates + // TODO: Temporary filtering of custom node templates on local installations + // Future: Add UX that allows local users to opt-in to templates with custom nodes, + // potentially conditional on whether they have those specific custom nodes installed. + // This would provide better template discovery while respecting local user workflows. + const filteredTemplates = isCloud + ? allTemplates + : allTemplates.filter( + (template) => !template.requiresCustomNodes?.length + ) + + return filteredTemplates }) /** diff --git a/src/platform/workflow/templates/types/template.ts b/src/platform/workflow/templates/types/template.ts index 426dd12cff..25a209e854 100644 --- a/src/platform/workflow/templates/types/template.ts +++ b/src/platform/workflow/templates/types/template.ts @@ -27,6 +27,11 @@ export interface TemplateInfo { * Whether this template uses open source models. When false, indicates partner/API node templates. */ openSource?: boolean + /** + * Array of custom node package IDs required for this template (from Custom Node Registry). + * Templates with this field will be hidden on local installations temporarily. + */ + requiresCustomNodes?: string[] } export interface WorkflowTemplates {