【问题标题】:Actions On Google: Implicit Oauth Flow, redirect failsGoogle 上的操作:隐式 Oauth 流,重定向失败
【发布时间】:2019-12-05 19:27:57
【问题描述】:

我按照以下说明为隐式流实现了自己的 Oauth 服务器:https://developers.google.com/actions/identity/oauth2?oauth=implicit

这看起来很简单,因为我只需要在检查客户端详细信息后重定向令牌。但是我遇到了问题。 我发送这个: https://oauth-redirect.googleusercontent.com/r/YOUR_PROJECT_ID?access_token=ACCESS_TOKEN&token_type=bearer&state=STATE_STRING

但是,当您重定向到此 URL 时,这似乎会扰乱 google 上的操作。 “Sing in Helper”意图似乎起作用然后失败,控制台没有显示任何错误Intent not working

我将不胜感激。

【问题讨论】:

    标签: redirect oauth-2.0 actions-on-google implicit-flow


    【解决方案1】:

    尝试切换 ?在 url 中添加一个#。 然后,这将在 url 中使用碎片,这将允许 google 读取参数。

    https://oauth-redirect.googleusercontent.com/r/YOUR_PROJECT_ID#access_token=ACCESS_TOKEN&token_type=bearer&state=STATE_STRING

    【讨论】:

    • 我几天前遇到了同样的问题,这似乎解决了它
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2016-08-01
    • 2011-12-16
    • 2017-09-15
    • 2018-10-20
    • 2013-05-02
    • 2017-05-03
    相关资源
    最近更新 更多