A couple of questions about appdaemon

A couple of questions about appdaemon:

  • Which of the API:s is AD using? https://home-assistant.io/developers/api
  • From what I can see you dont have to run AD on the same machine as HA, right?
  • Any drawbacks on running multiple instances of AD on different machines (besides avoiding conflicts between apps)?
  • Do we have a built in way to share data between the machines, or should I use my own solution, such as an shared database etc?

AppDaemon is using the Restful API

Correct.

I haven’t found any. Event listeners will trigger on all nodes “simultaneously” (disregarding networking delays) and that could be problematic, or advantageous depending on your goal. :slight_smile:

Nothing built directly into AppDaemon will allow you to do this. Two options I can think of immediately…

  • through the Home Assistant platform itself by reading/writing to entities.
  • MQTT
1 Like

I share data between two HA instances with the built in webserver.

If you want to use Home Assistant to host or serve static files then create a directory called www under the .homeassistant configuration path. The static files in .homeassistant/www/ can be accessed by the following URL http://your.domain:8123/local/.

2 Likes

You can also communicate and pass data between AD instances using custom events - that way you can pass arbitrary Python structures back and forth.

1 Like

Given that they* can be serialized and sent via json/text - no?

Yes, I don’t think JSON serializes, so if you want to pass complex binary data you may need to do that yourself, but basically anything you can put in a dictionary you should be able to send.

Nice, thanks for the replies everyone!