https://github.com/nichtstudiocode/gofile4j
A java wrapper for the GoFile.io API
https://github.com/nichtstudiocode/gofile4j
file gofile java upload upload-file upload-images upload-pictures upload-videos wrapper
Last synced: 8 months ago
JSON representation
A java wrapper for the GoFile.io API
- Host: GitHub
- URL: https://github.com/nichtstudiocode/gofile4j
- Owner: NichtStudioCode
- License: mit
- Archived: true
- Created: 2020-06-27T15:43:45.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-05-20T21:49:05.000Z (over 3 years ago)
- Last Synced: 2025-01-01T13:43:45.071Z (9 months ago)
- Topics: file, gofile, java, upload, upload-file, upload-images, upload-pictures, upload-videos, wrapper
- Language: Java
- Homepage:
- Size: 22.5 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# GoFile4j
[](https://app.codacy.com/manual/NichtStudioCode/GoFile4j?utm_source=github.com&utm_medium=referral&utm_content=NichtStudioCode/GoFile4j&utm_campaign=Badge_Grade_Settings)
A java wrapper for the API
## Uploading files
Create a new instance of GoFile4j and provide the Files you want to upload
```java
GoFile4j goFile4j = new GoFile4j(file, file1);
```
optional: set these values
```java
goFile4j.setEmail("email@domain.com"); // The email of the account the upload should be associated with (= manage uploads)
goFile4j.setDescription("description"); // The description shown on the download page
goFile4j.setPassword("password"); // The password used to access the download page
goFile4j.setTags("tag1,tag2,tag3"); // The tags
```
Upload the files
```java
goFile4j.upload();
```## Use the FileUploadResult
The upload method returns a FileUploadResult, here is how you use it:The two codes ```getCode()``` and ```getRemovalCode()``` return the values from the API.
```getDownloadLink()``` provides a link to the main download page.
```getDirectDownloadLinks()``` returns an array of direct download links. **These links will not work if the main download page hasn't been visited before.**