Github API按created_at字段对搜索结果进行排序

如何创建按created_at字段排序的搜索查询?我试过了:

https://api.github.com/search/repositories?q=blog&sort=created_at&order=desc

https://api.github.com/search/repositories?q=blog&sort=created&order=desc

但是我得到与此查询相同的结果:

https://api.github.com/search/repositories?q=blog

最佳答案 排序参数
only takes one of three values:星号,分叉或更新:

The sort field. One of stars, forks, or updated. Default: results are sorted by best match.

似乎无法按创建日期排序,但您可以将搜索查询的响应读入数组并从那里排序.

点赞