我仍然相对较新的Twitter开发。所以这可能是一个愚蠢的问题。 我正在查看一个Twitter API库,它们在资源文件中定义了速率限制
<data name="QueryRateLimit" xml:space="preserve">
<value>https://api.twitter.com/1.1/application/rate_limit_status.json</value>
https://api.twitter.com/1.1/application/rate_limit_status.json究竟做了什么以及它在应用程序中使用了什么?
因为如果您只是打开浏览器并复制并通过此链接,就会出现预期的身份验证错误。但是,如果您的请求已通过身份验证,这是否意味着json将返回一组某些值映射到会话的速率限制?
非常感谢所有提示和帮助。
由于
什么
答案 0 :(得分:0)
根据documentation,你会得到这样的结论:
{
"rate_limit_context": {
"access_token": "119476949-oYGCs2M5duG5QalbOAK2YUZh8zG3ur7DPYo5qIFN"
},
"resources": {
"help": {
"/help/privacy": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/help/configuration": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/help/tos": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/help/languages": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
}
},
"statuses": {
"/statuses/oembed": {
"remaining": 180,
"reset": 1346439527,
"limit": 180
},
"/statuses/user_timeline": {
"remaining": 180,
"reset": 1346439527,
"limit": 180
},
"/statuses/mentions_timeline": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/statuses/home_timeline": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/statuses/show/:id": {
"remaining": 180,
"reset": 1346439527,
"limit": 180
},
"/statuses/retweets/:id": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
}
},
"users": {
"/users/show": {
"remaining": 180,
"reset": 1346439527,
"limit": 180
},
"/users/search": {
"remaining": 180,
"reset": 1346439527,
"limit": 180
},
"/users/suggestions": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/users/contributors": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/users/suggestions/:slug/members": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/users/suggestions/:slug": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/users/contributees": {
"remaining": 15,
"reset": 1346439527,
"limit": 15
},
"/users/lookup": {
"remaining": 180,
"reset": 1346439527,
"limit": 180
}
},
"search": {
"/search/tweets": {
"remaining": 180,
"reset": 1346439527,
"limit": 180
}
}
}
}