Connect to running Home Assistant instance CLI?

Maybe this is already possible but I would like to connect to an existing HA instance (running as a daemon or systemd for instance) so you can see the current log output and use the CLI.

If you want to see the log output, just run tail on <config_dir>/home-assistant.log

There is no real CLI, except for startup, and that is just hass which is located in <install_dir>/bin/hass however, I never use it except to call hass --script check_config

I started with a CLI for Home Assistant a while ago as a prototype.

Not much feedback. Thus not much progress.

Using the Server-sent events allows you to consume messages as well.

Or the WebSocket API.

I just started with Home Assistant, so I’m not sure how this could be implemented or how much demand there is. It’s just that while playing around with HA I felt that it was missing something like this.

It would be useful to have an actual console which you can use as a low level interface in case the web interface fails for example. And where you could see the log, set verbosity of log messages, execute queries and simple commands, just like many other systems that provide network services. OpenHAB also has something like it. Maybe it can give some inspiration.

Great to read that some attempt has already been made! I will have a go with it at a later stage.