GET/repos/{owner}/{repo}/zipball/{ref}

Download a repository ZIP archive

Downloads a ZIP archive of a repository at the specified revision. Use ref to select a branch, tag, or commit; if omitted, the repository’s default branch is used. Follow the redirect or use its Location header to make a second GET request; download links for private repositories expire after five minutes.

3 parameters
ownerstringrequired
The account that owns the repository; the name is not case-sensitive.
repostringrequired
The repository name without the `.git` extension; the name is not case-sensitive.
refstringrequired
The branch, tag, or commit to archive. Defaults to the repository’s default branch when omitted.

1 status code
302Redirects to a URL for downloading the repository ZIP archive. Follow the redirect or use the `Location` header to make a second GET request.

Error handling

Use the owner path parameter and repo path parameter to identify the repository, and the ref path parameter to select the revision. If you omit ref, the repository’s default branch is used; links for private repositories expire after five minutes.