【问题标题】:How to get OAuth token without user consent?如何在未经用户同意的情况下获取 OAuth 令牌?
【发布时间】:2016-04-12 03:18:55
【问题描述】:

标准(对我而言)OAuth 流程是:

  1. 生成 url flow.step1_get_authorize_url() 并要求用户允许应用访问
  2. 获取代码
  3. 使用flow.step2_exchange(auth_code) 获取凭据

但是我遇到了另一个服务,我只需要向 token_uri 发起一个 POST 请求,client_idclient_secret 作为表单值 (application/x-www-form-urlencoded) 传递,grant_typeclient_credentials 和 @ 987654330@ 也作为表单字段值传递。

oauth2client 库支持吗?

【问题讨论】:

标签: python oauth oauth2client


【解决方案1】:

将grant_type 更新为implicit

【讨论】:

    猜你喜欢
    • 2017-07-30
    • 2014-10-31
    • 2022-12-07
    • 1970-01-01
    • 1970-01-01
    • 2017-08-15
    • 2017-06-18
    • 1970-01-01
    • 2020-10-19
    相关资源
    最近更新 更多