{ "name": "verify-if-branch-payload-depth", "nodes": [ {"id": "n1", "name": "Trigger", "type": "click-trigger", "position": {"x": 0, "y": 0}, "config": {}}, {"id": "src", "name": "Src", "type": "code", "position": {"x": 0, "y": 100}, "config": {"code": "return { count: 2, emails: [{ id: 'a' }, { id: 'b' }] };"}}, {"id": "gate", "name": "Gate", "type": "if-condition", "position": {"x": 0, "y": 200}, "config": {"combineWith": "and", "conditions": [{"field": "data.result.count", "operator": "greater_than", "value": "0"}]}}, {"id": "lp", "name": "Loop", "type": "loop", "position": {"x": 0, "y": 300}, "config": {"inputField": "data.result.emails", "itemVariableName": "email", "outputField": "res", "continueOnError": true}}, {"id": "body", "name": "Body", "type": "code", "position": {"x": 0, "y": 400}, "config": {"code": "return { seen: (input.email && input.email.id) || 'NOT-AN-EMAIL' };"}} ], "connections": [ {"sourceNodeId": "n1", "sourceOutput": "main", "targetNodeId": "src", "targetInput": "data"}, {"sourceNodeId": "src", "sourceOutput": "main", "targetNodeId": "gate", "targetInput": "data"}, {"sourceNodeId": "gate", "sourceOutput": "true", "targetNodeId": "lp", "targetInput": "data"}, {"sourceNodeId": "lp", "sourceOutput": "loop", "targetNodeId": "body", "targetInput": "data"} ], "expect": { "lp": {"status": "completed"}, "body": {"status": "completed", "output": {"result": {"seen": "b"}}} } }