Help with current state node


The current state node works fine when I trigger this manually .

The current state node shows error when I try to trigger it using an automation from an event.

I am not sure what went wrong here .

--Works fine :


put a debug node on the "events' tab and see what is the format and type of the msg.payload. Is the data valid for the current state node?

Thanks for the response .Here is the output from debug node of event.

My goal is to turn on a switch based on output of the event node . Before turning on the switch ,I want to check if that switch is on or not .That is why I am using a current state node

event_type: "image_processing.detect_face"
entity_id: "image_processing.face_counter"
event: object
name: "Pav"
confidence: 78.27
entity_id: "image_processing.face_counter"