Fetch all releases via API, response pagination? #24376
Answered
by
cmdcolin
cmdcolin
asked this question in
API and Webhooks
-
The “List releases” API it seems to suggest that a response includes a “Link” header containing next page and last page Is this not available? curl -i https://api.github.com/repos/myorg/myrepo/releases -v > /dev/null
This does not have any link and the body of the json doesn’t appear to have it either |
Beta Was this translation helpful? Give feedback.
Answered by
cmdcolin
Sep 21, 2020
Replies: 1 comment
-
In case it is helpful, I loop from https://api.github.com/repos/myorg/myrepo/releases?page=N Until I get an empty JSON response I use this instead of trying to parse the response HTTP Link header |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
In case it is helpful, I loop from
https://api.github.com/repos/myorg/myrepo/releases?page=N
Until I get an empty JSON response
I use this instead of trying to parse the response HTTP Link header