Hi. I am trying to understand the data coming in the example below and how to split it into separate items so that i can import it into mautic.
What I would like to do is split the high level sports into two items so that i can insert these in the coming nodes, and then do the same for teams. The other issue is that I would like to take the sports values and team values and insert them into mautic, however each time i receive a webhook there could be a different number of sports and a different number of teams so i would need to loop over them.
What is the error message (if any)?
Please share the workflow
Share the output returned by the last node
Information on your n8n setup
Database you’re using (default: SQLite):
Running n8n with the execution process [own(default), main]:
Running n8n via [Docker, npm, n8n.cloud, desktop app]: docker
Data that can change is in body.3, this could sometimes just be nfl, sometimes just nba and sometimes both nfl and nbd.
Inside Teams this is also variable data, and can sometimes be either nba or nfl or both and the number of teams might differ each time, sometimes there might be only 1 team, sometimes there might be 7 for example.
What I am trying to accomplish is to take the data from teams regardless of how many teams there are and get them into a string that i can then input into a custom field inside Mautic. So in the example above I would like to get nfl teams as: “Denver Broncos,Los Angeles Chargers,Kansas City Chiefs”. I would then take this and use this when adding to a field inside my mautic node.