PersistentAI API Documentation / @persistentai/fireflow-vfs / / IFileTypeDefinition
Interface: IFileTypeDefinition
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:84
Complete file type definition. Stored in static registry on backend, cached on frontend.
Pattern inspired by secretTypeSchemas in fireflow-types.
Properties
actions
actions:
FileAction[]
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:121
Available actions for this file type
category
category:
FileTypeCategory
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:104
Category for grouping in menus
createSchema?
optionalcreateSchema:ZodType<Record<string,unknown>,ZodTypeDef,Record<string,unknown>>
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:107
Zod schema for creation dialog fields (if creatable)
defaultContent?
optionaldefaultContent:string| (params) =>string
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:110
Default content template (string or function)
description?
optionaldescription:string
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:92
Brief description for tooltips
dropNodeType?
optionaldropNodeType:string
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:142
Node type to create when this file is dropped onto the flow canvas
editable
editable:
boolean
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:133
Whether file content is editable
extensions
extensions:
string[]
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:95
File extensions this type handles (e.g., ['.fflow', '.ffw'])
handler
handler:
FileHandler
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:124
Handler that opens this file type
icon
icon:
string
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:101
Icon identifier (lucide icon name or custom)
id
id:
string
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:86
Unique identifier (e.g., 'fflow', 'json', 'markdown')
mimeTypes?
optionalmimeTypes:string[]
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:98
MIME types this type handles (fallback identification)
name
name:
string
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:89
Human-readable name (e.g., 'FireFlow Flow')
preCreateHook?
optionalpreCreateHook:PreCreateHookId
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:118
Pre-create hook identifier. If set, DBOS workflow will execute this hook before writing the file. The hook creates a resource (Flow, Secret, MCP) and returns its ID, which is then embedded in the file content via defaultContent({ resourceId }).
previewable
previewable:
boolean
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:136
Whether file can be previewed inline
priority?
optionalpriority:number
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:139
Priority for extension conflicts (higher wins)
virtual
virtual:
boolean
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:127
Whether file can expose virtual children
virtualChildType?
optionalvirtualChildType:VirtualChildType
Defined in: packages/fireflow-vfs/src/types/file-type-definition.ts:130
Virtual child type identifier (for virtual: true types)