Reputation: 403
I have a web service response in XML. I want to extract the 'available' tag value in node-red. I have placed the XML node before a function node and I tried accessing the value as msg.payload.agentAvailability.available
in my function. It ends while reporting an error undefined.
This is how my node-red flow looks like.
Any help will be appearciated.
Upvotes: 1
Views: 394
Reputation: 59608
You have missed out the $
key in your path.
Try the following:
msg.payload.agentAvailability["$"].available
Upvotes: 1