{"record":{"id":"ee53acf11b4e85c7","repo":"FlowiseAI/Flowise","slug":"json-path-is-required","errorCode":null,"errorMessage":"JSON Path is required","messagePattern":"JSON Path is required","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"packages/components/nodes/tools/JSONPathExtractor/JSONPathExtractor.ts","lineNumber":118,"sourceCode":"            },\n            {\n                label: 'Return Null on Error',\n                name: 'returnNullOnError',\n                type: 'boolean',\n                default: false,\n                description: 'Return null instead of throwing error when extraction fails',\n                optional: true,\n                additionalParams: true\n            }\n        ]\n    }\n\n    async init(nodeData: INodeData, _: string): Promise<any> {\n        const path = (nodeData.inputs?.path as string) || ''\n        const returnNullOnError = (nodeData.inputs?.returnNullOnError as boolean) || false\n\n        if (!path) {\n            throw new Error('JSON Path is required')\n        }\n\n        return new JSONPathExtractorTool(path, returnNullOnError)\n    }\n}\n\nmodule.exports = { nodeClass: JSONPathExtractor_Tools }\n","sourceCodeStart":100,"sourceCodeEnd":126,"githubUrl":"https://github.com/FlowiseAI/Flowise/blob/abe4a8601a058047b350c260676826e21dd14101/packages/components/nodes/tools/JSONPathExtractor/JSONPathExtractor.ts#L100-L126","documentation":"Thrown by JSONPathExtractor_Tools.init (the INode factory) when nodeData.inputs.path is empty, before any tool instance is constructed. This is the design-time guard that prevents error 384 from ever firing in normal Flowise use — the node refuses to initialize without a path. It runs at flow load/run time, not at tool _call time.","triggerScenarios":"The JSON Path input field on the node is blank or contains only whitespace; the flow was imported/saved without setting the required field; the node was duplicated and the path field wasn't filled.","commonSituations":"Saving a draft flow before configuring required inputs; programmatic flow creation that omits path; a migration that reset optional/required flags.","solutions":["Open the node and type a path in the JSON Path field (e.g. 'data' or 'user.name').","If building the flow programmatically, set inputs.path in the node data before running.","Validate required fields before flow save in your automation.","Note: returnNullOnError does NOT suppress this init-time error — the path must be non-empty regardless."],"exampleFix":"// before\nnodeData.inputs = { path: '' }\n// after\nnodeData.inputs = { path: 'data.result' }","handlingStrategy":"validation","validationCode":"function validateNodeInputs(nodeData: INodeData) {\n  const path = (nodeData.inputs?.path as string)?.trim?.() ?? ''\n  if (!path) throw new Error('JSON Path is required — set inputs.path before running the flow')\n}","typeGuard":"function hasPathInput(n: INodeData): n is INodeData & { inputs: { path: string } } {\n  return typeof n.inputs?.path === 'string' && n.inputs.path.trim().length > 0\n}","tryCatchPattern":null,"preventionTips":["Set the JSON Path field before saving/running the node.","Mark path as required in flow templates so the UI blocks save.","returnNullOnError does NOT suppress this init-time check.","When building flows programmatically, always set inputs.path."],"tags":["jsonpath","config","validation","required-field","init"],"backgroundTag":null,"analyzedSha":"abe4a8601a058047b350c260676826e21dd14101","analyzedAt":"2026-08-12T16:04:40.823Z","schemaVersion":2},"datasetVersion":"2026-08-12T18:17:37.767Z"}