Java-client for the XenforoResourceManagerAPI from SpigotMC.org https://github.com/SpigotMC/XenforoResourceManagerAPI
Issues and pull requests are welcome!
To use this project in your Maven-based project, add the following dependency:
<dependency>
<groupId>de.jonahd345</groupId>
<artifactId>xenfororesourcemanagerapi</artifactId>
<version>1.1.1</version>
</dependency>
XenforoResourceManagerAPI api = new XenforoResourceManagerAPI();
// get Resource (with id)
Resource resource = api.getResource(106888);
if (resource != null) {
List<Update> updatesOfResource = api.getResourceUpdates(resource.getId());
}
// get Author async (in this way available for all endpoints)
CompletableFuture<Author> futureAuthor = api.getAuthorAsync(1407849);
futureAuthor.thenAccept(author -> {
if (author != null) {
System.out.println("Author: " + author.getUsername());
} else {
System.out.println("Author not found.");
}
});
coded with ❤️ by JonaHD345