HA Fix Tracked State

I use the bond bridge via Home Assistant integration. Overall it works well and I control 9 fans with it.

My question: does anyone know a way to fix tracked state via the API. Periodically the state in the bond gets off (mainly due to “unauthorized” use of a remote) and it needs to be corrected. I would like to update the state from HA rather than having to go through the bond app (lots of menu’s to get there). Any thought/ideas?

Check out Bond Local API


I had used the local API in the past and then when the HA integration came out stopped using it. I had looked through the API documentation quickly and did not notice the “Update State Belief” command. I can use that via curl in HA to do what I want. In parallel I will see if I can work with the Bond Integration team to add this as a HA service which would be ideal.

1 Like

If you open a PR to core and ping me, I’d be happy to review it.

It looks like the underlying library will also need an adjustment to be able to patch state : bond-api/bond.py at master · prystupa/bond-api · GitHub

Thanks @bdraco,

I have not contributed to the code for HA yet, so this is as good an issue as any to start on. I have already put together a workaround using the rest_command platform but I had to manually put the bond token and device id’s into it. I think it would make sense to add it to the bond device integration itself. It will take me some time to learn the ins and outs of how to fork, test, and PR, but the documentation should show me the way. I will let you know once I have a PR ready for review.


1 Like