Checking MQTT Variable in Automation

Hi,
i am trying to create a simple automation with a MQTT trigger when a button on a shellyplus2pm is pressed. I already get the mqtt message in the automation with this payload.

payload: {"src":"shellyplus2pm-441793ad883c","dst":"shellies/shelly-wohnung-terasse-rechts/events","method":"NotifyEvent","params":{"ts":1676464698.32,"events":[{"component":"input:1", "id":1, "event":"single_push", "ts":1676464698.32}]}}

My problem is now that the condition is not working. I tried this templates:
{{ trigger.payload_json.params.events["event"] == "single_push" }}
AND
{{ trigger.payload_json.params.events["id"] == 1 }}

but the result for this condition is always false. what am I doing wrong?

events is a list and requires an index. Also, use bracket notation for safety: events is the sort of key that might also be a special function name. So:

{{ trigger.payload_json["params"]["events"][0]["event"] == "single_push" }}
{{ trigger.payload_json["params"]["events"][0]["id"] == 1 }}