NIBE Uplink API component (non S-series)

It seems the dependent library nibeuplink is missing. I guess this is supposed to be installed automatically but fails in hassio for some reason. How did you solve this nickcj?

Hi, could you solve the issue?
I have similar problem.
In case I have to install manually where do I have to put it?

I will not look myself att hassio installation issues. I dont use It it. seems it may need to be wrapped in a addon somehow. You can get around it with manual install of nibeuplink component inside docker. Google on custom dep install hassio.

I will accept a pull request for it.

One step forward, now I get:

Platform nibe not ready yet. Retrying in 180 seconds.

Did you manage to install nibeuplink in Hass.io? If so, how did you do that?

I try to give all infos:

  1. installed addon Custom deps deployment
    Config:
    {
    ā€œpypiā€: [
    ā€œnibeuplinkā€
    ],
    ā€œapkā€: []
    }

  2. I temporarly redirected 8123 port from outside world to the device where I have installed hassio

  3. I followed the general instructions to activate it

You dont need to redirect/publish the port. You can enter a internal local url as redirect url.

iā€™m trying to intergrade my nibe but not sure what to write under system and unit (red marked in your config) Can you please help me?

System should be your system id (From the nibe link stated above. Unit should be 0 and of you have more then one unit (I have a vvm325 and a f2120) the next unit should be 1.

Got it to work. How do you use the intergration? Any automation or other nice things to set up?

Works fine in hassio. Just follow instructions from elupus.

I thought you were using hassbian! :wink:
Any clue of why nibeuplink wonā€™t install automagically for me or how I can troubleshoot that in hassio?

I was, but setting up ssl and stuff was a pain. So, just switched to hassio

When I try to add this repository as add-on repository I get ā€œCanā€™t read repository information from /data/addons/git/f166caec/repository.jsonā€ in system log, am I doing something wrong?

If I am to copy it manually instead, in which format should it be? The entire zip-file? Or the folder hass_nibe-master? What should be the content in config/custom_components?

Iā€™m on hassio by the way.

The content of zip file should be in your custom_components.

Ie:
custom_components/nibe/
custom_components/climate/

1 Like

Just follow elupus instructions and you are good to go, the files must go in your custom_components folder. If you donā€™t have it you must make one.

nickcjā€™s post above shows how it should be installed: NIBE Uplink API component

1 Like

Somehow, nibeuplink must have been installed after some restarts. All of a sudden the ā€œnew component have been discoveredā€ box showed up and I was able to successfully get it up and running in Hassio 0.85.1 :grinning: Thanks for all your work on this component eluplus!! :+1:

I hit the NIBE API request limit. How often does hass_nibe make calls? Is there anyway to configure/limit how often the API should be called?

Here what NIBE says about the limit in their docs at https://api.nibeuplink.com/docs/v1

## Rate Limiting and Client Abuse

The NIBE Uplink API is rate limited. All requests reaching the NIBE Uplink API is counted and when the limit has been reached the following requests will get an error message with the HTTP status code 429 in return. The current limit for public API clients is one request every 4th second with occasional bursts allowed. These limits can be be adjusted at any time without notice if deemed necessary.

If an application or client is found abusing the API in any way, NIBE Energy Systems has the right to block it until the client owner has solved the issues highlighted by NIBE.

My log:

2019-02-05 11:39:48 ERROR (MainThread) [homeassistant.core] Error doing job: Task exception was never retrieved
Traceback (most recent call last):
  File "/config/custom_components/nibe/__init__.py", line 380, in update
    notice = await self.uplink.get_notifications(self.system_id)
  File "/config/deps/lib/python3.6/site-packages/nibeuplink/__init__.py", line 410, in get_notifications
    data = await self.get('systems/{}/notifications'.format(system_id), params=params)
  File "/config/deps/lib/python3.6/site-packages/nibeuplink/__init__.py", line 218, in get
    headers= {},
  File "/config/deps/lib/python3.6/site-packages/nibeuplink/__init__.py", line 240, in _request
    await raise_for_status(response)
  File "/config/deps/lib/python3.6/site-packages/nibeuplink/__init__.py", line 74, in raise_for_status
    headers=response.headers)
aiohttp.client_exceptions.ClientResponseError: 429, message='{
  "httpStatusCode": 400,
  "errorCode": 28,
  "timestamp": "2019-02-05T10:39:48.7377341Z",
  "details": [
    "You have exceeded the API request rate limit and have been blocked temporarily."
  ],
  "data": null
}'

Very odd. It should be limited to 1 requests per 4 seconds. That said. It is set to be exactly every 4 seconds. Sadly, there is currently no way to change it to something higher from config.

I suppose set commands bypass this. Did you change some value often?

I donā€™t have premium account and thus do not make any set calls?

Where in the code do you set that 4 seconds interval? I found this in init.py:

INTERVAL = timedelta(minutes=1)

but that seems to be 1 minuteā€¦ :slight_smile: