# Block specific device via MQTT

**URL:** <https://forums.losant.com/t/block-specific-device-via-mqtt/5686>\
**Category:** Help\
**Tags:** mqtt, workflow, device\
**Created:** [November 25, 2024, 2:12pm UTC](https://forums.losant.com/t/block-specific-device-via-mqtt/5686 "2024-11-25T14:12:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Jonatas\_Liasch](https://avatars.discourse-cdn.com/v4/letter/j/b3f665/32.png) [@Jonatas\_Liasch](https://forums.losant.com/u/Jonatas_Liasch)\
**Post date:** [November 25, 2024, 2:12pm UTC](https://forums.losant.com/t/block-specific-device-via-mqtt/5686/1 "2024-11-25T14:12:37Z")

</div>

Hi  
I have several devices connected to the platform via MQTT, these devices execute a workflow when they send data to the system.

 ![image](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/5/5f98644a852b5c90e9ea9d23e1ea2989a1d9b3cf.png)

I would like to know if it is possible to block the system so that a device no longer sends data?

NOTE: I create an individual Access Key for each device, and if I deactivate this access key, it really stops writing data to the device, but it still continues to receive messages via MQTT, and performs other functions in the system. I would like to block it completely

 ![image](https://us1.discourse-cdn.com/flex015/uploads/getstructure/original/2X/0/0769d7a8874f3e987f42d4399edb89726c8961d6.png)

Can you help me?

---

<div class="post-metadata">

**Author:** ![Dylan\_Schuster](https://sea1.discourse-cdn.com/flex015/user_avatar/forums.losant.com/dylan_schuster/32/2850_2.png) [@Dylan\_Schuster](https://forums.losant.com/u/Dylan_Schuster)\
**Post date:** [November 25, 2024, 2:49pm UTC](https://forums.losant.com/t/block-specific-device-via-mqtt/5686/2 "2024-11-25T14:49:19Z")

</div>

There is no way, from the device itself, to stop all state reports generated from [Device: State Nodes](https://docs.losant.com/workflows/outputs/device-state/) or through the [Device: Send State API endpoint](https://docs.losant.com/rest-api/device/#send-state) to record; same goes for stopping [commands](https://docs.losant.com/devices/commands/) from being published to the device’s topic as those publishes succeed - and result in a billable payload - regardless of if the device is connected to the broker.

We do expose [advanced query for workflows](https://docs.losant.com/rest-api/flows/#get) in our API; you could perhaps use that to track down which workflows are generating the activity for the device.

You could then write some logic into the flow, or whatever is kicking it off, to skip the device you would like to disable. I would do this with an “isDisabled = true” tag on the device, which would allow you to disable other devices in the future.

---

<div class="post-metadata">

**Author:** ![Jonatas\_Liasch](https://avatars.discourse-cdn.com/v4/letter/j/b3f665/32.png) [@Jonatas\_Liasch](https://forums.losant.com/u/Jonatas_Liasch)\
**Post date:** [November 25, 2024, 4:46pm UTC](https://forums.losant.com/t/block-specific-device-via-mqtt/5686/3 "2024-11-25T16:46:14Z")

</div>

Thanks @Dylan_Schuster for your help  
I thought there was some way to do this blocking remotely  
I’m going to try doing it the way you said, then at least it won’t execute other commands within the workflow
