NodeRed using message data in service calls

It should be pretty easy to see what I’m trying to do here from the image but basically I have a function node that adds some data (the entity to call) to the message as it flows through the nodes then I want to use that data as the entity to call in the service.

I’ve tried lots of different syntaxes, {{msg.payload.data.entity}}, “{{msg.payload.data.entity}}” etc but everything gives the same error that you see on the right.

Edit your thread to node-red classification. You will likely be more successful this way.

Delete the entry from the service call. By default it will use msg.payload.data.entity. You don’t need anything in that box

1 Like

This!

Yes it works. Is there any documentation you can point me to that explains it? I hit upon using msg.payload.data from another post but didn’t really know why I was doing it.
Thanks for completing the last step for me :slight_smile:

Only thing I have is the info screen from the node. I know I have seen it somewhere else before.

Ok thank you.
I’m still not sure I really understand that text but hopefully with use I’ll get the hang of it all.