EDIT: by @CodeShepherd Moved to own topic from this one.
Hello,
Thanks for the sharing.
I tried it and I have an issue at the JSON parsing . The initial URL was : https://{{ip}}/{{{command}}} I changed it to https://{{ip}}/{{command}}
This doesn't seem to work, it returns statuscode 200 and I still get a "JSON parse error"
I'm on a Virtual Core do you have a solution?
Solved! Go to Solution.
Could you share your nodes so we can do some tests?
Yes of course.
Please rename .txt to .json
I tried to get trough all of this and I found that it was a little bit confusing. Because I normally simply use function to put the message together and use a generic http request.
Did you try to use three brackets each "https://{{{ip}}}/{{{command}}}"? I now other nodes behave like this.
We could also have a short online meeting if you like. Please send me a private message with your contact data then.
I had a deeper look and found that your code simply asks for the html code at a node on the datalayer. This is also given back, but the JSON parser cannot interpret this as a JSON object so you get the error shown.
ctrlX Node-RED customer flow JSON parse error
Please have a look to the blog post "Using REST API of ctrlX CORE" to see how the basics work.