Error importing workflow created by Claude Code and ChatGPT

Describe the problem/error/question

It seems that there is an error every time i try to import a workflow created by an AI tool. I cant seem to find what exactly is failing the import. It is failing on both self hosted and cloud 

What is the error message (if any)?

Problem importing workflow

propertyValues[itemName] is not iterable

Please share your workflow

Share the output returned by the last node

Information on your n8n setup

  • n8n version: 2.2.5
  • Database (default: SQLite): SQLite
  • n8n EXECUTIONS_PROCESS setting (default: own, main): default
  • Running n8n via (Docker, npm, n8n cloud, desktop app): Docker
  • Operating system: Ubuntu Server 24.4
1 Like

The “propertyValues[itemName] is not iterable” error is a known issue that occurs when importing AI-generated workflows, as mentioned in [github.com](propertyValues[itemName] is not iterable · Issue #14775 · n8n-io/n8n · GitHub). This typically happens because AI tools sometimes generate JSON structures that don’t match n8n’s expected format exactly.

To fix this, try these steps:

• First, validate your workflow JSON using a JSON validator to ensure it’s properly formatted

• Check if any node parameters contain arrays where n8n expects objects or vice versa

• Try importing the workflow in smaller parts - copy individual nodes first, then rebuild connections manually

• As a workaround, you can often fix the JSON by opening it in a text editor and looking for any malformed arrays or missing brackets around parameter values

If the issue persists, consider sharing the problematic JSON (with sensitive data removed) in the n8n community forum for more specific debugging help.

1 Like

Hey @Mohamed_Aly Welcome to the n8n community

As you are trying to make an n8n workflow using ClaudeCode, i recommend adding an MCP on ClaudeCode which is the official n8n docs mcp “ https://n8n.mcp.kapa.ai/ “ , and this will allow claudeCode to see how workflows are made and basic data structures n8n workflow JSON uses, this helped me a lot when trying out AI generated workflows. As adding MCP server will allow claudeCode to actually see how things actually work in n8n, and this will help you get better AI generated JSON (Workflow Automation) , and this will also reduce the chance of ‘workflow not importing’ as most of the times workflow not importing means invalid JSON for n8n flows , let me know if the issue persists!

Cheers!

Thanks for your reply. I already have it connected to the MCP and skills here GitHub - czlonkowski/n8n-mcp: A MCP for Claude Desktop / Claude Code / Windsurf / Cursor to build n8n workflows for you

I think I have identified the issue though. I think it is an issue with Perplexity node. When I removed it it imported the workflow

1 Like