I am trying to programmatically download a zip file of a repository which is already checked out to a specific branch. For that I need to obtain the zipballUrl of the head of the branch I specify through github graphQL API.
This answer specifies how to get the zipballUrl of the default branch but I could not alter it to my requirement. Appreciate if someone can help out.
PS: Running a git clone command and checking out to branch is not an option because the programming language I use (ballerina) does not support shell commands yet.