Use ChatGPT to generate curl commands and JavaScript code for n8n workflows when built-in actions fall short. The speaker gets ChatGPT to write an API call that lists Google Sheets names and IDs, then JavaScript to parse the response, both pasted directly into n8n nodes. It works on the first try.
Chapters
I think the biggest life hack for NAN is literally just using ChatGPT. And there's so many different ways you can do this, but one of the examples I just used for a video in the new community I'm building is when you're trying to do something, for example, in Google Sheets and NAN only gives you this set list of actions, but you want to do something like, for example, list all of the sheet names or IDs inside of a Google Sheet. And you can't do that with the actions that NAN are giving you. You can do is literally just come over to ChatGPT and say, can you gimme a curl that'll allow me to return all of the sheets inside of a Google Sheet? And then it'll just do that. And then I import that into HTTP request in NaN. And then I said the output looks like this, can you give me some JavaScript that will extract these sheet IDs as separate items? And it just gives me the JavaScript and it works first time. Some people probably think that this is cheating, but there's literally no reason to not do this because ChatGPT is always going to be around. The example I used in the video for the community is it's the same thing as using a calculator in maths. I don't know about you guys, but when I was at school, we literally did a maths paper with a calculator. And in class in school, we use a calculator in maths for some lessons. It's literally the same