使用github API搜索结果

时间:2017-09-13 23:55:03

标签: github github-api

我使用以下查询: https://api.github.com/search/repositories?q=mysql&created:%3C2009-04-11&order=asc

并看到与以下相同的结果: https://api.github.com/search/repositories?q=mysql&created:%3E=2013-04-11&order=asc

看起来创建没有生效。 如果我在查询中遗漏任何内容,你能帮我吗?

1 个答案:

答案 0 :(得分:1)

document of REST API v3,使用+添加参数。那么下面的修改呢?

来自:

https://api.github.com/search/repositories?q=mysql&created:<2009-04-11&order=asc
https://api.github.com/search/repositories?q=mysql&created:>=2013-04-11&order=asc

致:

https://api.github.com/search/repositories?q=mysql+created:<2009-04-11&order=asc
https://api.github.com/search/repositories?q=mysql+created:>=2013-04-11&order=asc

如果我误解了你的问题,我很抱歉。

编辑:

如果要使用curl检索数据,请使用以下方法。在这种情况下,请使用双引号将URL括起来。此示例中的URL来自您的评论。

curl "https://api.github.com/search/repositories?q=python+created:%3E2009-04-11&page=1"

curl "https://api.github.com/search/repositories?q=python+created:>2009-04-11&page=1"
相关问题