我正在寻找一种方法,用AJAX简单搜索科学论文的引用。 Google学术搜索没有API(根据他们的使用条款判断,不会有任何API),CiteSeerX支持OAI-PMH API。是否有人知道JavaScript / jQuery实现允许我进行异步查询并获得顶级项目列表?例如。搜索knuth
应该产生类似
{
{
author: 'Knuth, DE',
title: 'The art of computer programming. Vol. 3: sorting and searching',
year: '1973',
publisher: 'Addison Wesley'
},
{
author: 'Graham, RL and Knuth, DE and Patashnik, O',
title: 'Concrete mathematics: a foundation for computer science',
year='1994',
publisher='Addison-Wesley Reading, MA'
},
// ...
}
或掌握OAI Api并知道如何将其包装成有效查询的任何人?
答案 0 :(得分:2)
<强> [UPDATE] 强> 我已经将Mendeley搜索JSONP代理的示例推送到GitHub ...请参阅https://github.com/nisc/node-mendeley-search-jsonp-proxy 的 [/ UPDATE] 强>
我没有时间查看OAI-PMH API是什么以及为什么无法使用简单的$ .getJSON()查询它,但您可能还想查看{{3 (也许他们甚至可以实现OAI-PMH,谁知道)。
特别是,Mendeley API可能很有趣。
只需document search(点击一下)。然后尝试类似的事情:
# I think curl does the percent-encoding automatically. You might
# want to replace "authors:knuth" with "authors%3Aknuth", though.
curl "http://api.mendeley.com/oapi/documents/search/authors:knuth/?consumer_key=$YOUR_KEY"
我不确定您是否应该将您的使用者密钥公开给客户端应用程序(更好地检查他们的文档)。但是,您始终可以构建一个非常简单的API代理( UPDATE :考虑相同的原始策略,您可能必须这样做,因为它们似乎不支持JSONP或CORS)。
我不知道他们的使用限制。 更新: register an application。
答案 1 :(得分:0)
在OAI-PMH中,a minimal implementation不包含任何其他类型的查询,而不是所需的时间段。
因此,它取决于您想要使用的OAI-PMH存储库,可能实现的不仅仅是这个最小的实现。