I am trying to find a way to download all the issues from a GitHub repository to have a local backup. I found this tool that can download issues as both JSON and HTML files. It works fine for public repos, but for private repos the HTML pull fails (this is a known issue and the developer said they don't intend to address it).
I've been trying to find a workaround myself and keep hitting walls. The basic HTML pull for a public repo works fine:
curl -L ";
When going to a private repo, I can pull the JSON for issues using the API:
curl -L \
-H "Accept: application/vnd.github.html+json" \
-H "Authorization: Bearer $token" \
-H "X-GitHub-Api-Version: 2022-11-28" \
> issues.json
so I know my authorization token is valid. However, when I try to combine these to get the HTML version of the issues, all I get is a 404 Not Found Error:
curl -L \
-H "Authorization: Bearer $token" \
> issue4.html
I've tried including other header info like the API version, the Authorized user, the format (using the "Accept" header), using "token" instead of "Bearer", and nothing seems able to get past the 404. I assume it's some sort of authorization error, but I can't figure out how to solve it. Anyone have suggestions/solutions?