[英]Created smart home activity (google home) with OAuth2 (which works) but can't Link it in the "Home" app
Introduction介绍
I've been trying to build a Google Home, Smart Home Activity that integrates with Azure AD.我一直在尝试构建与 Azure AD 集成的 Google Home、Smart Home Activity。 I've been able to correctly sign in so the ClientId/endpoints/scopes must be correct.
我已经能够正确登录,因此 ClientId/endpoints/scopes 必须正确。
When I try to connect to the Smart Home skill using the simulator it shows me an error that this functionality isn't supported in the simulator.当我尝试使用模拟器连接到智能家居技能时,它向我显示模拟器不支持此功能的错误。 So I then moved to my actual android phone.
所以我然后转移到我的实际 android 手机。 However when I try to link to the smart home service in the google home app it correctly asks me to login, but after logging in the login screen disappears and I'm back to selecting a service I want to link to.
但是,当我尝试在 google home 应用程序中链接到智能家居服务时,它正确地要求我登录,但登录后登录屏幕消失了,我又回到了选择要链接到的服务。
Flow to activate service:激活服务流程:
So after the 4th image it just goes back to the original screen and no skill was ever added.所以在第四张图片之后它只是回到原来的屏幕并且没有添加任何技能。
I've also setup NGROK as my fullfillment URL but I see no activity other then some of my own tests:我还将 NGROK 设置为我的完整版 URL 但除了我自己的一些测试之外,我没有看到任何活动:
My configuration我的配置
This is the way I've set everything up:这是我设置所有内容的方式:
Azure AD: Azure 广告:
I've also configured the direct URL to be: https://oauth-redirect.googleusercontent.com/r/davysmarthome
我还将直接 URL 配置为:
https://oauth-redirect.googleusercontent.com/r/davysmarthome
Google Home (Action):谷歌主页(行动):
Google Home (OAuth):谷歌主页(OAuth):
Summary概括
My question would be why my skill doesn't want to be linked to.我的问题是为什么我的技能不想被链接到。 I have not yet implemented anything in my actual API yet but I would expect NGROK to at least show some data traffic if google home would actually try to link itself and request what devices are connected.
我还没有在我的实际 API 中实现任何东西,但我希望 NGROK 至少会显示一些数据流量,如果谷歌主页实际上会尝试链接自身并请求连接哪些设备。
After analyzing the 4th image, it can be seen that you haven't enabled "Testing" on your project, sometimes the Account Linking process fails if testing has been disabled for any reason.分析第 4 张图片后,可以看出您没有在项目上启用“测试”,如果由于任何原因禁用了测试,有时帐户链接过程会失败。 To make sure testing is enabled for the project, go to AoG Console > Develop > Account Linking > Test (Upper Right Corner).
为确保为项目启用测试,go 到 AoG 控制台 > 开发 > 帐户链接 > 测试(右上角)。 But, in this case, it does not necessarily mean that the account linking failed, it is also possible that account linking succeeded, but failed in SmartHome Sync.
但是,这种情况下,并不一定是账号绑定失败,也有可能是账号绑定成功,但是在SmartHome Sync中失败了。 To make sure if account linking has succeeded, please visit https://myaccount.google.com/accountlinking?hl=en and check if the account has been linked correctly.
为确认帐号关联是否成功,请访问https://myaccount.google.com/accountlinking?hl=en并检查帐号是否已正确关联。
There are other tools available that can help you with debugging OAuth issues such as "OAuth Playground".还有其他可用的工具可以帮助您调试 OAuth 问题,例如“OAuth Playground”。 It helps in finding out the exact issue causing the error.
它有助于找出导致错误的确切问题。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.