Echchama Nayak
Echchama Nayak

Reputation: 933

Github search by created

I am using the following link to search using curl. My intention is to get results which are sorted by creation.

My sample query is as follows:

curl 'https://api.github.com/search/repositories?q=arrow&sort=created' > results.txt

When I search the 'results.txt', I get results which are not ordered by creation dates.

Upvotes: 1

Views: 132

Answers (2)

VonC
VonC

Reputation: 1326932

created is not a sort order, but a search qualifier, a filter.

You would use it as part of the q parameter:

cats created:>=2012-04-30

https://github.com/search?utf8=%E2%9C%93&q=cats+created%3A%3E%3D2012-04-30&type=Issues

The sort order only involve stars, forks, or updated.
Not creation date.

Upvotes: 2

René Höhle
René Höhle

Reputation: 27305

When you take a look at the documentation you can see that sort specified options like stars, forks and updated

https://developer.github.com/v3/search/

To get the created you have to define them in your filter then its an defined word in the filter. You can see that in the documentation.

Upvotes: 0

Related Questions