This is client library for Hetzner cloud, based on Retrofit HTTP client.
Declare dependency in pom.xml
<dependency>
<groupId>cloud.dnation.integration</groupId>
<artifactId>hetzner-cloud-client-java</artifactId>
<version>1.3.0</version>
</dependency>
Instantiate client and make an API call
import cloud.dnation.hetznerclient.*;
HetznerApi api = ClientFactory.create("my-token-123456");
Response<GetServerByIdResponse> response = api.getServer(123456).execute();
if (response.isSuccessful()) {
System.out.println(response.body());
}