Stumpped need help with mqtt trigger and actions in a blueprint

Help I’m Stumpped.
I’ve read the docs searched the forum but still stumpped
I’m trying to create a blueprint which will run some actions based on mqtt trigger.
Below is the bottom part of blueprint.
How do I pass the result of the trigger payload to the action block.

I know the device works and if I listen to the mqtt it does pass the “on”, “off”, etc.



’ mode: restart
max_exceeded: silent
trigger_variables:
base_topic: !input base_topic
controller: !input controller
trigger:

  • platform: mqtt
    topic: ‘{{ base_topic ~ ‘’/’’ ~ controller ~ ‘’/action’’ }}’
    action:
  • variables:
    command: ‘{{ trigger.topic }}’ <---- This is probably wrong
  • choose:
    • conditions:
      • ‘{{ command == “on” }}’
        sequence: !input button_on
    • conditions:
      • ‘{{ command == “off” }}’
        sequence: !input button_off
    • conditions:
      • ‘{{ command == “brightness_move_up” }}’
        sequence: !input button_on_long_press
    • conditions:
      • ‘{{ command == “brightness_move_down” }}’
        sequence: !input button_off_long_press
    • conditions:
      • ‘{{ command == “brightness_stop” }}’
        sequence: !input button_long_press_stop

Available MQTT Trigger data

If the data you want is in the payload, you would start with trigger.payload.

You can check the automation’s trace of a previous run. In the lower section, click on “Changed Variables” and find the payload value to check what data type it is returning.