Problems to connect to Gardena cloud service with the Gardena binding

I am on openhab 3.0.2. I find this entry in openhab.log every 10 seconds (10 seconds are my timeout setting for the Gardena binding):

2021-05-13 18:21:45.342 [WARN ] [ternal.handler.GardenaAccountHandler] - Error 429 null, {"message":"Limit Exceeded"}

I discovered it today, but my logfiles show it starting from April 30th. Maybe it started earlier, but older logfiles are deleted. The binding configuration was working before with openhab 3.0.1 and since then it has been unchanged.

Additionally the “Gardena Smart Home Account” item is in state “ERROR:COMM”. What can I do to successfully connect to the Gardena cloud service again?

I found out myself:
I created a new API-Key at this website: https://developer.husqvarnagroup.cloud/
Let’s see, if that’s a temporary solution.

After 23 days I had to renew the API-Key again. It looks, that there is a limit within the Husquana cloud service, that is reached after some events and that triggers blacklisting the API key. At this point of time I couldn’t determine the limit value.

I have five Gardena devices in operation:

  • one mower
  • three water control valves
  • one smart sensor

Maybe the number of devices has an effect on reaching the limit.

After a larger number of entries “Connection Lost” in the log these entries follow, which relate to the limit:

2021-06-07 20:11:32.127 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost
2021-06-07 20:11:45.174 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to OFFLINE (COMMUNICATION_ERROR): Error 400 Bad Request, {"error":"invalid_request","error_description":"Simultaneous logins detected for client[id=67515f31-aa98-4d53-b75e-4872b14c5144], user[id=***, email=x@y.org}]","error_code":"simultaneous.logins"}
2021-06-07 20:11:46.822 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Error 400 Bad Request, {"error":"invalid_request","error_description":"Simultaneous logins detected for client[id=67515f31-aa98-4d53-b75e-4872b14c5144], user[id=***, email=x@y.org}]","error_code":"simultaneous.logins"} to ONLINE
2021-06-07 20:12:11.960 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost
2021-06-07 20:12:16.907 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to OFFLINE (CONFIGURATION_ERROR): Device with id e8bbe3bd-f3fe-4003-ab54-15ca58f0e863 not found
2021-06-07 20:12:16.912 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (CONFIGURATION_ERROR): Device with id e8bbe3bd-f3fe-4003-ab54-15ca58f0e863 not found to OFFLINE (CONFIGURATION_ERROR): Device with id a965be7a-0069-48e8-9942-9f3d2d428aa8 not found
2021-06-07 20:12:16.914 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (CONFIGURATION_ERROR): Device with id a965be7a-0069-48e8-9942-9f3d2d428aa8 not found to OFFLINE (COMMUNICATION_ERROR): Connection lost
2021-06-07 20:12:16.919 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to OFFLINE (CONFIGURATION_ERROR): Device with id c71780c8-c982-4051-91ec-de4cd444fdd5 not found
2021-06-07 20:12:16.922 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (CONFIGURATION_ERROR): Device with id c71780c8-c982-4051-91ec-de4cd444fdd5 not found to OFFLINE (CONFIGURATION_ERROR): Device with id 01d1e252-e394-4749-86b8-ca0e50786edc not found
2021-06-07 20:12:16.929 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (CONFIGURATION_ERROR): Device with id 01d1e252-e394-4749-86b8-ca0e50786edc not found to OFFLINE (CONFIGURATION_ERROR): Device with id 66eb06fb-93dc-4e47-a216-885f59ff172f not found
2021-06-07 20:12:36.254 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (CONFIGURATION_ERROR): Device with id 66eb06fb-93dc-4e47-a216-885f59ff172f not found to OFFLINE (COMMUNICATION_ERROR): Idle timeout 10000 ms
2021-06-07 20:12:38.528 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Idle timeout 10000 ms to OFFLINE (COMMUNICATION_ERROR): Error 400 Bad Request, {"error":"invalid_request","error_description":"Simultaneous logins detected for client[id=67515f31-aa98-4d53-b75e-4872b14c5144], user[id=***, email=x@y.org}]","error_code":"simultaneous.logins"}
2021-06-07 20:12:45.481 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Error 400 Bad Request, {"error":"invalid_request","error_description":"Simultaneous logins detected for client[id=67515f31-aa98-4d53-b75e-4872b14c5144], user[id=***, email=x@y.org}]","error_code":"simultaneous.logins"} to ONLINE
2021-06-07 20:12:47.281 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost2021-06-07 20:12:52.251 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to OFFLINE (COMMUNICATION_ERROR): Error 400 Bad Request, {"error":"invalid_request","error_description":"Simultaneous logins detected for client[id=67515f31-aa98-4d53-b75e-4872b14c5144], user[id=***, email=x@y.org}]","error_code":"simultaneous.logins"}
2021-06-07 20:12:52.935 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Error 400 Bad Request, {"error":"invalid_request","error_description":"Simultaneous logins detected for client[id=67515f31-aa98-4d53-b75e-4872b14c5144], user[id=***, email=x@y.org}]","error_code":"simultaneous.logins"} to OFFLINE (COMMUNICATION_ERROR): Connection lost
2021-06-07 20:12:53.955 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to ONLINE
2021-06-07 20:12:59.856 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost
2021-06-07 20:13:14.776 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to OFFLINE (COMMUNICATION_ERROR): org.eclipse.jetty.websocket.api.UpgradeException: Failed to upgrade to websocket: Unexpected HTTP Response Status Code: 410 Gone
2021-06-07 20:13:16.600 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): org.eclipse.jetty.websocket.api.UpgradeException: Failed to upgrade to websocket: Unexpected HTTP Response Status Code: 410 Gone to OFFLINE (COMMUNICATION_ERROR): Connection lost
2021-06-07 20:13:17.759 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to ONLINE
2021-06-07 20:13:17.930 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost
2021-06-07 20:13:23.855 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to ONLINE
2021-06-07 20:13:44.967 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Error 429 null, {"message":"Limit Exceeded"}
2021-06-07 20:13:55.001 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:010d0959' changed from OFFLINE (COMMUNICATION_ERROR): Error 429 null, {"message":"Limit Exceeded"} to OFFLINE (CONFIGURATION_ERROR): Device with id e8bbe3bd-f3fe-4003-ab54-15ca58f0e863 not found

