I am going nuts figuring this out , going through tons of google/stackflow/blogs pages but have not found clear answer.
I would like to programatically download repository in ZIP format using Curl and my personal github token.
$token -> my personal token
$org -> my organization as a owner of repositories
$repo -> private repository I would like to download
I am trying to use something like this:
curl -H “Authorization: $token” -L https://api.github.com/repos/$org/$repo/zipball > repo.zip
but it produces following json:
“message”: “Not Found”,
Please help !!