Sure. If your device has been successfully paired then it will get an entry added to the configuration file. Check out this configuration file to find the friendly name associated with the device (most likely you already edited this file before as one of the first thing people do is changing the friendly name). This command will show the configuration file.
cat /opt/zigbee2mqtt/data/configuration.yaml
Then a simple MQTT IN node added to a Node-RED flow will be able to get the values from the device. You want to configure the topic in this node as: zigbee2mqtt/friendly_name
. Alternatively you can get the latest values by publishing to the topic zigbee2mqtt/friendly_name/get
.
Well, below flow is probably self explanatory. Jut edit the configuration of the MQTT node to point it to your MQTT broker (the same one configured in the zigbee2mqtt gateway). Edit also the friendly_name to match yours.
[{"id":"8ec5512b.3dd93","type":"mqtt in","z":"59a9124d.bf2cbc","name":"","topic":"zigbee2mqtt/friendly_name","qos":"2","datatype":"utf8","broker":"4b8b1456.e440dc","x":270,"y":1600,"wires":[["27257ffd.5d904"]]},{"id":"27257ffd.5d904","type":"debug","z":"59a9124d.bf2cbc","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":490,"y":1600,"wires":[]},{"id":"ee2fc280.38cb2","type":"mqtt out","z":"59a9124d.bf2cbc","name":"","topic":"","qos":"2","retain":"false","broker":"4b8b1456.e440dc","x":530,"y":1680,"wires":[]},{"id":"f6ce06f3.c982e8","type":"inject","z":"59a9124d.bf2cbc","name":"","topic":"zigbee2mqtt/friendly_name/get","payload":"{\"state\":\"\"}","payloadType":"json","repeat":"","crontab":"","once":false,"onceDelay":0.1,"x":300,"y":1680,"wires":[["ee2fc280.38cb2"]]},{"id":"4b8b1456.e440dc","type":"mqtt-broker","z":"","name":"Home Broker","broker":"192.168.1.40","port":"1883","clientid":"","usetls":false,"compatmode":true,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""}]