Java HTTP client for the Cloudinfo API, providing cloud provider information including regions and compute products with pricing.
Add the dependency to your build.gradle:
dependencies {
implementation 'io.seqera:lib-cloudinfo:1.1.2'
}Note: Check the project's VERSION file for the current version number.
- Fetch cloud regions for AWS, GCP, and Azure
- Fetch compute products (instance types) with on-demand and spot pricing
- Built on
lib-httpxwith automatic retry and error handling - Type-safe JSON deserialization using
lib-serde-jackson
// Create client with default configuration
CloudInfoClient client = CloudInfoClient.create();
// Fetch regions for a cloud provider
List<CloudRegion> regions = client.getRegions("amazon");
List<String> regionIds = client.getRegionIds("amazon");
// Fetch compute products with pricing
List<CloudProduct> products = client.getProducts("amazon", "us-east-1");Pass a ProductsQuery to restrict the products endpoint to instance families
with Scheduler support (sched=true) or NVMe local storage (nvme=true).
Filters are applied server-side and can be combined; providers without filter
config entries return all products unfiltered.
ProductsQuery query = ProductsQuery.builder()
.sched(true)
.nvme(true)
.build();
List<CloudProduct> products = client.getProducts("amazon", "us-east-1", query);CloudInfoClient client = CloudInfoClient.builder()
.endpoint("https://cloudinfo.seqera.io")
.connectTimeout(Duration.ofSeconds(30))
.maxRetries(5)
.build();| Provider | ID |
|---|---|
| AWS | amazon |
| GCP | google |
| Azure | azure |
| Class | Description |
|---|---|
CloudRegion |
Region identifier and name |
CloudProduct |
Compute instance type with CPU, memory, GPU, pricing, and per-product capability features (SCHED, NVME, GPU, family-type, etc.) |
CloudPrice |
Spot price for a specific zone |
CloudResponse |
API response wrapper containing products |
ProductAttributes |
Additional product attributes |
ProductsQuery |
Optional filters (sched, nvme) for the products endpoint |
lib-httpx: HTTP client with retry supportlib-serde-jackson: JSON serialization/deserialization