gpt4 book ai didi

rebol - 为什么 rebol 使用 stackoverflow api 失败?

转载 作者:行者123 更新时间:2023-12-02 08:58:12 27 4
gpt4 key购买 nike

如果我在浏览器中输入(请参阅 https://stackapps.com/questions/2/getting-started-with-the-api ):

http://api.stackoverflow.com/1.0/stats

返回

{
"statistics": [
{
"total_questions": 800830,
"total_unanswered": 131356,
"total_accepted": 500653,
"total_answers": 2158752,
"total_comments": 3125048,
"total_votes": 7601765,
"total_badges": 798091,
"total_users": 289282,
"questions_per_minute": 1.50,
"answers_per_minute": 3.12,
"badges_per_minute": 1.20,
"views_per_day": 455215.44,
"api_version": {
"version": "1.0",
"revision": "2010.7.17.1"
},
"site": {
"name": "Stack Overflow",
"logo_url": "http://sstatic.net/stackoverflow/img/logo.png",
"api_endpoint": "http://api.stackoverflow.com",
"site_url": "http://stackoverflow.com",
"description": "Q&A for professional and enthusiast programmers",
"icon_url": "http://sstatic.net/stackoverflow/apple-touch-icon.png",
"state": "normal",
"styling": {
"link_color": "#0077CC",
"tag_foreground_color": "#3E6D8E",
"tag_background_color": "#E0EAF1"
}
}
}
]
}

如果我在 rebol 控制台中输入以下内容:

read http://api.stackoverflow.com/1.0/stats

它返回一些奇怪的二进制字符。

最佳答案

probe load to-string gunzip to-string read/binary http://api.stackoverflow.com/1.0/stats
connecting to: api.stackoverflow.com
{
"statistics": [
{
"total_questions": 801559,
"total_unanswered": 131473,
"total_accepted": 501129,
"total_answers": 2160171,
"total_comments": 3127759,
"total_votes": 7607247,
"total_badges": 798608,
"total_users": 289555,
"questions_per_minute": 0.93,
"answers_per_minute": 1.83,
"badges_per_minute": 0.73,
"views_per_day": 455579.60,
"api_version": {
"version": "1.0",
"revision": "2010.7.17.2"
},
"site": {
"name": "Stack Overflow",
"logo_url": "http://sstatic.net/stackoverflow/img/logo.png",
"api_endpoint": "http://api.stackoverflow.com",
"site_url": "http://stackoverflow.com",
"description": "Q&A for professional and enthusiast programmers",
"icon_url": "http://sstatic.net/stackoverflow/apple-touch-icon.png",
"state": "normal",
"styling": {
"link_color": "#0077CC",
"tag_foreground_color": "#3E6D8E",
"tag_background_color": "#E0EAF1"
}
}
}
]
}

关于rebol - 为什么 rebol 使用 stackoverflow api 失败?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3271302/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com