MQTT Door Lock Status Format

I have a Danalock lock on one of the doors of my house, which I am connecting to HA via MQTT. As I have multiple instances of HA, I need to manually configure the MQTT entry. While I have the lock working correctly, I cannot get its status correctly.

The lock reports its status as true/false, rather than locked/unlocked, but the command is LOCK and UNLOCK. This is what I have at the moment, but it isn’t working. I know it is the value_template I need to change, but I cannot find the correct structure - can anyone suggest what it should be please?

  - platform: mqtt
    name: Garage Side Door
    state_topic: "zwave2mqtt/Garage/Side-Door/98/1/0"
    command_topic: "zwave2mqtt/Garage/Side-Door/98/1/0/set"
    payload_lock: "LOCK"
    payload_unlock: "UNLOCK"
    state_locked: "true"
    state_unlocked: "false"
    optimistic: false
    qos: 1
    retain: true
    value_template: '{{ "value.x" }}'