Device Tools: Create, Modify and Merge Devices

Devices and their pages are a great way to group entities and see relevant information about a physical device in one glance.

Unfortunately many custom and core integration are not using the built in ways to reuse existing devices or attach lose entities to their associated device.

Also users are not allowed to manually create devices or override device attributes in any way although sometimes this functionality would be helpful with better representing the actual physical device’s information.

All this and more is now possible with the brand new Device Tools integration for Home Assistant!

Just install the integration with HACS, set up a config entry for your device and start taking control! If you made a mistake or want to reset all the changes you made, simply delete the config entry and all changes will be automatically reverted for you.

I hope you have fun with this integration and if you find any bugs or have any suggestions on how to improve it, please feel free to open an issue.

16 Likes

In the installation section of your GitHub page, users need to install the custom repository before they can use HACS.

They then need to go to the integrations page and create a new integration for “Device Tools”.

And I’m really not clear about what to do next… I was hoping to create a “device” to contain the entities created by a .yaml integration.

To install this integration you will have to install the HACS store. After that you can add the device-tools integration as a custom repository, install it and restart Home Assistant. Now you can configure device modifications by using the “Add integration” button and searching for Device Tools.

To create a new device, you simply set a modification name and leave the device selector empty. In the next page you input the name for the new device. After a few seconds the device should be created. To add entities or configure attributes for the device, you use the “Configure” button on the config entry.

Also please update to 1.8.1 if you already installed the integration since there was a bug preventing you from configuring newly created devices.

4 Likes

1.8.1 working well, thanks. Is there any way to include template-created entities in a device? They don’t seem to appear in the drop-down list.

Edit: Got it - you have to assign them a unique id.

3 Likes

Hi,

I have a bunch of sensor entities created by pushing them to HomeAssistant using the REST api. Now I’d like to assign those to a device, but they’re not listed when I click on configure and select entity.

I also tried to use the example sensor from example-custom-config/custom_components/example_sensor/sensor.py at fd0c35485eb9ee29f0a683794cae8c432c849146 · home-assistant/example-custom-config · GitHub but that way I’m also not able to add the sensor.

What am I doing wrong? Any idea?

It might be that those entities do not have a unique_id which is required by device-tools to assign them to devices.

OK, thanks. That’s the point. I’ll try to migrate to using MQTT as this assigns unique_ids automatically if I understood it correctly.

nice, this really scratches an itch! Any thoughts on being able to ‘yaml’ my way into creating a new device?

use case:

  • I create a lot of custom sensors/numbers that I use to ‘configure’ rooms, e.g. when is it dark in a room, when is it cold in a room, etc.
  • some of the rooms don’t feature these sensors, so I made a python script that makes my .yaml files.

It would be amazing if I’d be able to add these entities programmatically as well to your integration.

I can’t believe I have only just found this. Thank you for this integration.

2 Likes

Thanks for the integration!
The documentation is a little bit limited on the github page, so I found this topic with a little bit more information. Would be nice, if you can add some more docu at the github.

3 Likes

Thats so cool. Thank you. Works like a charm.

Thanks @EuleMitKeule for the integration!
I did not find any instructions on how to use the integration after installing it so I’m a bit out of luck in finding the user interface where I can assign an entity to a device. I didn’t for example find it in the settings of an entity (I confirmed that my entity has a unique id). It would be really nice to see a few screenshots of the integration in action :slight_smile:

@celindho Hi! I am currently working on improving the documentation and the overall stability of the integration. To create modifications, you need to click “Add integration” on the integrations page and select “Device Tools”. Then you can select what kind of modification you want to create and configure everything.

1 Like