Innogy SmartHome - "Unexcepted API error: Remote access not allowed"

Thanks a lot. That’s the output:

2018-03-11 15:34:08.042 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Initializing innogy SmartHome BridgeHandler...
2018-03-11 15:34:08.042 [DEBUG] [marthome.handler.InnogyBridgeHandler] - innogy config: Config [clientId=24635748, clientSecret=no secret, redirectUrl=https://www.ollie.in/innogy-smarthome-token/, authCode=, accessToken=eyJ0eXAiOi...-__V-gQmHw, refreshToken=47b18...d9bda]
2018-03-11 15:34:08.042 [INFO ] [marthome.handler.InnogyBridgeHandler] - Initializing innogy SmartHome client...
2018-03-11 15:34:08.042 [DEBUG] [arthome.internal.client.InnogyClient] - Initializing innogy SmartHome Session...
2018-03-11 15:34:08.374 [DEBUG] [arthome.internal.client.InnogyClient] - [1] Statuscode is NOT OK: 403
2018-03-11 15:34:08.374 [DEBUG] [arthome.internal.client.InnogyClient] - Remote access not allowed. Access is allowed only from the SHC device network.
2018-03-11 15:34:08.374 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Remote access not allowed. Dropping access token and reinitializing binding...
2018-03-11 15:34:08.374 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Scheduling reinitialize in 0 seconds.
2018-03-11 15:34:08.374 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Unexcepted API error: Remote access not allowed. Access is allowed only from the SHC device network.
2018-03-11 15:34:08.374 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Initializing innogy SmartHome BridgeHandler...
2018-03-11 15:34:08.374 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Disposing innogy SmartHome bridge handler 'SMARTHOME10'
2018-03-11 15:34:08.374 [DEBUG] [marthome.handler.InnogyBridgeHandler] - innogy config: Config [clientId=24635748, clientSecret=no secret, redirectUrl=https://www.ollie.in/innogy-smarthome-token/, authCode=, accessToken=eyJ0eXAiOi...-__V-gQmHw, refreshToken=47b18...d9bda]
2018-03-11 15:34:08.374 [DEBUG] [arthome.internal.client.InnogyClient] - Uninitializing innogy SmartHome Session...
2018-03-11 15:34:08.374 [INFO ] [marthome.handler.InnogyBridgeHandler] - Initializing innogy SmartHome client...
2018-03-11 15:34:08.374 [DEBUG] [arthome.internal.client.InnogyClient] - Initializing innogy SmartHome Session...
2018-03-11 15:34:08.411 [DEBUG] [arthome.internal.client.InnogyClient] - [2] Statuscode is NOT OK: 404
2018-03-11 15:34:08.411 [DEBUG] [arthome.internal.client.InnogyClient] - Session not found: ErrorResponse [code=2012, description=Session not found, messages=[Session not found: e76ce0b5232b46bb8bd004c78babf7dc]]
2018-03-11 15:34:08.411 [DEBUG] [marthome.handler.InnogyBridgeHandler] - innogy SmartHome bridge handler shut down.
2018-03-11 15:34:08.411 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Scheduling reinitialize in 120 seconds.
2018-03-11 15:34:08.411 [ERROR] [marthome.handler.InnogyBridgeHandler] - Error initializing innogy SmartHome client.
2018-03-11 15:34:08.543 [DEBUG] [arthome.internal.client.InnogyClient] - [1] Statuscode is NOT OK: 403
2018-03-11 15:34:08.543 [DEBUG] [arthome.internal.client.InnogyClient] - Remote access not allowed. Access is allowed only from the SHC device network.
2018-03-11 15:34:08.558 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Remote access not allowed. Dropping access token and reinitializing binding...
2018-03-11 15:34:08.558 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Scheduling reinitialize in 0 seconds - ignored: already triggered in 119 seconds.
2018-03-11 15:34:08.558 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Unexcepted API error: Remote access not allowed. Access is allowed only from the SHC device network.
2018-03-11 15:34:08.558 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Disposing innogy SmartHome bridge handler 'SMARTHOME10'
2018-03-11 15:34:08.558 [DEBUG] [marthome.handler.InnogyBridgeHandler] - innogy SmartHome bridge handler shut down.
2018-03-11 15:34:08.558 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Scheduling reinitialize in 120 seconds.
2018-03-11 15:34:08.558 [ERROR] [marthome.handler.InnogyBridgeHandler] - Error initializing innogy SmartHome client.
2018-03-11 15:36:08.565 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Initializing innogy SmartHome BridgeHandler...
2018-03-11 15:36:08.566 [DEBUG] [marthome.handler.InnogyBridgeHandler] - innogy config: Config [clientId=24635748, clientSecret=no secret, redirectUrl=https://www.ollie.in/innogy-smarthome-token/, authCode=, accessToken=eyJ0eXAiOi...-__V-gQmHw, refreshToken=47b18...d9bda]
2018-03-11 15:36:08.567 [INFO ] [marthome.handler.InnogyBridgeHandler] - Initializing innogy SmartHome client...
2018-03-11 15:36:08.567 [DEBUG] [arthome.internal.client.InnogyClient] - Initializing innogy SmartHome Session...
2018-03-11 15:36:08.818 [DEBUG] [arthome.internal.client.InnogyClient] - [1] Statuscode is NOT OK: 403
2018-03-11 15:36:08.818 [DEBUG] [arthome.internal.client.InnogyClient] - Remote access not allowed. Access is allowed only from the SHC device network.
2018-03-11 15:36:08.818 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Remote access not allowed. Dropping access token and reinitializing binding...
2018-03-11 15:36:08.818 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Scheduling reinitialize in 0 seconds.
2018-03-11 15:36:08.818 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Unexcepted API error: Remote access not allowed. Access is allowed only from the SHC device network.
2018-03-11 15:36:08.818 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Initializing innogy SmartHome BridgeHandler...
2018-03-11 15:36:08.818 [DEBUG] [marthome.handler.InnogyBridgeHandler] - innogy config: Config [clientId=24635748, clientSecret=no secret, redirectUrl=https://www.ollie.in/innogy-smarthome-token/, authCode=, accessToken=eyJ0eXAiOi...-__V-gQmHw, refreshToken=47b18...d9bda]
2018-03-11 15:36:08.818 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Disposing innogy SmartHome bridge handler 'SMARTHOME10'
2018-03-11 15:36:08.818 [DEBUG] [arthome.internal.client.InnogyClient] - Uninitializing innogy SmartHome Session...
2018-03-11 15:36:08.818 [INFO ] [marthome.handler.InnogyBridgeHandler] - Initializing innogy SmartHome client...
2018-03-11 15:36:08.818 [DEBUG] [arthome.internal.client.InnogyClient] - Initializing innogy SmartHome Session...
2018-03-11 15:36:08.872 [DEBUG] [arthome.internal.client.InnogyClient] - [2] Statuscode is NOT OK: 404
2018-03-11 15:36:08.872 [DEBUG] [arthome.internal.client.InnogyClient] - Session not found: ErrorResponse [code=2012, description=Session not found, messages=[Session not found: e76ce0b5232b46bb8bd004c78babf7dc]]
2018-03-11 15:36:08.872 [DEBUG] [marthome.handler.InnogyBridgeHandler] - innogy SmartHome bridge handler shut down.
2018-03-11 15:36:08.872 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Scheduling reinitialize in 120 seconds.
2018-03-11 15:36:08.872 [ERROR] [marthome.handler.InnogyBridgeHandler] - Error initializing innogy SmartHome client.
2018-03-11 15:36:09.088 [DEBUG] [arthome.internal.client.InnogyClient] - [1] Statuscode is NOT OK: 403
2018-03-11 15:36:09.104 [DEBUG] [arthome.internal.client.InnogyClient] - Remote access not allowed. Access is allowed only from the SHC device network.
2018-03-11 15:36:09.104 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Remote access not allowed. Dropping access token and reinitializing binding...
2018-03-11 15:36:09.104 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Scheduling reinitialize in 0 seconds - ignored: already triggered in 119 seconds.
2018-03-11 15:36:09.104 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Unexcepted API error: Remote access not allowed. Access is allowed only from the SHC device network.
2018-03-11 15:36:09.104 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Disposing innogy SmartHome bridge handler 'SMARTHOME10'
2018-03-11 15:36:09.104 [DEBUG] [marthome.handler.InnogyBridgeHandler] - innogy SmartHome bridge handler shut down.
2018-03-11 15:36:09.104 [DEBUG] [marthome.handler.InnogyBridgeHandler] - Scheduling reinitialize in 120 seconds.
2018-03-11 15:36:09.104 [ERROR] [marthome.handler.InnogyBridgeHandler] - Error initializing innogy SmartHome client.

Thanks for the logs, @sayhelloto. I’ll talk to the developers again as this definetely means that it does not work. :frowning:

But wait - it seems you have the same accesstoken every time again. Maybe I missed something. I’ll dig into it again and get back to you - hopefully I can make it this weekend.

1 Like

hi oliver, for me the getting of authtoken doesn’t work at all… when i click on the link in openhab paperui, it takes me to the login screen but nothing happens there. i enter my user/pass but instead of being redirected to you’re page, i’m being presented with a login form again…

is this link working for you? https://api.services-smarthome.de/AUTH/authorize?response_type=code&client_id=24635750&redirect_uri=https%3A%2F%2Fwww.ollie.in%2Fstart-smarthome-token%2F&scope&lang=de-DE

I’m getting as a response: Wrong provider. Please use the correct client to login.

Hi,

here comes a new version:
http://www.ollie.in/wp-content/uploads/2018/03/org.openhab.binding.innogysmarthome-2.3.0-SNAPSHOT-180323.jar

@sayhelloto: this should hopefully now create new tokens and solve the “unexpected api error”. Please test!

@suntribe: What brand do you use? Please try the URLs from here, as there is a version with wrong URLs.

Regarding auth-URLs, the new version above already has newer URLs included, which are not yet active in the innogy backend and will be changed there soon. So please use the URLs from the README.md.

Hi ollie,

unfortunately I’m not able to test if this version works. I’ve contacted the innogy support about this too since their own app didn’t work well as well with no mobile access. I needed to sign out and back in every day. They “fixed” this by giving me the mobile access for free. There weren’t any problems since then with the binding.

Just for you information: I needed to delete and readd the SmartHome Controller thing in the Paper UI to get it to work initially.

Hi @oliver_kuhl , i managed to pass the authorization by following one link on page 30 of some german forum :slight_smile: Anyways, i update to the last version now and will see how it behaves now…

I have one more question. When i bought innogy smarthome central unit and RSTs i had to register with innogy and then i got a two-year free mobile access. Will this binding work after that period will end?

Btw, so far, new version of the binding is working ok…

1 Like

Yes it should - I do not have such a subscription. And I hope those IP change errors are now gone with the new version.

1 Like

it looks to me like they’re gone… there were few disconnect/reconnect but they happened the first day i installed the latest version. It can be linked to smth else also, but since then, i haven’t noticed same behaviour… all looks smooth :slight_smile:

1 Like

FYI:

1 Like

Hi,

I have updated my SHC to the new Innogy Firmware. All worked flawless but after some hours I have received the already mentioned error:

OFFLINE - COMMUNICATION_ERROR Remote access not allowed. Access is allowed only from the SHC device network.

I am running the latest 2.4.x snapshot. Any ideas how to fix this?

best regards René

The issue should be fixed. Do you have the DEBUG logging enabled? If not, please do it and send me the log entries around the error. Usually, after the error message occurs, the binding grabs a new auth-token and retries the login, which then should work.

Hi,

thanks for your reply. I bought the remote access for 15€ now it is working. Lets see what happens after 12 month :wink: Oliver thanks again for your wonderful binding.

best regards René

Hello, I have been using the Innogy binding successfully for a few years now but now I get the remote access error:

org.openhab.binding.innogysmarthome.internal.client.exception.RemoteAccessNotAllowedException: Remote access not allowed. Access is allowed only from the SHC device network.>

I don’t want to pay for the remote access and this has not been necessary so far.
The relevant DEBUG log is this:

15:39:46.385 [DEBUG] [marthome.internal.client.InnogyClient] - Saving access token.
15:39:46.388 [DEBUG] [marthome.internal.client.InnogyClient] - Initializing innogy SmartHome Session…
15:39:46.418 [DEBUG] [marthome.internal.client.InnogyClient] - [1] Statuscode is NOT OK: 403
15:39:46.422 [DEBUG] [marthome.internal.client.InnogyClient] - Remote access not allowed. Access is allowed only from the SHC device network.
15:39:46.425 [DEBUG] [.internal.handler.InnogyBridgeHandler] - Remote access not allowed. Dropping access token and reinitializing binding…
15:39:46.428 [DEBUG] [.internal.handler.InnogyBridgeHandler] - Scheduling reinitialize in 0 seconds - ignored: already triggered in 119 seconds.
15:39:46.431 [DEBUG] [.internal.handler.InnogyBridgeHandler] - Unexcepted API error: Remote access not allowed. Access is allowed only from the SHC device network.
15:39:46.434 [ERROR] [ogysmarthome.internal.InnogyWebSocket] - innogy WebSocket onError() - Failed to upgrade to websocket: Unexpected HTTP Response Status Code: 403 Forbidden
15:39:46.436 [DEBUG] [.internal.handler.InnogyBridgeHandler] - Disposing innogy SmartHome bridge handler ‘SMARTHOME08’
15:39:46.441 [DEBUG] [.internal.handler.InnogyBridgeHandler] - ExecutionException: UpgradeException: Failed to upgrade to websocket: Unexpected HTTP Response Status Code: 403 Forbidden
15:39:46.447 [DEBUG] [.internal.handler.InnogyBridgeHandler] - Disposing innogy SmartHome bridge handler ‘SMARTHOME08’
15:39:46.448 [DEBUG] [.internal.handler.InnogyBridgeHandler] - innogy SmartHome bridge handler shut down.
15:39:46.451 [DEBUG] [.internal.handler.InnogyBridgeHandler] - innogy SmartHome bridge handler shut down.
15:39:46.454 [DEBUG] [.internal.handler.InnogyBridgeHandler] - Scheduling reinitialize in 120 seconds.
15:39:46.456 [DEBUG] [.internal.handler.InnogyBridgeHandler] - Scheduling reinitialize in 30 seconds.

It would be great if anybody could help. Thanks!

@sloth0815 you need to update to OH 2.5.1. Innogy has deprecated API v1.0.

If you’re already on OH 2.5, just restart the Innogy bridge. Remote access is definitely not required for OH, but I’ve seen that error too in the past.

I am running OpenHAB 2.5 and have restarted the Innogy bridge but it still does not work. Should I delete the Innogy bridge Thing and search for it again?

You can try, but I doubt it will make much of a difference.

Last time I had the remote access error a restart of the bridge was enough to get things working again.
That being said, the initial cause was an outage of the Innogy backend and I couldn’t access the official app/web frontend as well (same error message). Are those still working for you?

I can access the bridge via the Innogy web interface without issue. Re-adding the bridge Thing unfortunately did not help. Still stuck.

Bumping this as I am still stuck with a bunch of Innogy devices that I cannot access via OpenHAB. Any ideas are highly welcome. Thanks!