https://github.com/litetex-oss/hetzner-cloud-client
A Java client for the Hetzner Cloud API
https://github.com/litetex-oss/hetzner-cloud-client
hetzner hetzner-api hetzner-cloud java
Last synced: about 1 year ago
JSON representation
A Java client for the Hetzner Cloud API
- Host: GitHub
- URL: https://github.com/litetex-oss/hetzner-cloud-client
- Owner: litetex-oss
- License: apache-2.0
- Archived: true
- Created: 2024-03-19T23:42:09.000Z (about 2 years ago)
- Default Branch: dev
- Last Pushed: 2024-08-31T02:46:49.000Z (almost 2 years ago)
- Last Synced: 2025-03-01T11:27:33.935Z (over 1 year ago)
- Topics: hetzner, hetzner-api, hetzner-cloud, java
- Language: Java
- Homepage:
- Size: 499 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 12
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Security: SECURITY.md
Awesome Lists containing this project
README
[](https://mvnrepository.com/artifact/net.litetex/hetzner-cloud-client)
[](https://github.com/litetex-oss/hetzner-cloud-client/actions/workflows/checkBuild.yml?query=branch%3Adev)
[](https://sonarcloud.io/dashboard?id=litetex-oss_hetzner-cloud-client)
# hetzner-cloud-client
A Java client for the [Hetzner Cloud API](https://docs.hetzner.cloud/)
## Usage
Example: Create a firewall and a server
```java
HetznerCloudAPI api = new HetznerCloudAPI("API-TOKEN");
Firewall firewall = api.firewalls().create(b -> b
.name("allow-icmp-from-everywhere")
.firewallRule(r -> r
.direction(FirewallRule.Direction.IN)
.protocol(FirewallRule.Protocol.ICMP)
.sourceIP("0.0.0.0/0")
.sourceIP("::/0")))
.firewall();
Server server = api.servers().create(b -> b
.name("my-server")
.startAfterCreate(false)
.serverType("cax11")
.image("...")
.datacenter("...")
.firewall(firewall.id()))
.server();
```
## Installation
[Installation guide for the latest release](https://github.com/litetex-oss/hetzner-cloud-client/releases/latest#Installation)
## Contributing
See the [contributing guide](./CONTRIBUTING.md) for detailed instructions on how to get started with our project.
## Dependencies and Licenses
View the [license of the current project](LICENSE) or the [summary including all dependencies](https://litetex-oss.github.io/hetzner-cloud-client/dependencies)