Is there any way to debug script elements in flows
I need to debug a script element in an iPaas flow but have been unable to find any way to get data out of the script (excluding the result). Are there any methods or functions that can be used to present the values of variables in the script (like to the log) so I can debug it? Is there a better way to do it?
Answer (1)
Hi Andrew,
The script element is intended to be used...sparingly, when iPaaS functionality isn't able to do what is desired; not as an ongoing first-choice flow step. The script functionality is definitely limited, and usual methods to log (such as console.log(), among others) don't work due to the limited scope of JS within iPaaS.
In thinking through how to return multiple things for debugging, and we think the best option is as JSON that returns to a table.
So - as you go through the script, you can add keys / values to see what things are throughout - making more variables as you go. You can see this output by saving it into a table.
Sincerely,
Mark Sayers
Sr Support Consultant, CS