I’m attempting to configure my Google Homes to control my OpenHAB items. I have been following the instructions at https://github.com/openhab/openhab-google-assistant , but have got stuck right near the end.
For the “Account Linkage & OAuth2” section, I need four pieces of information.
The authorisation and token URLs. Are these the URLs to my OpenHAB cloud instance?
Does anyone know where can I obtain the Client ID and Client Secret from?
Currently when I attempt to use the Web Functions app that I have created, I get a “Cannot GET /oauth” message. In this consistent with OAuth not being configured correctly?
Thanks Michael. I’m now much further along.
When “testing” my app, I get a login prompt from my OpenHAB Cloud instance, but, after logging in, I don’t get an option to authorize the app though. I get the following error.
I used these 2 commands:
db.oauth2scopes.insert( { name : “google-assistant”, description: “Access to myopenHAB specific API for Actions on Google Assistant”, } )
db.oauth2clients.insert({ clientId: “xxxxx”, clientSecret: “xxxxxxxxx” })
I am attempting also to configure my google home to control my openHAB items. I 've also followed the instructions from https://github.com/openhab/openhab-google-assistant with success but i got stuck on the same point.
Does anyone know how i can get the authorization code and the token from myopenhab?
You should be following the instructions here. the instructions in the README on github are for when you are hosting your own instance of myopenhab.org.
Thanks a lot @rlkoshak. I think i took the hard way
I follow the instructions and as myopenhab works properly the only think i had to do was to create an item file for my temperature sensor with a simple line:
Number Temperature “Temperature [%1.f °C]” [ CurrentTemperature", “Celcius” ]
After that i’ve added openhab in Google Assistant and after the authorization my item added properly and works perfect!