0

I want to get the list of all repositories in GitHub with pagination and I want to set items per page to for example 50.
for that, I use this

https://api.github.com/repositories?page=1&per_page=50

but it doesn't work and always I get 369 items per page

what I'm missing?

max
  • 5,963
  • 12
  • 49
  • 80

1 Answers1

0

The GitHub API docs give this answer:

Note: Pagination is powered exclusively by the since parameter. Use the Link header to get the URL for the next page of repositories.

For pagination your url could like like: https://api.github.com/repositories?since=19991704

J.Gerbershagen
  • 316
  • 1
  • 3