The Loop block in Architect is notoriously picky about data types, and it’s probably not recognizing that raw JSON string as a proper array object. When you pull data from a Data Action, it often comes through as a string unless you explicitly tell the system to parse it.
You need to convert that string into an actual list object before the Loop block sees it. The easiest way to do this is by using a Set Data block with a JSON parsing expression. If your Data Action output is stored in a variable like dataActionOutput, you’d set a new variable, say parsedItems, using this expression:
json.parse(dataActionOutput)
Make sure dataActionOutput is actually the string representation of the array ["item1", "item2"]. If your Data Action is already returning a structured JSON object, you might just need to reference the specific array field within it, like dataActionOutput.items.
Once you have that parsedItems variable, map it to the Loop block’s “Items” input. The Loop block expects a list, not a string. If you skip the parsing step, Architect treats the whole JSON string as a single item, which is why the body doesn’t execute or behaves unexpectedly.
Also, check the data type of the variable you’re setting. In the Set Data block, ensure the target variable type is set to “List of Strings” or “List of Objects” depending on what’s inside your array. If it’s set to “String”, the loop won’t iterate correctly.
I’ve run into this exact issue when integrating with external APIs that return JSON strings. The json.parse() function is your friend here. It converts the string into a usable list that Architect can iterate over. Just be careful if your array contains complex objects; you’ll need to handle the property access inside the loop body accordingly.
Give that a shot. If the Loop still skips, try adding a Log block right before the Loop to print the type and length of the variable you’re passing in. That usually reveals whether the parsing happened as expected.