CiteULike API“禁止”

2024-09-24 16:33:47 发布

您现在位置:Python中文网/ 问答频道 /正文

我试图查询类似城市的研究论文的书签数量。我使用“http://www.citeulike.org/api/posts/for/doi/”URL来请求一个包含给定DOI(论文的唯一标识符)书签信息的XML文档的请求(为Python使用urllib2库)。但是我一直收到一个http403错误:Forbbiden。在

有人知道我为什么会犯这个错误吗?我尝试过将URL和DOI放在浏览器中,这样就可以很好地返回XML,所以问题似乎与我的自动请求有关。在

谢谢, 纳撒尼尔


Tags: orgapihttpurlfor数量www错误
1条回答
网友
1楼 · 发布于 2024-09-24 16:33:47

你应该读http://wiki.citeulike.org/index.php/Importing_and_Exporting#Scripting_CiteULike

If you access CiteULike via an automated process, you MUST provide a means to identify yourself via the User-Agent string. Please use "<username>/<email> <application>" e.g., "fred/fred@wilma.com myscraper/1.0". Any scripting of the site without a means to identify you may result in a block.

相关问题 更多 >