API Calls from outside network

Yes, I think that’s what’s happening in my case… I hope this will get fixed in version 3 that’s currently being worked on.

Thanks to all,

Just to be clrear, this is not something that can be fixed in AppDaemon, it would need a fix in the Addon.

1 Like

Yes, of course, I understand that… Thanks!

1 Like

Hi,

I had the same problem. However it’s quite easy to fix. The addon only supports one open port at the moment. I’ve created a pull request which adds another port. You can either wait till it will be merged, create a temporary local addon version or you can disable the Dashboard for now and use the REST API. Both at the same time isn’t possible.

Example for the appdaemon.yaml:

AppDaemon:
  logfile: STDOUT
  errorfile: STDERR
  threads: 10
  app_dir: /config/appdaemon/apps
  api_port: 5050
HASS:
  ha_url: !secret url
  ha_key: !secret password
#remove or comment the dashboard lines
#HADashboard:
#  dash_url: http://127.0.0.1:5050
#  dash_dir: /config/appdaemon/dashboards

It is important to set the api_port to 5050 because that is the enabled one in the docker image. You can bind the port to something else in the hass.io config window under network

2 Likes

Cool… I never thought about trying what you propose. I will give it a try and report back.

Thanks!

UPDATE: Bingo! That works. Right away, it worked. Thanks again,

1 Like

You said:

"You can bind the port to something else in the hass.io config window under network"

What do you mean by that? Which config Window? You mean in configuration.yaml?

im glad that you could prove that the conclusion that it must be hassio was right. :wink:
at least our efford has brought that the problem is now known.

Like there.

Ah, yes… Thanks!

Just a quick update. The app daemon 3 and the next version of the app daemon 2 hass io plugin will support 2 Ports. Then dashboard and the rest API will work side by side.

Good news. Thanks for the update. Any ETA for version 3 ?

The 3.0 beta is alreay out and on beta2, and Last night @frenk released an updated plugin for hass.io, for AppDaemon 3.0, it also uses beta2 for now.