The authentication information in these log entries is anonymized and the clientId is invalidated.

I appreciate any hint to avoid reaching this limit which stops the operation of the binding and requires manual intervention (creation of a new API key).

3,000 a month.
That’s about one every fifteen minutes.
It also says it’ll throttle you to one every 15 minutes anyway, i.e. discard or reject more frequent calls.

The binding doesn’t seem to offer you any control over that rate.

Hi,
I am experiencing the same problem. Periodically, I am loosing connection to Gardena cloud,

2021-06-13 13:06:10.907 [WARN ] [rdena.internal.GardenaSmartWebSocket] - Gardena Webservice error (home-My Garden): Broken pipe, restarting

2021-06-13 13:06:10.911 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:home' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost

2021-06-13 13:06:23.312 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:home' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to ONLINE

2021-06-13 13:06:37.212 [WARN ] [rdena.internal.GardenaSmartWebSocket] - Gardena Webservice error (home-My Garden): Broken pipe, restarting

2021-06-13 13:06:37.216 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:home' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost

2021-06-13 13:06:49.346 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:home' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to ONLINE

2021-06-13 13:07:12.327 [WARN ] [rdena.internal.GardenaSmartWebSocket] - Gardena Webservice error (home-My Garden): Broken pipe, restarting

2021-06-13 13:07:12.331 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:home' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost

2021-06-13 13:07:24.462 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:home' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to ONLINE

2021-06-13 13:07:38.469 [WARN ] [rdena.internal.GardenaSmartWebSocket] - Gardena Webservice error (home-My Garden): Broken pipe, restarting

2021-06-13 13:07:38.473 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:home' changed from ONLINE to OFFLINE (COMMUNICATION_ERROR): Connection lost

2021-06-13 13:07:50.601 [INFO ] [ab.event.ThingStatusInfoChangedEvent] - Thing 'gardena:account:home' changed from OFFLINE (COMMUNICATION_ERROR): Connection lost to ONLINE

This behaviour started with the new binding in 2020. I am on OpenHABian 3.0.2 on Raspberry 4. After some time, Gardena blocks my access. Any idea?

Now I have the same problem. Gardena Thing is offline, “limit exceeded”.
Restart of OH does not help.
Access via Gardena app is possible without problems.

For me the creation of a new API key worked around the problem temporarily.

Anyway in the meantime I issued a GitHub ticket: [gardena] Binding shouldn't reach request limit on Husqvarna cloud service · Issue #10841 · openhab/openhab-addons · GitHub

Same issue , communication stop after around 20 days and I have to create a new API-Key.

OH-3.0.2 on Pi-4

Yes, after creating a new API-key, it works again.
Let’s see how long…

same here… openhab 3.1.0 release

That’s good then, you’re all working fine with a new key.

Hello,
Even if i renew the API, it connects but after one minute, i have “connection lost”

In the log i have :

 2021-08-01 17:31:44.449 [WARN ] [rdena.internal.GardenaSmartWebSocket] - Gardena Webservice error (gardenabridge-My Garden): java.util.concurrent.TimeoutException: Idle timeout expired: 150000/150000 ms, restarting

2021-08-01 17:31:44.451 [WARN ] [.core.thing.binding.BaseThingHandler] - Handler GardenaAccountHandler tried updating the thing status although the handler was already disposed.


Somebody have an idea ?

Thanks, this helped me as well.

There is a new github issue with a possible explanation for the connection issues. Something with the service_id could be wrong.
Link to the issue: [gardena] Error 400 Bad Request - Can not parse service ID · Issue #12481 · openhab/openhab-addons · GitHub

Hope somebody can fix this. For the meantime, downgrading to openHAB 2 and installing the “new” binding for openHAB3 (Link: Gardena API Binding | Eclipse Plugins, Bundles and Products - Eclipse Marketplace) works for me.