FlowiseAI/Flowise · error · Error
Worker name is required!
Error message
Worker name is required!
What it means
Thrown by Worker.init when `nodeData.inputs?.workerName` is falsy. The worker name is required because it is normalized into a unique agent identifier (`workerLabel.toLowerCase().replace(/\s/g, '_')`) used by the supervisor to route tasks.
Source
Thrown at packages/components/nodes/multiagents/Worker/Worker.ts:96
label: 'Max Iterations',
name: 'maxIterations',
type: 'number',
optional: true
}
]
}
async init(nodeData: INodeData, input: string, options: ICommonObject): Promise<any> {
let tools = nodeData.inputs?.tools
tools = flatten(tools)
let workerPrompt = nodeData.inputs?.workerPrompt as string
const workerLabel = nodeData.inputs?.workerName as string
const supervisor = nodeData.inputs?.supervisor as IMultiAgentNode
const maxIterations = nodeData.inputs?.maxIterations as string
const model = nodeData.inputs?.model as BaseChatModel
const promptValuesStr = nodeData.inputs?.promptValues
if (!workerLabel) throw new Error('Worker name is required!')
const workerName = workerLabel.toLowerCase().replace(/\s/g, '_').trim()
if (!workerPrompt) throw new Error('Worker prompt is required!')
let workerInputVariablesValues: ICommonObject = {}
if (promptValuesStr) {
try {
workerInputVariablesValues = typeof promptValuesStr === 'object' ? promptValuesStr : JSON.parse(promptValuesStr)
} catch (exception) {
throw new Error("Invalid JSON in the Worker's Prompt Input Values: " + exception)
}
}
workerInputVariablesValues = handleEscapeCharacters(workerInputVariablesValues, true)
const llm = model || (supervisor.llm as BaseChatModel)
const multiModalMessageContent = supervisor?.multiModalMessageContent || []
const abortControllerSignal = options.signal as AbortControllerView on GitHub (pinned to abe4a8601a)
Solutions
- Open the Worker node config and supply a non-empty workerName.
- If building chatflows programmatically, set `inputs.workerName` to a unique string per worker.
- Add schema validation at flow-save so empty workerName is rejected in the UI.
Example fix
// before
const workerLabel = nodeData.inputs?.workerName as string
// after
const workerLabel = nodeData.inputs?.workerName as string
if (!workerLabel?.trim()) throw new Error('Worker name is required!') Defensive patterns
Strategy: validation
Validate before calling
const workerLabel = (nodeData.inputs?.workerName as string)?.trim()
if (!workerLabel) throw new Error('Worker name is required!') Prevention
- Mark workerName as required in the node input schema.
- Validate at flow-save time so the UI blocks publishing empty names.
- Use unique names per worker to avoid routing collisions.
When it happens
Trigger: A Worker node placed on the canvas without filling in the workerName input, or a flow imported from JSON where workerName was omitted/empty.
Common situations: Authoring a new multi-agent flow and forgetting to label one worker; copy-pasting a worker node and clearing its name; programmatic chatflow creation that skips required fields.
Related errors
- Worker prompt is required!
- Supervisor name is required!
- Invalid JSON in the Worker's Prompt Input Values: ${exceptio
- Worker input variables values are not provided!
- Must specify one of "k" or "similarity_threshold".
AI-assisted analysis of FlowiseAI/Flowise@abe4a8601a (2026-08-12).
Data as JSON: /api/errors/120c60781dea0b39.
Report an issue: GitHub.