Help
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Ground Controller Lvl 1
Message 1 of 2

Download file from github using Java

I wanted to download files from github using java code and not visiting github page. Want to dowonload subdirectory or subfolder from github by directly hitting url provided for download.
1 Reply
Highlighted
Commander Lvl 1
Message 2 of 2

Re: Download file from github using Java

Hey! You will want to use: https://docs.oracle.com/javase/6/docs/api/java/net/URL.html in order to make a request. 

 

If the content is Base64 encoded, you can use: https://developer.github.com/v3/repos/contents/

 

Otherwise, you may need to use: https://developer.github.com/v3/repos/releases/#get-a-single-release-asset to get the assets from the release. 

 

You may also want to check out: https://github-api.kohsuke.org