【问题标题】:Twitter auth configuration missing (ParseTwitterUtils)缺少 Twitter 身份验证配置 (ParseTwitterUtils)
【发布时间】:2018-04-28 00:49:48
【问题描述】:

没有获得任何将 Twitter 身份验证与解析服务器集成的有效解决方案。我已经阅读了 github 上的几乎所有解决方案并应用了它,但没有运气。更多信息我使用了 ParseUI 项目。

https://github.com/parse-community/ParseUI-Android

我使用了 parse'com.parse:parsetwitterutils-android:1.10.6' 提供的这个库来验证用户。但没有运气。在网上搜索后,我发现有些人告诉我要在 index.js 页面上添加以下代码。

oauth: {
  twitter: {
  consumer_key: "qweREbUdsfsdfsdfsdfsd4wIg9EX", // REQUIRED
  consumer_secret: "AZrUDjnEVUsdfsdfsdfsdfsdfsdfsdfxcpxBtM0X3" // REQUIRED
  },
  facebook: {
          appIds: "8489456465"
       }
  } 

然后我得到回应:

04-27 01:53:32.340 16920-17090/app.com.parse.example D/OkHttp: {"code":1,"error":"Twitter auth configuration missing"}
<-- END HTTP (55-byte body)
04-27 01:53:47.148 16920-17113/app.com.parse.example D/OkHttp: {"authData":{"twitter":{"consumer_key":"VdzzbGHfHgFhgFHGf4wIg9EX","auth_token":"157620898-qbODfHyHJKGHGJHGJHGJHGmF38LeJ2cd","screen_name":"blackjack","consumer_secret":"AZrUwerHJGJHGJHGJHGhgjhgZwJopxBtM0X3","id":"1554545698","auth_token_secret":"PK6IgEQMrszxcjhgjhgjhjhJHGrh1Ure8IGbuPX6H"}}}
--> END POST (319-byte body)
04-27 01:53:47.239 16920-17113/app.com.parse.example D/OkHttp: {"code":1,"error":"Twitter auth configuration missing"}
<-- END HTTP (55-byte body)
04-27 01:53:47.255 16920-16920/app.com.parse.example W/ParseLoginFragment: Twitter login failed, exception: com.parse.ParseRequest$ParseRequestException: Twitter auth configuration missing

还有:

04-27 16:31:33.705 4998-4998/com.parse.loginsample.basic     W/ParseLoginFragment: Twitter login failed, exception:     com.parse.ParseRequest$ParseRequestException: i/o failure

参考答案/讨论没有解决我的问题:

https://github.com/parse-community/parse-server/issues/973

Parse server twitter authentication: Twitter auth integrated but unable to create session to use on client side

Parse server open source Android Twitter Login is not working

【问题讨论】:

    标签: android twitter parse-server


    【解决方案1】:

    oauth 选项已弃用,将在未来版本中删除,请改用 auth 选项。

    http://docs.parseplatform.org/parse-server/guide/#oauth-and-3rd-party-authentication

    查看更改日志:

    https://github.com/parse-community/parse-server/blob/master/CHANGELOG.md#230

    例子:

    auth: {
      twitter: {
      consumer_key: "qweREbUdsfsdfsdfsdfsd4wIg9EX", // REQUIRED
      consumer_secret: "AZrUDjnEVUsdfsdfsdfsdfsdfsdfsdfxcpxBtM0X3" // REQUIRED
      },
      facebook: {
          appIds: "8489456465"
       }
    } 
    

    【讨论】:

      猜你喜欢
      • 2017-12-15
      • 2015-06-01
      • 2019-12-03
      • 2021-06-27
      • 2014-01-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2018-08-03
      相关资源
      最近更新 更多