Hi @Jose_Cruz,
As I understand it, your issue stems from using a single MQTT client to report data for multiple devices. While there is not a perfect way to resolve this, I do think we’ve identified a workable solution.
You’ll need to create a custom MQTT topic to report to. Then, in an application workflow, begin with an MQTT Trigger Node with the same MQTT Topic/Path that is configured in your MQTT client - so in your case the topic configured in your MQTT Client should match what is configured in the MQTT Trigger node, which is devices.
With this setup, we need a way to differentiate your devices as they report on the same topic to the Application Workflow. A unique identifier needs to be sent with each device report through your MQTT client, such as a custom unique number that you manage, a serial number, mac address, or something along those lines.
From there, use a Device: Get node and query to Match All Tags, with your key template set to the macId of your devices (or some other unique identifier) - this allows you to make the association between the specific device that is currently reporting data and its deviceID in Losant. Should that device be recognized, you can then set the device state using the Device: State node.
I’ve provided a couple of screenshots below of what this configured workflow would look like.
Hope this helps!
@Aidan_Zebertavage

