Trello OAuth令牌到期

Sco*_*t M 5 oauth trello

我们的服务具有Trello集成,我们使用OAuth对用户进行身份验证和授权.但是,在服务重新验证用户之前,我们看到所有对Trello的调用都会失败.首先打电话给https://api.trello.com/1/lists发帖,收到401回复.获取新令牌(通过有效重新验证)解决了问题,因此它不是权限问题.

这个问题最初听起来像一个令牌过期问题(因为expiration=never显然是支持的),但它在过去没有发生,我们已经使用Trello的API超过一年.有没有人碰巧知道Trello的默认OAuth令牌到期以及最近是否有变化?

谢谢!

小智 0

如果请求中未提供过期时间,则 OAuth1.0 流的默认值为30days

401用户从其帐户页面撤销 Trello 令牌也可能导致此问题: https: //trello.com/my/account

1/tokens此外,您可以通过以下路径检查令牌的到期日期:https://trello.com/1/tokens/ {tokenValue}?key={TrelloAPIKey}&token={tokenValue}。

该路由的响应示例如下所示: { "id": "a58541ff795dc3d9a124374b", "identifier": "My Trello Token", "idMember": "5859bd30f6582fbf01f4a8fc", "dateCreated": "2016-12-16T16:45:06.810Z", "dateExpires": null, "permissions": [ { "idModel": "69bdfbf01f58582530f4a8fc", "modelType": "Member", "read": true, "write": true }, { "idModel": "*", "modelType": "Board", "read": true, "write": true }, { "idModel": "*", "modelType": "Organization", "read": true, "write": true } ] }