Execute workflow input...? Cannot read properties of undefined (reading 'json) [line 1]

I’m trying to use the execute workflow to pass data from an API, but I get this error:

image

Does it need to be formatted somehow? Seems I can’t pass directly as a result of an API…

Hi @yukyo, I am sorry you’re having trouble. Could you perhaps confirm which n8n version you are currently using and provide a workflow (or two workflows, seeing the Execute Workflow node would require two different workflows) using which your problem can be reproduced?

Thank you!

Hi @MutedJam.

I have created a demonstration scenario with a javascript that replicates the exact same needed input to the execution workflow.

And it is showing the same exact error.

Thanks!

Sorry @MutedJam, I forgot to mention my version, I’m currently running: 0.199.0 (1 version behind latest)

image

Thanks so much for providing an example here @yukyo. I tried reproducing this by first creating a child workflow like this:

I’ve then executed the parent workflow you have provided (the only change I have made was updating the child workflow ID to match my own ID.

The workflow executed fine for me:

Is there a chance the problem occurs in your child workflow (the workflow called by the Execute Workflow node)? Can you take a look at the execution data for it and check your sub-workflow for errors? If you don’t store all executions, you might need to update the workflow settings first like below:

Then re-run your parent workflow to reproduce the error.

Also I am away until later next week, so won’t be able to respond straight away here on the forum.

1 Like

OMG :person_facepalming:

So the error that I see in the Parent scenario is an error coming from the child scenario… not very intuitive… maybe more details on it like that? “Sub-scenario XX (ID of the workflow) returned the error: Cannot read properties of undefined (reading ‘json) [line 1] ]”

Ok, it seems to be working now… Thanks!

Fair enough, though tbh the Execute Workflow node’s only function is to run other workflows. So pretty much any error on there would be coming from the respective sub-workflow.