diff --git a/services/iaas/README.md b/services/iaas/README.md index 2c1410b..04411de 100644 --- a/services/iaas/README.md +++ b/services/iaas/README.md @@ -1,6 +1,6 @@ # STACKIT Java SDK for IaaS-API -- API version: 1 +- API version: 2beta1 This API allows you to create and modify IaaS resources. diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiCallback.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiCallback.java index 8d6639f..ab58dd8 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiCallback.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiCallback.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiClient.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiClient.java index 0e95c89..ac90c53 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiClient.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiClient.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -52,12 +52,12 @@ /** ApiClient class. */ public class ApiClient { - protected String basePath = "https://iaas.api.eu01.stackit.cloud"; + protected String basePath = "https://iaas.api.stackit.cloud"; protected List servers = new ArrayList( Arrays.asList( new ServerConfiguration( - "https://iaas.api.{region}stackit.cloud", + "https://iaas.api.stackit.cloud", "No description provided", new HashMap() { { @@ -65,9 +65,8 @@ public class ApiClient { "region", new ServerVariable( "No description provided", - "eu01.", - new HashSet( - Arrays.asList("eu01.")))); + "global", + new HashSet())); } }))); protected Integer serverIndex = 0; @@ -162,7 +161,7 @@ public String getBasePath() { /** * Set base path * - * @param basePath Base path of the URL (e.g https://iaas.api.eu01.stackit.cloud + * @param basePath Base path of the URL (e.g https://iaas.api.stackit.cloud * @return An instance of OkHttpClient */ public ApiClient setBasePath(String basePath) { diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiResponse.java index 9da9eeb..49821a6 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ApiResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/GzipRequestInterceptor.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/GzipRequestInterceptor.java index cb12462..c49716a 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/GzipRequestInterceptor.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/GzipRequestInterceptor.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/JSON.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/JSON.java index 210e683..58729c5 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/JSON.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/JSON.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -21,6 +21,7 @@ import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import io.gsonfire.GsonFireBuilder; +import io.gsonfire.TypeSelector; import java.io.IOException; import java.io.InputStream; import java.io.InputStreamReader; @@ -34,6 +35,7 @@ import java.time.OffsetDateTime; import java.time.format.DateTimeFormatter; import java.util.Date; +import java.util.HashMap; import java.util.Map; import okio.ByteString; @@ -55,7 +57,110 @@ public class JSON { @SuppressWarnings("unchecked") public static GsonBuilder createGson() { - GsonFireBuilder fireBuilder = new GsonFireBuilder(); + GsonFireBuilder fireBuilder = + new GsonFireBuilder() + .registerTypeSelector( + cloud.stackit.sdk.iaas.model.ManagementRouteDestination.class, + new TypeSelector< + cloud.stackit.sdk.iaas.model.ManagementRouteDestination>() { + @Override + public Class< + ? extends + cloud.stackit.sdk.iaas.model + .ManagementRouteDestination> + getClassForElement(JsonElement readElement) { + Map classByDiscriminatorValue = + new HashMap(); + classByDiscriminatorValue.put( + "ManagementRoute_destination", + cloud.stackit.sdk.iaas.model + .ManagementRouteDestination.class); + return getClassByDiscriminator( + classByDiscriminatorValue, + getDiscriminatorValue(readElement, "type")); + } + }) + .registerTypeSelector( + cloud.stackit.sdk.iaas.model.ManagementRouteNexthop.class, + new TypeSelector< + cloud.stackit.sdk.iaas.model.ManagementRouteNexthop>() { + @Override + public Class< + ? extends + cloud.stackit.sdk.iaas.model + .ManagementRouteNexthop> + getClassForElement(JsonElement readElement) { + Map classByDiscriminatorValue = + new HashMap(); + classByDiscriminatorValue.put( + "ManagementRoute_nexthop", + cloud.stackit.sdk.iaas.model.ManagementRouteNexthop + .class); + return getClassByDiscriminator( + classByDiscriminatorValue, + getDiscriminatorValue(readElement, "type")); + } + }) + .registerTypeSelector( + cloud.stackit.sdk.iaas.model.RouteDestination.class, + new TypeSelector() { + @Override + public Class< + ? extends + cloud.stackit.sdk.iaas.model + .RouteDestination> + getClassForElement(JsonElement readElement) { + Map classByDiscriminatorValue = + new HashMap(); + classByDiscriminatorValue.put( + "cidrv4", + cloud.stackit.sdk.iaas.model.DestinationCIDRv4 + .class); + classByDiscriminatorValue.put( + "cidrv6", + cloud.stackit.sdk.iaas.model.DestinationCIDRv6 + .class); + classByDiscriminatorValue.put( + "Route_destination", + cloud.stackit.sdk.iaas.model.RouteDestination + .class); + return getClassByDiscriminator( + classByDiscriminatorValue, + getDiscriminatorValue(readElement, "type")); + } + }) + .registerTypeSelector( + cloud.stackit.sdk.iaas.model.RouteNexthop.class, + new TypeSelector() { + @Override + public Class< + ? extends + cloud.stackit.sdk.iaas.model + .RouteNexthop> + getClassForElement(JsonElement readElement) { + Map classByDiscriminatorValue = + new HashMap(); + classByDiscriminatorValue.put( + "blackhole", + cloud.stackit.sdk.iaas.model.NexthopBlackhole + .class); + classByDiscriminatorValue.put( + "internet", + cloud.stackit.sdk.iaas.model.NexthopInternet.class); + classByDiscriminatorValue.put( + "ipv4", + cloud.stackit.sdk.iaas.model.NexthopIPv4.class); + classByDiscriminatorValue.put( + "ipv6", + cloud.stackit.sdk.iaas.model.NexthopIPv6.class); + classByDiscriminatorValue.put( + "Route_nexthop", + cloud.stackit.sdk.iaas.model.RouteNexthop.class); + return getClassByDiscriminator( + classByDiscriminatorValue, + getDiscriminatorValue(readElement, "type")); + } + }); GsonBuilder builder = fireBuilder.createGsonBuilder(); return builder; } @@ -95,6 +200,12 @@ private static Class getClassByDiscriminator( gsonBuilder.registerTypeAdapter(OffsetDateTime.class, offsetDateTimeTypeAdapter); gsonBuilder.registerTypeAdapter(LocalDate.class, localDateTypeAdapter); gsonBuilder.registerTypeAdapter(byte[].class, byteArrayAdapter); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.AddRoutesToRoutingTablePayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.AddRoutingTableToAreaPayload + .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.AddVolumeToServerPayload .CustomTypeAdapterFactory()); @@ -105,14 +216,8 @@ private static Class getClassByDiscriminator( .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.AllowedAddressesInner.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.Area.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.AreaConfig.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.AreaId.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.AreaPrefixConfigIPv4.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.AvailabilityZoneListResponse .CustomTypeAdapterFactory()); @@ -131,11 +236,6 @@ private static Class getClassByDiscriminator( gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.CreateAffinityGroupPayload .CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.CreateAreaAddressFamily - .CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.CreateAreaIPv4.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.CreateBackupPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -143,7 +243,10 @@ private static Class getClassByDiscriminator( gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.CreateKeyPairPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.CreateNetworkAddressFamily + new cloud.stackit.sdk.iaas.model.CreateManagementNetworkPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.CreateManagementNetworkRoutePayload .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.CreateNetworkAreaPayload @@ -155,9 +258,21 @@ private static Class getClassByDiscriminator( new cloud.stackit.sdk.iaas.model.CreateNetworkAreaRoutePayload .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.CreateNetworkIPv4Body.CustomTypeAdapterFactory()); + new cloud.stackit.sdk.iaas.model.CreateNetworkIPv4.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.CreateNetworkIPv4WithPrefix + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.CreateNetworkIPv4WithPrefixLength + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.CreateNetworkIPv6.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.CreateNetworkIPv6WithPrefix + .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.CreateNetworkIPv6Body.CustomTypeAdapterFactory()); + new cloud.stackit.sdk.iaas.model.CreateNetworkIPv6WithPrefixLength + .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.CreateNetworkPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -183,12 +298,14 @@ private static Class getClassByDiscriminator( gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.CreateServerPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.CreateServerPayloadNetworking + new cloud.stackit.sdk.iaas.model.CreateServerPayloadAllOfNetworking .CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.CreateSnapshotPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.CreateVolumePayload.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.DestinationCIDRv4.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.DestinationCIDRv6.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.Error.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -221,6 +338,16 @@ private static Class getClassByDiscriminator( gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.MachineTypeListResponse .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.ManagementRoute.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.ManagementRouteDestination + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.ManagementRouteListResponse + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.ManagementRouteNexthop.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.NIC.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -229,11 +356,13 @@ private static Class getClassByDiscriminator( new cloud.stackit.sdk.iaas.model.Network.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.NetworkArea.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.NetworkAreaIPv4.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.NetworkAreaListResponse .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.NetworkIPv4.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.NetworkIPv6.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.NetworkListResponse.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -241,6 +370,14 @@ private static Class getClassByDiscriminator( gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.NetworkRangeListResponse .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.NexthopBlackhole.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.NexthopIPv4.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.NexthopIPv6.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.NexthopInternet.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.PartialUpdateNetworkAreaPayload .CustomTypeAdapterFactory()); @@ -270,6 +407,13 @@ private static Class getClassByDiscriminator( new cloud.stackit.sdk.iaas.model.QuotaList.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.QuotaListResponse.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.RegionalArea.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.RegionalAreaIPv4.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.RegionalAreaListResponse + .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.Request.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -282,8 +426,17 @@ private static Class getClassByDiscriminator( new cloud.stackit.sdk.iaas.model.ResizeVolumePayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.Route.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.RouteDestination.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.RouteListResponse.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.RouteNexthop.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.RoutingTable.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.RoutingTableListResponse + .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.SecurityGroup.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -299,6 +452,8 @@ private static Class getClassByDiscriminator( .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.Server.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.ServerAgent.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.ServerConsoleUrl.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -307,6 +462,8 @@ private static Class getClassByDiscriminator( new cloud.stackit.sdk.iaas.model.ServerMaintenance.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.ServerNetwork.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.ServerNetworking.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.ServiceAccountMailListResponse .CustomTypeAdapterFactory()); @@ -316,16 +473,9 @@ private static Class getClassByDiscriminator( new cloud.stackit.sdk.iaas.model.Snapshot.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.SnapshotListResponse.CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.UpdateAreaAddressFamily - .CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.UpdateAreaIPv4.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.UpdateAttachedVolumePayload .CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.UpdateBackupPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.UpdateImagePayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( @@ -334,10 +484,7 @@ private static Class getClassByDiscriminator( gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.UpdateKeyPairPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.UpdateNetworkAddressFamily - .CustomTypeAdapterFactory()); - gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.UpdateNetworkAreaRoutePayload + new cloud.stackit.sdk.iaas.model.UpdateManagementNetworkRoutePayload .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.UpdateNetworkIPv4Body.CustomTypeAdapterFactory()); @@ -348,14 +495,38 @@ private static Class getClassByDiscriminator( gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.UpdatePublicIPPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.UpdateSecurityGroupPayload + new cloud.stackit.sdk.iaas.model.UpdateRegionalAreaIPv4.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.UpdateRouteOfRoutingTablePayload .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.UpdateServerPayload.CustomTypeAdapterFactory()); + new cloud.stackit.sdk.iaas.model.UpdateRoutingTableOfAreaPayload + .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( - new cloud.stackit.sdk.iaas.model.UpdateSnapshotPayload.CustomTypeAdapterFactory()); + new cloud.stackit.sdk.iaas.model.UpdateServerPayload.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.UpdateVolumePayload.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2beta1ConfigureNetworkAreaRegionPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2beta1CreateSnapshotPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2beta1UpdateBackupPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2beta1UpdateNetworkAreaRegionPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2beta1UpdateRouteOfAreaPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2beta1UpdateSecurityGroupPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2beta1UpdateSnapshotPayload + .CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( new cloud.stackit.sdk.iaas.model.Volume.CustomTypeAdapterFactory()); gsonBuilder.registerTypeAdapterFactory( diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/Pair.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/Pair.java index 25a73fd..cd2c118 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/Pair.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/Pair.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ProgressRequestBody.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ProgressRequestBody.java index 0817b86..4885b11 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ProgressRequestBody.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ProgressRequestBody.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ProgressResponseBody.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ProgressResponseBody.java index 5a41d02..9c0f277 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ProgressResponseBody.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ProgressResponseBody.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ServerConfiguration.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ServerConfiguration.java index 37083c1..5943cce 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ServerConfiguration.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ServerConfiguration.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ServerVariable.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ServerVariable.java index b3e35f0..e7089a5 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ServerVariable.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/ServerVariable.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/StringUtil.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/StringUtil.java index 8509051..c17ef6b 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/StringUtil.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/StringUtil.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/api/DefaultApi.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/api/DefaultApi.java index 9ad35e5..ff0952c 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/api/DefaultApi.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/api/DefaultApi.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -18,6 +18,8 @@ import cloud.stackit.sdk.iaas.ApiClient; import cloud.stackit.sdk.iaas.ApiResponse; import cloud.stackit.sdk.iaas.Pair; +import cloud.stackit.sdk.iaas.model.AddRoutesToRoutingTablePayload; +import cloud.stackit.sdk.iaas.model.AddRoutingTableToAreaPayload; import cloud.stackit.sdk.iaas.model.AddVolumeToServerPayload; import cloud.stackit.sdk.iaas.model.AffinityGroup; import cloud.stackit.sdk.iaas.model.AffinityGroupListResponse; @@ -28,6 +30,8 @@ import cloud.stackit.sdk.iaas.model.CreateBackupPayload; import cloud.stackit.sdk.iaas.model.CreateImagePayload; import cloud.stackit.sdk.iaas.model.CreateKeyPairPayload; +import cloud.stackit.sdk.iaas.model.CreateManagementNetworkPayload; +import cloud.stackit.sdk.iaas.model.CreateManagementNetworkRoutePayload; import cloud.stackit.sdk.iaas.model.CreateNetworkAreaPayload; import cloud.stackit.sdk.iaas.model.CreateNetworkAreaRangePayload; import cloud.stackit.sdk.iaas.model.CreateNetworkAreaRoutePayload; @@ -37,7 +41,6 @@ import cloud.stackit.sdk.iaas.model.CreateSecurityGroupPayload; import cloud.stackit.sdk.iaas.model.CreateSecurityGroupRulePayload; import cloud.stackit.sdk.iaas.model.CreateServerPayload; -import cloud.stackit.sdk.iaas.model.CreateSnapshotPayload; import cloud.stackit.sdk.iaas.model.CreateVolumePayload; import cloud.stackit.sdk.iaas.model.GetServerLog200Response; import cloud.stackit.sdk.iaas.model.Image; @@ -49,6 +52,8 @@ import cloud.stackit.sdk.iaas.model.Keypair; import cloud.stackit.sdk.iaas.model.MachineType; import cloud.stackit.sdk.iaas.model.MachineTypeListResponse; +import cloud.stackit.sdk.iaas.model.ManagementRoute; +import cloud.stackit.sdk.iaas.model.ManagementRouteListResponse; import cloud.stackit.sdk.iaas.model.NIC; import cloud.stackit.sdk.iaas.model.NICListResponse; import cloud.stackit.sdk.iaas.model.Network; @@ -65,12 +70,16 @@ import cloud.stackit.sdk.iaas.model.PublicIpListResponse; import cloud.stackit.sdk.iaas.model.PublicNetworkListResponse; import cloud.stackit.sdk.iaas.model.QuotaListResponse; +import cloud.stackit.sdk.iaas.model.RegionalArea; +import cloud.stackit.sdk.iaas.model.RegionalAreaListResponse; import cloud.stackit.sdk.iaas.model.Request; import cloud.stackit.sdk.iaas.model.RescueServerPayload; import cloud.stackit.sdk.iaas.model.ResizeServerPayload; import cloud.stackit.sdk.iaas.model.ResizeVolumePayload; import cloud.stackit.sdk.iaas.model.Route; import cloud.stackit.sdk.iaas.model.RouteListResponse; +import cloud.stackit.sdk.iaas.model.RoutingTable; +import cloud.stackit.sdk.iaas.model.RoutingTableListResponse; import cloud.stackit.sdk.iaas.model.SecurityGroup; import cloud.stackit.sdk.iaas.model.SecurityGroupListResponse; import cloud.stackit.sdk.iaas.model.SecurityGroupRule; @@ -83,17 +92,23 @@ import cloud.stackit.sdk.iaas.model.Snapshot; import cloud.stackit.sdk.iaas.model.SnapshotListResponse; import cloud.stackit.sdk.iaas.model.UpdateAttachedVolumePayload; -import cloud.stackit.sdk.iaas.model.UpdateBackupPayload; import cloud.stackit.sdk.iaas.model.UpdateImagePayload; import cloud.stackit.sdk.iaas.model.UpdateImageSharePayload; import cloud.stackit.sdk.iaas.model.UpdateKeyPairPayload; -import cloud.stackit.sdk.iaas.model.UpdateNetworkAreaRoutePayload; +import cloud.stackit.sdk.iaas.model.UpdateManagementNetworkRoutePayload; import cloud.stackit.sdk.iaas.model.UpdateNicPayload; import cloud.stackit.sdk.iaas.model.UpdatePublicIPPayload; -import cloud.stackit.sdk.iaas.model.UpdateSecurityGroupPayload; +import cloud.stackit.sdk.iaas.model.UpdateRouteOfRoutingTablePayload; +import cloud.stackit.sdk.iaas.model.UpdateRoutingTableOfAreaPayload; import cloud.stackit.sdk.iaas.model.UpdateServerPayload; -import cloud.stackit.sdk.iaas.model.UpdateSnapshotPayload; import cloud.stackit.sdk.iaas.model.UpdateVolumePayload; +import cloud.stackit.sdk.iaas.model.V2beta1ConfigureNetworkAreaRegionPayload; +import cloud.stackit.sdk.iaas.model.V2beta1CreateSnapshotPayload; +import cloud.stackit.sdk.iaas.model.V2beta1UpdateBackupPayload; +import cloud.stackit.sdk.iaas.model.V2beta1UpdateNetworkAreaRegionPayload; +import cloud.stackit.sdk.iaas.model.V2beta1UpdateRouteOfAreaPayload; +import cloud.stackit.sdk.iaas.model.V2beta1UpdateSecurityGroupPayload; +import cloud.stackit.sdk.iaas.model.V2beta1UpdateSnapshotPayload; import cloud.stackit.sdk.iaas.model.Volume; import cloud.stackit.sdk.iaas.model.VolumeAttachment; import cloud.stackit.sdk.iaas.model.VolumeAttachmentListResponse; @@ -154,6 +169,7 @@ public void setCustomBaseUrl(String customBaseUrl) { * Build call for addNetworkToServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param networkId The identifier (ID) of a STACKIT Network. (required) * @param _callback Callback for upload/download progress @@ -173,6 +189,7 @@ public void setCustomBaseUrl(String customBaseUrl) { */ public okhttp3.Call addNetworkToServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID networkId, final ApiCallback _callback) @@ -194,10 +211,13 @@ public okhttp3.Call addNetworkToServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/networks/{networkId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/networks/{networkId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", localVarApiClient.escapeString(serverId.toString())) @@ -242,6 +262,7 @@ public okhttp3.Call addNetworkToServerCall( @SuppressWarnings("rawtypes") private okhttp3.Call addNetworkToServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID networkId, final ApiCallback _callback) @@ -252,6 +273,12 @@ private okhttp3.Call addNetworkToServerValidateBeforeCall( "Missing the required parameter 'projectId' when calling addNetworkToServer(Async)"); } + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling addNetworkToServer(Async)"); + } + // verify the required parameter 'serverId' is set if (serverId == null) { throw new ApiException( @@ -264,7 +291,7 @@ private okhttp3.Call addNetworkToServerValidateBeforeCall( "Missing the required parameter 'networkId' when calling addNetworkToServer(Async)"); } - return addNetworkToServerCall(projectId, serverId, networkId, _callback); + return addNetworkToServerCall(projectId, region, serverId, networkId, _callback); } /** @@ -272,6 +299,7 @@ private okhttp3.Call addNetworkToServerValidateBeforeCall( * interface from the specified network to the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param networkId The identifier (ID) of a STACKIT Network. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the @@ -290,10 +318,11 @@ private okhttp3.Call addNetworkToServerValidateBeforeCall( */ public void addNetworkToServer( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID networkId) throws ApiException { - addNetworkToServerWithHttpInfo(projectId, serverId, networkId); + addNetworkToServerWithHttpInfo(projectId, region, serverId, networkId); } /** @@ -301,6 +330,7 @@ public void addNetworkToServer( * interface from the specified network to the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param networkId The identifier (ID) of a STACKIT Network. (required) * @return ApiResponse<Void> @@ -320,11 +350,12 @@ public void addNetworkToServer( */ public ApiResponse addNetworkToServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID networkId) throws ApiException { okhttp3.Call localVarCall = - addNetworkToServerValidateBeforeCall(projectId, serverId, networkId, null); + addNetworkToServerValidateBeforeCall(projectId, region, serverId, networkId, null); return localVarApiClient.execute(localVarCall); } @@ -333,6 +364,7 @@ public ApiResponse addNetworkToServerWithHttpInfo( * attach a network interface from the specified network to the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param networkId The identifier (ID) of a STACKIT Network. (required) * @param _callback The callback to be executed when the API call finishes @@ -353,13 +385,15 @@ public ApiResponse addNetworkToServerWithHttpInfo( */ public okhttp3.Call addNetworkToServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID networkId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - addNetworkToServerValidateBeforeCall(projectId, serverId, networkId, _callback); + addNetworkToServerValidateBeforeCall( + projectId, region, serverId, networkId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } @@ -368,6 +402,7 @@ public okhttp3.Call addNetworkToServerAsync( * Build call for addNicToServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param nicId The identifier (ID) of a network interface. (required) * @param _callback Callback for upload/download progress @@ -388,6 +423,7 @@ public okhttp3.Call addNetworkToServerAsync( */ public okhttp3.Call addNicToServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) @@ -409,10 +445,13 @@ public okhttp3.Call addNicToServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/nics/{nicId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/nics/{nicId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", localVarApiClient.escapeString(serverId.toString())) @@ -457,6 +496,7 @@ public okhttp3.Call addNicToServerCall( @SuppressWarnings("rawtypes") private okhttp3.Call addNicToServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) @@ -467,6 +507,12 @@ private okhttp3.Call addNicToServerValidateBeforeCall( "Missing the required parameter 'projectId' when calling addNicToServer(Async)"); } + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling addNicToServer(Async)"); + } + // verify the required parameter 'serverId' is set if (serverId == null) { throw new ApiException( @@ -479,13 +525,14 @@ private okhttp3.Call addNicToServerValidateBeforeCall( "Missing the required parameter 'nicId' when calling addNicToServer(Async)"); } - return addNicToServerCall(projectId, serverId, nicId, _callback); + return addNicToServerCall(projectId, region, serverId, nicId, _callback); } /** * Attach an existing network interface. Attach an existing network interface to a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param nicId The identifier (ID) of a network interface. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the @@ -505,16 +552,18 @@ private okhttp3.Call addNicToServerValidateBeforeCall( */ public void addNicToServer( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID nicId) throws ApiException { - addNicToServerWithHttpInfo(projectId, serverId, nicId); + addNicToServerWithHttpInfo(projectId, region, serverId, nicId); } /** * Attach an existing network interface. Attach an existing network interface to a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param nicId The identifier (ID) of a network interface. (required) * @return ApiResponse<Void> @@ -535,11 +584,12 @@ public void addNicToServer( */ public ApiResponse addNicToServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID nicId) throws ApiException { okhttp3.Call localVarCall = - addNicToServerValidateBeforeCall(projectId, serverId, nicId, null); + addNicToServerValidateBeforeCall(projectId, region, serverId, nicId, null); return localVarApiClient.execute(localVarCall); } @@ -548,6 +598,7 @@ public ApiResponse addNicToServerWithHttpInfo( * to a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param nicId The identifier (ID) of a network interface. (required) * @param _callback The callback to be executed when the API call finishes @@ -569,13 +620,14 @@ public ApiResponse addNicToServerWithHttpInfo( */ public okhttp3.Call addNicToServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - addNicToServerValidateBeforeCall(projectId, serverId, nicId, _callback); + addNicToServerValidateBeforeCall(projectId, region, serverId, nicId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } @@ -584,6 +636,7 @@ public okhttp3.Call addNicToServerAsync( * Build call for addPublicIpToServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback Callback for upload/download progress @@ -604,6 +657,7 @@ public okhttp3.Call addNicToServerAsync( */ public okhttp3.Call addPublicIpToServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) @@ -625,10 +679,13 @@ public okhttp3.Call addPublicIpToServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/public-ips/{publicIpId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/public-ips/{publicIpId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", localVarApiClient.escapeString(serverId.toString())) @@ -673,6 +730,7 @@ public okhttp3.Call addPublicIpToServerCall( @SuppressWarnings("rawtypes") private okhttp3.Call addPublicIpToServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) @@ -683,6 +741,12 @@ private okhttp3.Call addPublicIpToServerValidateBeforeCall( "Missing the required parameter 'projectId' when calling addPublicIpToServer(Async)"); } + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling addPublicIpToServer(Async)"); + } + // verify the required parameter 'serverId' is set if (serverId == null) { throw new ApiException( @@ -695,13 +759,14 @@ private okhttp3.Call addPublicIpToServerValidateBeforeCall( "Missing the required parameter 'publicIpId' when calling addPublicIpToServer(Async)"); } - return addPublicIpToServerCall(projectId, serverId, publicIpId, _callback); + return addPublicIpToServerCall(projectId, region, serverId, publicIpId, _callback); } /** * Associate a public IP to the server. Associate a public IP to a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param publicIpId The identifier (ID) of a Public IP. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the @@ -721,16 +786,18 @@ private okhttp3.Call addPublicIpToServerValidateBeforeCall( */ public void addPublicIpToServer( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID publicIpId) throws ApiException { - addPublicIpToServerWithHttpInfo(projectId, serverId, publicIpId); + addPublicIpToServerWithHttpInfo(projectId, region, serverId, publicIpId); } /** * Associate a public IP to the server. Associate a public IP to a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param publicIpId The identifier (ID) of a Public IP. (required) * @return ApiResponse<Void> @@ -751,11 +818,13 @@ public void addPublicIpToServer( */ public ApiResponse addPublicIpToServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID publicIpId) throws ApiException { okhttp3.Call localVarCall = - addPublicIpToServerValidateBeforeCall(projectId, serverId, publicIpId, null); + addPublicIpToServerValidateBeforeCall( + projectId, region, serverId, publicIpId, null); return localVarApiClient.execute(localVarCall); } @@ -763,6 +832,7 @@ public ApiResponse addPublicIpToServerWithHttpInfo( * Associate a public IP to the server. (asynchronously) Associate a public IP to a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback The callback to be executed when the API call finishes @@ -784,23 +854,28 @@ public ApiResponse addPublicIpToServerWithHttpInfo( */ public okhttp3.Call addPublicIpToServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - addPublicIpToServerValidateBeforeCall(projectId, serverId, publicIpId, _callback); + addPublicIpToServerValidateBeforeCall( + projectId, region, serverId, publicIpId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for addSecurityGroupToServer + * Build call for addRoutesToRoutingTable * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param addRoutesToRoutingTablePayload Request an addition of routes to a routing table. + * (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -808,7 +883,7 @@ public okhttp3.Call addPublicIpToServerAsync( * * * - * + * * * * @@ -817,10 +892,12 @@ public okhttp3.Call addPublicIpToServerAsync( * *
Response Details
Status Code Description Response Headers
202 Security group attachment request was accepted. -
201 Adding routes to routing table was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call addSecurityGroupToServerCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId, + public okhttp3.Call addRoutesToRoutingTableCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull AddRoutesToRoutingTablePayload addRoutesToRoutingTablePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -836,20 +913,23 @@ public okhttp3.Call addSecurityGroupToServerCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = addRoutesToRoutingTablePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/security-groups/{securityGroupId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables/{routingTableId}/routes" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -863,7 +943,7 @@ public okhttp3.Call addSecurityGroupToServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -874,7 +954,7 @@ public okhttp3.Call addSecurityGroupToServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PUT", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -886,46 +966,70 @@ public okhttp3.Call addSecurityGroupToServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call addSecurityGroupToServerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId, + private okhttp3.Call addRoutesToRoutingTableValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull AddRoutesToRoutingTablePayload addRoutesToRoutingTablePayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling addSecurityGroupToServer(Async)"); + "Missing the required parameter 'organizationId' when calling addRoutesToRoutingTable(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling addSecurityGroupToServer(Async)"); + "Missing the required parameter 'areaId' when calling addRoutesToRoutingTable(Async)"); } - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling addSecurityGroupToServer(Async)"); + "Missing the required parameter 'region' when calling addRoutesToRoutingTable(Async)"); + } + + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { + throw new ApiException( + "Missing the required parameter 'routingTableId' when calling addRoutesToRoutingTable(Async)"); } - return addSecurityGroupToServerCall(projectId, serverId, securityGroupId, _callback); + // verify the required parameter 'addRoutesToRoutingTablePayload' is set + if (addRoutesToRoutingTablePayload == null) { + throw new ApiException( + "Missing the required parameter 'addRoutesToRoutingTablePayload' when calling addRoutesToRoutingTable(Async)"); + } + + return addRoutesToRoutingTableCall( + organizationId, + areaId, + region, + routingTableId, + addRoutesToRoutingTablePayload, + _callback); } /** - * Add a server to a security group. Add an existing server to an existing security group. + * Create new routes in a routing table. Create new routes in an existing routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param addRoutesToRoutingTablePayload Request an addition of routes to a routing table. + * (required) + * @return RouteListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -934,28 +1038,40 @@ private okhttp3.Call addSecurityGroupToServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
202 Security group attachment request was accepted. -
201 Adding routes to routing table was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void addSecurityGroupToServer( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId) + public RouteListResponse addRoutesToRoutingTable( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull AddRoutesToRoutingTablePayload addRoutesToRoutingTablePayload) throws ApiException { - addSecurityGroupToServerWithHttpInfo(projectId, serverId, securityGroupId); + ApiResponse localVarResp = + addRoutesToRoutingTableWithHttpInfo( + organizationId, + areaId, + region, + routingTableId, + addRoutesToRoutingTablePayload); + return localVarResp.getData(); } /** - * Add a server to a security group. Add an existing server to an existing security group. + * Create new routes in a routing table. Create new routes in an existing routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @return ApiResponse<Void> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param addRoutesToRoutingTablePayload Request an addition of routes to a routing table. + * (required) + * @return ApiResponse<RouteListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -964,24 +1080,35 @@ public void addSecurityGroupToServer( * *
Response Details
Status Code Description Response Headers
202 Security group attachment request was accepted. -
201 Adding routes to routing table was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse addSecurityGroupToServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId) + public ApiResponse addRoutesToRoutingTableWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull AddRoutesToRoutingTablePayload addRoutesToRoutingTablePayload) throws ApiException { okhttp3.Call localVarCall = - addSecurityGroupToServerValidateBeforeCall( - projectId, serverId, securityGroupId, null); - return localVarApiClient.execute(localVarCall); + addRoutesToRoutingTableValidateBeforeCall( + organizationId, + areaId, + region, + routingTableId, + addRoutesToRoutingTablePayload, + null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Add a server to a security group. (asynchronously) Add an existing server to an existing - * security group. + * Create new routes in a routing table. (asynchronously) Create new routes in an existing + * routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param addRoutesToRoutingTablePayload Request an addition of routes to a routing table. + * (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -990,7 +1117,7 @@ public ApiResponse addSecurityGroupToServerWithHttpInfo( * * * - * + * * * * @@ -999,26 +1126,36 @@ public ApiResponse addSecurityGroupToServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
202 Security group attachment request was accepted. -
201 Adding routes to routing table was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call addSecurityGroupToServerAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId, - final ApiCallback _callback) + public okhttp3.Call addRoutesToRoutingTableAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull AddRoutesToRoutingTablePayload addRoutesToRoutingTablePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - addSecurityGroupToServerValidateBeforeCall( - projectId, serverId, securityGroupId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + addRoutesToRoutingTableValidateBeforeCall( + organizationId, + areaId, + region, + routingTableId, + addRoutesToRoutingTablePayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for addServiceAccountToServer + * Build call for addRoutingTableToArea * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param serviceAccountMail The e-mail address of a service account. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param addRoutingTableToAreaPayload Request an addition of a routing table to an area. + * (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -1026,7 +1163,7 @@ public okhttp3.Call addSecurityGroupToServerAsync( * * * - * + * * * * @@ -1035,10 +1172,11 @@ public okhttp3.Call addSecurityGroupToServerAsync( * *
Response Details
Status Code Description Response Headers
201 Service account attached to the server. -
201 Adding routing table was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call addServiceAccountToServerCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail, + public okhttp3.Call addRoutingTableToAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull AddRoutingTableToAreaPayload addRoutingTableToAreaPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -1054,20 +1192,20 @@ public okhttp3.Call addServiceAccountToServerCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = addRoutingTableToAreaPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/service-accounts/{serviceAccountMail}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) .replace( - "{" + "serviceAccountMail" + "}", - localVarApiClient.escapeString(serviceAccountMail.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -1081,7 +1219,7 @@ public okhttp3.Call addServiceAccountToServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -1092,7 +1230,7 @@ public okhttp3.Call addServiceAccountToServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PUT", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -1104,47 +1242,58 @@ public okhttp3.Call addServiceAccountToServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call addServiceAccountToServerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail, + private okhttp3.Call addRoutingTableToAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull AddRoutingTableToAreaPayload addRoutingTableToAreaPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling addServiceAccountToServer(Async)"); + "Missing the required parameter 'organizationId' when calling addRoutingTableToArea(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling addServiceAccountToServer(Async)"); + "Missing the required parameter 'areaId' when calling addRoutingTableToArea(Async)"); } - // verify the required parameter 'serviceAccountMail' is set - if (serviceAccountMail == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serviceAccountMail' when calling addServiceAccountToServer(Async)"); + "Missing the required parameter 'region' when calling addRoutingTableToArea(Async)"); + } + + // verify the required parameter 'addRoutingTableToAreaPayload' is set + if (addRoutingTableToAreaPayload == null) { + throw new ApiException( + "Missing the required parameter 'addRoutingTableToAreaPayload' when calling addRoutingTableToArea(Async)"); } - return addServiceAccountToServerCall(projectId, serverId, serviceAccountMail, _callback); + return addRoutingTableToAreaCall( + organizationId, areaId, region, addRoutingTableToAreaPayload, _callback); } /** - * Attach service account to a server. Attach an additional service account to the server. + * Create new routing table in a network area. Create a new routing table in an existing network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param serviceAccountMail The e-mail address of a service account. (required) - * @return ServiceAccountMailListResponse + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param addRoutingTableToAreaPayload Request an addition of a routing table to an area. + * (required) + * @return RoutingTable * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -1153,30 +1302,35 @@ private okhttp3.Call addServiceAccountToServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
201 Service account attached to the server. -
201 Adding routing table was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ServiceAccountMailListResponse addServiceAccountToServer( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail) + public RoutingTable addRoutingTableToArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull AddRoutingTableToAreaPayload addRoutingTableToAreaPayload) throws ApiException { - ApiResponse localVarResp = - addServiceAccountToServerWithHttpInfo(projectId, serverId, serviceAccountMail); + ApiResponse localVarResp = + addRoutingTableToAreaWithHttpInfo( + organizationId, areaId, region, addRoutingTableToAreaPayload); return localVarResp.getData(); } /** - * Attach service account to a server. Attach an additional service account to the server. + * Create new routing table in a network area. Create a new routing table in an existing network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param serviceAccountMail The e-mail address of a service account. (required) - * @return ApiResponse<ServiceAccountMailListResponse> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param addRoutingTableToAreaPayload Request an addition of a routing table to an area. + * (required) + * @return ApiResponse<RoutingTable> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -1185,25 +1339,28 @@ public ServiceAccountMailListResponse addServiceAccountToServer( * *
Response Details
Status Code Description Response Headers
201 Service account attached to the server. -
201 Adding routing table was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse addServiceAccountToServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail) + public ApiResponse addRoutingTableToAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull AddRoutingTableToAreaPayload addRoutingTableToAreaPayload) throws ApiException { okhttp3.Call localVarCall = - addServiceAccountToServerValidateBeforeCall( - projectId, serverId, serviceAccountMail, null); - Type localVarReturnType = new TypeToken() {}.getType(); + addRoutingTableToAreaValidateBeforeCall( + organizationId, areaId, region, addRoutingTableToAreaPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Attach service account to a server. (asynchronously) Attach an additional service account to - * the server. + * Create new routing table in a network area. (asynchronously) Create a new routing table in an + * existing network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param serviceAccountMail The e-mail address of a service account. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param addRoutingTableToAreaPayload Request an addition of a routing table to an area. + * (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -1212,7 +1369,7 @@ public ApiResponse addServiceAccountToServerWith * * * - * + * * * * @@ -1221,28 +1378,29 @@ public ApiResponse addServiceAccountToServerWith * *
Response Details
Status Code Description Response Headers
201 Service account attached to the server. -
201 Adding routing table was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call addServiceAccountToServerAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail, - final ApiCallback _callback) + public okhttp3.Call addRoutingTableToAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull AddRoutingTableToAreaPayload addRoutingTableToAreaPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - addServiceAccountToServerValidateBeforeCall( - projectId, serverId, serviceAccountMail, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + addRoutingTableToAreaValidateBeforeCall( + organizationId, areaId, region, addRoutingTableToAreaPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for addVolumeToServer + * Build call for addSecurityGroupToServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param addVolumeToServerPayload Request a volume attachment creation. (optional) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -1250,7 +1408,7 @@ public okhttp3.Call addServiceAccountToServerAsync( * * * - * + * * * * @@ -1259,11 +1417,11 @@ public okhttp3.Call addServiceAccountToServerAsync( * *
Response Details
Status Code Description Response Headers
202 Volume attachment request was accepted. -
202 Security group attachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call addVolumeToServerCall( + public okhttp3.Call addSecurityGroupToServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -1279,20 +1437,23 @@ public okhttp3.Call addVolumeToServerCall( basePath = null; } - Object localVarPostBody = addVolumeToServerPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/volume-attachments/{volumeId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/security-groups/{securityGroupId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", localVarApiClient.escapeString(serverId.toString())) .replace( - "{" + "volumeId" + "}", - localVarApiClient.escapeString(volumeId.toString())); + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -1306,7 +1467,7 @@ public okhttp3.Call addVolumeToServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -1329,50 +1490,55 @@ public okhttp3.Call addVolumeToServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call addVolumeToServerValidateBeforeCall( + private okhttp3.Call addSecurityGroupToServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling addVolumeToServer(Async)"); + "Missing the required parameter 'projectId' when calling addSecurityGroupToServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling addSecurityGroupToServer(Async)"); } // verify the required parameter 'serverId' is set if (serverId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling addVolumeToServer(Async)"); + "Missing the required parameter 'serverId' when calling addSecurityGroupToServer(Async)"); } - // verify the required parameter 'volumeId' is set - if (volumeId == null) { + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { throw new ApiException( - "Missing the required parameter 'volumeId' when calling addVolumeToServer(Async)"); + "Missing the required parameter 'securityGroupId' when calling addSecurityGroupToServer(Async)"); } - return addVolumeToServerCall( - projectId, serverId, volumeId, addVolumeToServerPayload, _callback); + return addSecurityGroupToServerCall( + projectId, region, serverId, securityGroupId, _callback); } /** - * Attach a volume to a server. Attach an existing volume to an existing server. + * Add a server to a security group. Add an existing server to an existing security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param addVolumeToServerPayload Request a volume attachment creation. (optional) - * @return VolumeAttachment + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -1381,33 +1547,30 @@ private okhttp3.Call addVolumeToServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
202 Volume attachment request was accepted. -
202 Security group attachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public VolumeAttachment addVolumeToServer( + public void addSecurityGroupToServer( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload) + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { - ApiResponse localVarResp = - addVolumeToServerWithHttpInfo( - projectId, serverId, volumeId, addVolumeToServerPayload); - return localVarResp.getData(); + addSecurityGroupToServerWithHttpInfo(projectId, region, serverId, securityGroupId); } /** - * Attach a volume to a server. Attach an existing volume to an existing server. + * Add a server to a security group. Add an existing server to an existing security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param addVolumeToServerPayload Request a volume attachment creation. (optional) - * @return ApiResponse<VolumeAttachment> + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -1416,27 +1579,26 @@ public VolumeAttachment addVolumeToServer( * *
Response Details
Status Code Description Response Headers
202 Volume attachment request was accepted. -
202 Security group attachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse addVolumeToServerWithHttpInfo( + public ApiResponse addSecurityGroupToServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload) + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { okhttp3.Call localVarCall = - addVolumeToServerValidateBeforeCall( - projectId, serverId, volumeId, addVolumeToServerPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + addSecurityGroupToServerValidateBeforeCall( + projectId, region, serverId, securityGroupId, null); + return localVarApiClient.execute(localVarCall); } /** - * Attach a volume to a server. (asynchronously) Attach an existing volume to an existing - * server. + * Add a server to a security group. (asynchronously) Add an existing server to an existing + * security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param addVolumeToServerPayload Request a volume attachment creation. (optional) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -1445,7 +1607,7 @@ public ApiResponse addVolumeToServerWithHttpInfo( * * * - * + * * * * @@ -1454,27 +1616,28 @@ public ApiResponse addVolumeToServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
202 Volume attachment request was accepted. -
202 Security group attachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call addVolumeToServerAsync( + public okhttp3.Call addSecurityGroupToServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull UUID securityGroupId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - addVolumeToServerValidateBeforeCall( - projectId, serverId, volumeId, addVolumeToServerPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + addSecurityGroupToServerValidateBeforeCall( + projectId, region, serverId, securityGroupId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for createAffinityGroup + * Build call for addServiceAccountToServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createAffinityGroupPayload Request a affinity group creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param serviceAccountMail The e-mail address of a service account. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -1482,17 +1645,20 @@ public okhttp3.Call addVolumeToServerAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Affinity group was created successfully. -
201 Service account attached to the server. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createAffinityGroupCall( + public okhttp3.Call addServiceAccountToServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -1508,14 +1674,23 @@ public okhttp3.Call createAffinityGroupCall( basePath = null; } - Object localVarPostBody = createAffinityGroupPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/affinity-groups" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/service-accounts/{serviceAccountMail}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "serviceAccountMail" + "}", + localVarApiClient.escapeString(serviceAccountMail.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -1529,7 +1704,7 @@ public okhttp3.Call createAffinityGroupCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -1540,7 +1715,7 @@ public okhttp3.Call createAffinityGroupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -1552,93 +1727,120 @@ public okhttp3.Call createAffinityGroupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createAffinityGroupValidateBeforeCall( + private okhttp3.Call addServiceAccountToServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createAffinityGroup(Async)"); + "Missing the required parameter 'projectId' when calling addServiceAccountToServer(Async)"); } - // verify the required parameter 'createAffinityGroupPayload' is set - if (createAffinityGroupPayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'createAffinityGroupPayload' when calling createAffinityGroup(Async)"); + "Missing the required parameter 'region' when calling addServiceAccountToServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling addServiceAccountToServer(Async)"); + } + + // verify the required parameter 'serviceAccountMail' is set + if (serviceAccountMail == null) { + throw new ApiException( + "Missing the required parameter 'serviceAccountMail' when calling addServiceAccountToServer(Async)"); } - return createAffinityGroupCall(projectId, createAffinityGroupPayload, _callback); + return addServiceAccountToServerCall( + projectId, region, serverId, serviceAccountMail, _callback); } /** - * Create a new affinity group in a project. Create a new server affinity group in the given - * project ID. + * Attach service account to a server. Attach an additional service account to the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createAffinityGroupPayload Request a affinity group creation. (required) - * @return AffinityGroup + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param serviceAccountMail The e-mail address of a service account. (required) + * @return ServiceAccountMailListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Affinity group was created successfully. -
201 Service account attached to the server. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public AffinityGroup createAffinityGroup( + public ServiceAccountMailListResponse addServiceAccountToServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail) throws ApiException { - ApiResponse localVarResp = - createAffinityGroupWithHttpInfo(projectId, createAffinityGroupPayload); + ApiResponse localVarResp = + addServiceAccountToServerWithHttpInfo( + projectId, region, serverId, serviceAccountMail); return localVarResp.getData(); } /** - * Create a new affinity group in a project. Create a new server affinity group in the given - * project ID. + * Attach service account to a server. Attach an additional service account to the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createAffinityGroupPayload Request a affinity group creation. (required) - * @return ApiResponse<AffinityGroup> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param serviceAccountMail The e-mail address of a service account. (required) + * @return ApiResponse<ServiceAccountMailListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Affinity group was created successfully. -
201 Service account attached to the server. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createAffinityGroupWithHttpInfo( + public ApiResponse addServiceAccountToServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail) throws ApiException { okhttp3.Call localVarCall = - createAffinityGroupValidateBeforeCall(projectId, createAffinityGroupPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + addServiceAccountToServerValidateBeforeCall( + projectId, region, serverId, serviceAccountMail, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create a new affinity group in a project. (asynchronously) Create a new server affinity group - * in the given project ID. + * Attach service account to a server. (asynchronously) Attach an additional service account to + * the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createAffinityGroupPayload Request a affinity group creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param serviceAccountMail The e-mail address of a service account. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -1647,33 +1849,39 @@ public ApiResponse createAffinityGroupWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Affinity group was created successfully. -
201 Service account attached to the server. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createAffinityGroupAsync( + public okhttp3.Call addServiceAccountToServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createAffinityGroupValidateBeforeCall( - projectId, createAffinityGroupPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + addServiceAccountToServerValidateBeforeCall( + projectId, region, serverId, serviceAccountMail, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createBackup + * Build call for addVolumeToServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createBackupPayload Request a backup creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param addVolumeToServerPayload Request a volume attachment creation. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -1681,17 +1889,21 @@ public okhttp3.Call createAffinityGroupAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Create request for Backup accepted. -
202 Volume attachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createBackupCall( + public okhttp3.Call addVolumeToServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateBackupPayload createBackupPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -1707,14 +1919,23 @@ public okhttp3.Call createBackupCall( basePath = null; } - Object localVarPostBody = createBackupPayload; + Object localVarPostBody = addVolumeToServerPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/volume-attachments/{volumeId}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "volumeId" + "}", + localVarApiClient.escapeString(volumeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -1739,7 +1960,7 @@ public okhttp3.Call createBackupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -1751,92 +1972,126 @@ public okhttp3.Call createBackupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createBackupValidateBeforeCall( + private okhttp3.Call addVolumeToServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateBackupPayload createBackupPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createBackup(Async)"); + "Missing the required parameter 'projectId' when calling addVolumeToServer(Async)"); } - // verify the required parameter 'createBackupPayload' is set - if (createBackupPayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'createBackupPayload' when calling createBackup(Async)"); + "Missing the required parameter 'region' when calling addVolumeToServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling addVolumeToServer(Async)"); } - return createBackupCall(projectId, createBackupPayload, _callback); + // verify the required parameter 'volumeId' is set + if (volumeId == null) { + throw new ApiException( + "Missing the required parameter 'volumeId' when calling addVolumeToServer(Async)"); + } + + return addVolumeToServerCall( + projectId, region, serverId, volumeId, addVolumeToServerPayload, _callback); } /** - * Create new Backup. Create a new Backup in a project. If a snapshot ID is provided create the - * backup from the snapshot. + * Attach a volume to a server. Attach an existing volume to an existing server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createBackupPayload Request a backup creation. (required) - * @return Backup + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param addVolumeToServerPayload Request a volume attachment creation. (optional) + * @return VolumeAttachment * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Create request for Backup accepted. -
202 Volume attachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Backup createBackup( + public VolumeAttachment addVolumeToServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateBackupPayload createBackupPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload) throws ApiException { - ApiResponse localVarResp = createBackupWithHttpInfo(projectId, createBackupPayload); + ApiResponse localVarResp = + addVolumeToServerWithHttpInfo( + projectId, region, serverId, volumeId, addVolumeToServerPayload); return localVarResp.getData(); } /** - * Create new Backup. Create a new Backup in a project. If a snapshot ID is provided create the - * backup from the snapshot. + * Attach a volume to a server. Attach an existing volume to an existing server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createBackupPayload Request a backup creation. (required) - * @return ApiResponse<Backup> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param addVolumeToServerPayload Request a volume attachment creation. (optional) + * @return ApiResponse<VolumeAttachment> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Create request for Backup accepted. -
202 Volume attachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createBackupWithHttpInfo( + public ApiResponse addVolumeToServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateBackupPayload createBackupPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload) throws ApiException { okhttp3.Call localVarCall = - createBackupValidateBeforeCall(projectId, createBackupPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + addVolumeToServerValidateBeforeCall( + projectId, region, serverId, volumeId, addVolumeToServerPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new Backup. (asynchronously) Create a new Backup in a project. If a snapshot ID is - * provided create the backup from the snapshot. + * Attach a volume to a server. (asynchronously) Attach an existing volume to an existing + * server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createBackupPayload Request a backup creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param addVolumeToServerPayload Request a volume attachment creation. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -1845,32 +2100,38 @@ public ApiResponse createBackupWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Create request for Backup accepted. -
202 Volume attachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createBackupAsync( + public okhttp3.Call addVolumeToServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateBackupPayload createBackupPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable AddVolumeToServerPayload addVolumeToServerPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createBackupValidateBeforeCall(projectId, createBackupPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + addVolumeToServerValidateBeforeCall( + projectId, region, serverId, volumeId, addVolumeToServerPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createImage + * Build call for createAffinityGroup * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createImagePayload Request an image creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createAffinityGroupPayload Request a affinity group creation. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -1878,18 +2139,18 @@ public okhttp3.Call createBackupAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Create request for an Image has been accepted. -
201 Affinity group was created successfully. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createImageCall( + public okhttp3.Call createAffinityGroupCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateImagePayload createImagePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -1905,14 +2166,17 @@ public okhttp3.Call createImageCall( basePath = null; } - Object localVarPostBody = createImagePayload; + Object localVarPostBody = createAffinityGroupPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images" + "/v2beta1/projects/{projectId}/regions/{region}/affinity-groups" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -1949,95 +2213,106 @@ public okhttp3.Call createImageCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createImageValidateBeforeCall( + private okhttp3.Call createAffinityGroupValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateImagePayload createImagePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createImage(Async)"); + "Missing the required parameter 'projectId' when calling createAffinityGroup(Async)"); } - // verify the required parameter 'createImagePayload' is set - if (createImagePayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'createImagePayload' when calling createImage(Async)"); + "Missing the required parameter 'region' when calling createAffinityGroup(Async)"); + } + + // verify the required parameter 'createAffinityGroupPayload' is set + if (createAffinityGroupPayload == null) { + throw new ApiException( + "Missing the required parameter 'createAffinityGroupPayload' when calling createAffinityGroup(Async)"); } - return createImageCall(projectId, createImagePayload, _callback); + return createAffinityGroupCall(projectId, region, createAffinityGroupPayload, _callback); } /** - * Create new Image. Create a new Image in a project. This call, if successful, returns a - * pre-signed URL for the customer to upload the image. + * Create a new affinity group in a project. Create a new server affinity group in the given + * project ID. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createImagePayload Request an image creation. (required) - * @return ImageCreateResponse + * @param region The STACKIT Region of the resources. (required) + * @param createAffinityGroupPayload Request a affinity group creation. (required) + * @return AffinityGroup * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Create request for an Image has been accepted. -
201 Affinity group was created successfully. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ImageCreateResponse createImage( + public AffinityGroup createAffinityGroup( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateImagePayload createImagePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload) throws ApiException { - ApiResponse localVarResp = - createImageWithHttpInfo(projectId, createImagePayload); + ApiResponse localVarResp = + createAffinityGroupWithHttpInfo(projectId, region, createAffinityGroupPayload); return localVarResp.getData(); } /** - * Create new Image. Create a new Image in a project. This call, if successful, returns a - * pre-signed URL for the customer to upload the image. + * Create a new affinity group in a project. Create a new server affinity group in the given + * project ID. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createImagePayload Request an image creation. (required) - * @return ApiResponse<ImageCreateResponse> + * @param region The STACKIT Region of the resources. (required) + * @param createAffinityGroupPayload Request a affinity group creation. (required) + * @return ApiResponse<AffinityGroup> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Create request for an Image has been accepted. -
201 Affinity group was created successfully. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createImageWithHttpInfo( + public ApiResponse createAffinityGroupWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateImagePayload createImagePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload) throws ApiException { okhttp3.Call localVarCall = - createImageValidateBeforeCall(projectId, createImagePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + createAffinityGroupValidateBeforeCall( + projectId, region, createAffinityGroupPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new Image. (asynchronously) Create a new Image in a project. This call, if successful, - * returns a pre-signed URL for the customer to upload the image. + * Create a new affinity group in a project. (asynchronously) Create a new server affinity group + * in the given project ID. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createImagePayload Request an image creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createAffinityGroupPayload Request a affinity group creation. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -2046,32 +2321,35 @@ public ApiResponse createImageWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Create request for an Image has been accepted. -
201 Affinity group was created successfully. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createImageAsync( + public okhttp3.Call createAffinityGroupAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateImagePayload createImagePayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateAffinityGroupPayload createAffinityGroupPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createImageValidateBeforeCall(projectId, createImagePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + createAffinityGroupValidateBeforeCall( + projectId, region, createAffinityGroupPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createKeyPair + * Build call for createBackup * - * @param createKeyPairPayload Request a public key import. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createBackupPayload Request a backup creation. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -2079,17 +2357,18 @@ public okhttp3.Call createImageAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Import of the public key was successful. -
201 Create request for Backup accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createKeyPairCall( - @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload, + public okhttp3.Call createBackupCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateBackupPayload createBackupPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -2105,10 +2384,17 @@ public okhttp3.Call createKeyPairCall( basePath = null; } - Object localVarPostBody = createKeyPairPayload; + Object localVarPostBody = createBackupPayload; // create path and map variables - String localVarPath = "/v1/keypairs"; + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/backups" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -2145,91 +2431,105 @@ public okhttp3.Call createKeyPairCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createKeyPairValidateBeforeCall( - @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload, + private okhttp3.Call createBackupValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateBackupPayload createBackupPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'createKeyPairPayload' is set - if (createKeyPairPayload == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'createKeyPairPayload' when calling createKeyPair(Async)"); + "Missing the required parameter 'projectId' when calling createBackup(Async)"); } - return createKeyPairCall(createKeyPairPayload, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createBackup(Async)"); + } + + // verify the required parameter 'createBackupPayload' is set + if (createBackupPayload == null) { + throw new ApiException( + "Missing the required parameter 'createBackupPayload' when calling createBackup(Async)"); + } + + return createBackupCall(projectId, region, createBackupPayload, _callback); } /** - * Import a public key. Import a new public key for the requesting user based on provided public - * key material. The creation will fail if an SSH keypair with the same name already exists. If - * a name is not provided it is autogenerated form the ssh-pubkey comment section. If that is - * also not present it will be the the MD5 fingerprint of the key. For autogenerated names - * invalid characters will be removed. Supported keypair types are ecdsa, ed25519 and rsa. + * Create new Backup. Create a new Backup in a project. If a snapshot ID is provided create the + * backup from the snapshot. * - * @param createKeyPairPayload Request a public key import. (required) - * @return Keypair + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createBackupPayload Request a backup creation. (required) + * @return Backup * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Import of the public key was successful. -
201 Create request for Backup accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Keypair createKeyPair( - @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload) + public Backup createBackup( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateBackupPayload createBackupPayload) throws ApiException { - ApiResponse localVarResp = createKeyPairWithHttpInfo(createKeyPairPayload); + ApiResponse localVarResp = + createBackupWithHttpInfo(projectId, region, createBackupPayload); return localVarResp.getData(); } /** - * Import a public key. Import a new public key for the requesting user based on provided public - * key material. The creation will fail if an SSH keypair with the same name already exists. If - * a name is not provided it is autogenerated form the ssh-pubkey comment section. If that is - * also not present it will be the the MD5 fingerprint of the key. For autogenerated names - * invalid characters will be removed. Supported keypair types are ecdsa, ed25519 and rsa. + * Create new Backup. Create a new Backup in a project. If a snapshot ID is provided create the + * backup from the snapshot. * - * @param createKeyPairPayload Request a public key import. (required) - * @return ApiResponse<Keypair> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createBackupPayload Request a backup creation. (required) + * @return ApiResponse<Backup> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Import of the public key was successful. -
201 Create request for Backup accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createKeyPairWithHttpInfo( - @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload) + public ApiResponse createBackupWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateBackupPayload createBackupPayload) throws ApiException { - okhttp3.Call localVarCall = createKeyPairValidateBeforeCall(createKeyPairPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + createBackupValidateBeforeCall(projectId, region, createBackupPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Import a public key. (asynchronously) Import a new public key for the requesting user based - * on provided public key material. The creation will fail if an SSH keypair with the same name - * already exists. If a name is not provided it is autogenerated form the ssh-pubkey comment - * section. If that is also not present it will be the the MD5 fingerprint of the key. For - * autogenerated names invalid characters will be removed. Supported keypair types are ecdsa, - * ed25519 and rsa. + * Create new Backup. (asynchronously) Create a new Backup in a project. If a snapshot ID is + * provided create the backup from the snapshot. * - * @param createKeyPairPayload Request a public key import. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createBackupPayload Request a backup creation. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -2238,32 +2538,34 @@ public ApiResponse createKeyPairWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Import of the public key was successful. -
201 Create request for Backup accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createKeyPairAsync( - @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload, - final ApiCallback _callback) + public okhttp3.Call createBackupAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateBackupPayload createBackupPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createKeyPairValidateBeforeCall(createKeyPairPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + createBackupValidateBeforeCall(projectId, region, createBackupPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createNetwork + * Build call for createImage * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createNetworkPayload Request a network creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createImagePayload Request an image creation. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -2271,18 +2573,19 @@ public okhttp3.Call createKeyPairAsync( * * * - * + * * * * * - * + * * *
Response Details
Status Code Description Response Headers
202 Network create has been accepted. -
201 Create request for an Image has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNetworkCall( + public okhttp3.Call createImageCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateImagePayload createImagePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -2298,14 +2601,17 @@ public okhttp3.Call createNetworkCall( basePath = null; } - Object localVarPostBody = createNetworkPayload; + Object localVarPostBody = createImagePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks" + "/v2beta1/projects/{projectId}/regions/{region}/images" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -2342,101 +2648,107 @@ public okhttp3.Call createNetworkCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createNetworkValidateBeforeCall( + private okhttp3.Call createImageValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateImagePayload createImagePayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createNetwork(Async)"); + "Missing the required parameter 'projectId' when calling createImage(Async)"); } - // verify the required parameter 'createNetworkPayload' is set - if (createNetworkPayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'createNetworkPayload' when calling createNetwork(Async)"); + "Missing the required parameter 'region' when calling createImage(Async)"); } - return createNetworkCall(projectId, createNetworkPayload, _callback); - } + // verify the required parameter 'createImagePayload' is set + if (createImagePayload == null) { + throw new ApiException( + "Missing the required parameter 'createImagePayload' when calling createImage(Async)"); + } + + return createImageCall(projectId, region, createImagePayload, _callback); + } /** - * Create new network. Create a new network in a project. `nameservers` will be filled - * from `defaultNameservers` of the respective area if not specified. If the project - * has `internetAccess` enabled and this is the first network in the project this - * might incur cost. + * Create new Image. Create a new Image in a project. This call, if successful, returns a + * pre-signed URL for the customer to upload the image. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createNetworkPayload Request a network creation. (required) - * @return Network + * @param region The STACKIT Region of the resources. (required) + * @param createImagePayload Request an image creation. (required) + * @return ImageCreateResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * + * * *
Response Details
Status Code Description Response Headers
202 Network create has been accepted. -
201 Create request for an Image has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Network createNetwork( + public ImageCreateResponse createImage( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateImagePayload createImagePayload) throws ApiException { - ApiResponse localVarResp = - createNetworkWithHttpInfo(projectId, createNetworkPayload); + ApiResponse localVarResp = + createImageWithHttpInfo(projectId, region, createImagePayload); return localVarResp.getData(); } /** - * Create new network. Create a new network in a project. `nameservers` will be filled - * from `defaultNameservers` of the respective area if not specified. If the project - * has `internetAccess` enabled and this is the first network in the project this - * might incur cost. + * Create new Image. Create a new Image in a project. This call, if successful, returns a + * pre-signed URL for the customer to upload the image. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createNetworkPayload Request a network creation. (required) - * @return ApiResponse<Network> + * @param region The STACKIT Region of the resources. (required) + * @param createImagePayload Request an image creation. (required) + * @return ApiResponse<ImageCreateResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * + * * *
Response Details
Status Code Description Response Headers
202 Network create has been accepted. -
201 Create request for an Image has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createNetworkWithHttpInfo( + public ApiResponse createImageWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateImagePayload createImagePayload) throws ApiException { okhttp3.Call localVarCall = - createNetworkValidateBeforeCall(projectId, createNetworkPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + createImageValidateBeforeCall(projectId, region, createImagePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new network. (asynchronously) Create a new network in a project. - * `nameservers` will be filled from `defaultNameservers` of the respective - * area if not specified. If the project has `internetAccess` enabled and this is the - * first network in the project this might incur cost. + * Create new Image. (asynchronously) Create a new Image in a project. This call, if successful, + * returns a pre-signed URL for the customer to upload the image. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createNetworkPayload Request a network creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createImagePayload Request an image creation. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -2445,33 +2757,33 @@ public ApiResponse createNetworkWithHttpInfo( * * * - * + * * * * * - * + * * *
Response Details
Status Code Description Response Headers
202 Network create has been accepted. -
201 Create request for an Image has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNetworkAsync( + public okhttp3.Call createImageAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateImagePayload createImagePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createNetworkValidateBeforeCall(projectId, createNetworkPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + createImageValidateBeforeCall(projectId, region, createImagePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createNetworkArea + * Build call for createKeyPair * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param createNetworkAreaPayload Request an area creation. (required) + * @param createKeyPairPayload Request a public key import. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -2479,17 +2791,17 @@ public okhttp3.Call createNetworkAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Area has been successfully created. -
201 Import of the public key was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNetworkAreaCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload, + public okhttp3.Call createKeyPairCall( + @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -2505,14 +2817,10 @@ public okhttp3.Call createNetworkAreaCall( basePath = null; } - Object localVarPostBody = createNetworkAreaPayload; + Object localVarPostBody = createKeyPairPayload; // create path and map variables - String localVarPath = - "/v1/organizations/{organizationId}/network-areas" - .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())); + String localVarPath = "/v2beta1/keypairs"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -2549,91 +2857,90 @@ public okhttp3.Call createNetworkAreaCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createNetworkAreaValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload, + private okhttp3.Call createKeyPairValidateBeforeCall( + @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { - throw new ApiException( - "Missing the required parameter 'organizationId' when calling createNetworkArea(Async)"); - } - - // verify the required parameter 'createNetworkAreaPayload' is set - if (createNetworkAreaPayload == null) { + // verify the required parameter 'createKeyPairPayload' is set + if (createKeyPairPayload == null) { throw new ApiException( - "Missing the required parameter 'createNetworkAreaPayload' when calling createNetworkArea(Async)"); + "Missing the required parameter 'createKeyPairPayload' when calling createKeyPair(Async)"); } - return createNetworkAreaCall(organizationId, createNetworkAreaPayload, _callback); + return createKeyPairCall(createKeyPairPayload, _callback); } /** - * Create new network area in an organization. Create a new network area in an organization. + * Import a public key. Import a new public key for the requesting user based on provided public + * key material. The creation will fail if an SSH keypair with the same name already exists. If + * a name is not provided it is autogenerated form the ssh-pubkey comment section. If that is + * also not present it will be the the MD5 fingerprint of the key. For autogenerated names + * invalid characters will be removed. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param createNetworkAreaPayload Request an area creation. (required) - * @return NetworkArea + * @param createKeyPairPayload Request a public key import. (required) + * @return Keypair * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Area has been successfully created. -
201 Import of the public key was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NetworkArea createNetworkArea( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload) + public Keypair createKeyPair( + @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload) throws ApiException { - ApiResponse localVarResp = - createNetworkAreaWithHttpInfo(organizationId, createNetworkAreaPayload); + ApiResponse localVarResp = createKeyPairWithHttpInfo(createKeyPairPayload); return localVarResp.getData(); } /** - * Create new network area in an organization. Create a new network area in an organization. + * Import a public key. Import a new public key for the requesting user based on provided public + * key material. The creation will fail if an SSH keypair with the same name already exists. If + * a name is not provided it is autogenerated form the ssh-pubkey comment section. If that is + * also not present it will be the the MD5 fingerprint of the key. For autogenerated names + * invalid characters will be removed. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param createNetworkAreaPayload Request an area creation. (required) - * @return ApiResponse<NetworkArea> + * @param createKeyPairPayload Request a public key import. (required) + * @return ApiResponse<Keypair> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Area has been successfully created. -
201 Import of the public key was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createNetworkAreaWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload) + public ApiResponse createKeyPairWithHttpInfo( + @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload) throws ApiException { - okhttp3.Call localVarCall = - createNetworkAreaValidateBeforeCall(organizationId, createNetworkAreaPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = createKeyPairValidateBeforeCall(createKeyPairPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new network area in an organization. (asynchronously) Create a new network area in an - * organization. + * Import a public key. (asynchronously) Import a new public key for the requesting user based + * on provided public key material. The creation will fail if an SSH keypair with the same name + * already exists. If a name is not provided it is autogenerated form the ssh-pubkey comment + * section. If that is also not present it will be the the MD5 fingerprint of the key. For + * autogenerated names invalid characters will be removed. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param createNetworkAreaPayload Request an area creation. (required) + * @param createKeyPairPayload Request a public key import. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -2642,35 +2949,33 @@ public ApiResponse createNetworkAreaWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Area has been successfully created. -
201 Import of the public key was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNetworkAreaAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload, - final ApiCallback _callback) + public okhttp3.Call createKeyPairAsync( + @javax.annotation.Nonnull CreateKeyPairPayload createKeyPairPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createNetworkAreaValidateBeforeCall( - organizationId, createNetworkAreaPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + createKeyPairValidateBeforeCall(createKeyPairPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createNetworkAreaRange + * Build call for createManagementNetwork * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param createNetworkAreaRangePayload Request an addition of network ranges to an area. - * (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createManagementNetworkPayload Request a management network creation. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -2678,19 +2983,18 @@ public okhttp3.Call createNetworkAreaAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Adding network ranges was successful. -
202 Management Network creation has been successfully accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNetworkAreaRangeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload, + public okhttp3.Call createManagementNetworkCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateManagementNetworkPayload createManagementNetworkPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -2706,17 +3010,17 @@ public okhttp3.Call createNetworkAreaRangeCall( basePath = null; } - Object localVarPostBody = createNetworkAreaRangePayload; + Object localVarPostBody = createManagementNetworkPayload; // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/network-ranges" + "/v2beta1/projects/{projectId}/regions/{region}/management-network" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -2753,113 +3057,108 @@ public okhttp3.Call createNetworkAreaRangeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createNetworkAreaRangeValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload, + private okhttp3.Call createManagementNetworkValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateManagementNetworkPayload createManagementNetworkPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling createNetworkAreaRange(Async)"); + "Missing the required parameter 'projectId' when calling createManagementNetwork(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling createNetworkAreaRange(Async)"); + "Missing the required parameter 'region' when calling createManagementNetwork(Async)"); } - // verify the required parameter 'createNetworkAreaRangePayload' is set - if (createNetworkAreaRangePayload == null) { + // verify the required parameter 'createManagementNetworkPayload' is set + if (createManagementNetworkPayload == null) { throw new ApiException( - "Missing the required parameter 'createNetworkAreaRangePayload' when calling createNetworkAreaRange(Async)"); + "Missing the required parameter 'createManagementNetworkPayload' when calling createManagementNetwork(Async)"); } - return createNetworkAreaRangeCall( - organizationId, areaId, createNetworkAreaRangePayload, _callback); + return createManagementNetworkCall( + projectId, region, createManagementNetworkPayload, _callback); } /** - * Create new network range in a network area. Create a new network range in an existing network - * area. + * Create new management network. Create resources for a management network and gain access to + * the management transfer network. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param createNetworkAreaRangePayload Request an addition of network ranges to an area. - * (required) - * @return NetworkRangeListResponse + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createManagementNetworkPayload Request a management network creation. (required) + * @return Network * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Adding network ranges was successful. -
202 Management Network creation has been successfully accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NetworkRangeListResponse createNetworkAreaRange( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload) + public Network createManagementNetwork( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateManagementNetworkPayload createManagementNetworkPayload) throws ApiException { - ApiResponse localVarResp = - createNetworkAreaRangeWithHttpInfo( - organizationId, areaId, createNetworkAreaRangePayload); + ApiResponse localVarResp = + createManagementNetworkWithHttpInfo( + projectId, region, createManagementNetworkPayload); return localVarResp.getData(); } /** - * Create new network range in a network area. Create a new network range in an existing network - * area. + * Create new management network. Create resources for a management network and gain access to + * the management transfer network. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param createNetworkAreaRangePayload Request an addition of network ranges to an area. - * (required) - * @return ApiResponse<NetworkRangeListResponse> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createManagementNetworkPayload Request a management network creation. (required) + * @return ApiResponse<Network> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Adding network ranges was successful. -
202 Management Network creation has been successfully accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createNetworkAreaRangeWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload) + public ApiResponse createManagementNetworkWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateManagementNetworkPayload createManagementNetworkPayload) throws ApiException { okhttp3.Call localVarCall = - createNetworkAreaRangeValidateBeforeCall( - organizationId, areaId, createNetworkAreaRangePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + createManagementNetworkValidateBeforeCall( + projectId, region, createManagementNetworkPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new network range in a network area. (asynchronously) Create a new network range in an - * existing network area. + * Create new management network. (asynchronously) Create resources for a management network and + * gain access to the management transfer network. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param createNetworkAreaRangePayload Request an addition of network ranges to an area. - * (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createManagementNetworkPayload Request a management network creation. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -2868,36 +3167,36 @@ public ApiResponse createNetworkAreaRangeWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Adding network ranges was successful. -
202 Management Network creation has been successfully accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNetworkAreaRangeAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload, - final ApiCallback _callback) + public okhttp3.Call createManagementNetworkAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateManagementNetworkPayload createManagementNetworkPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createNetworkAreaRangeValidateBeforeCall( - organizationId, areaId, createNetworkAreaRangePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + createManagementNetworkValidateBeforeCall( + projectId, region, createManagementNetworkPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createNetworkAreaRoute + * Build call for createManagementNetworkRoute * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param createNetworkAreaRoutePayload Request an addition of routes to an area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createManagementNetworkRoutePayload Request an addition of routes to a management + * network. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -2905,7 +3204,7 @@ public okhttp3.Call createNetworkAreaRangeAsync( * * * - * + * * * * @@ -2914,10 +3213,11 @@ public okhttp3.Call createNetworkAreaRangeAsync( * *
Response Details
Status Code Description Response Headers
202 Create request for network routes has been accepted. -
201 Management network route created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNetworkAreaRouteCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload, + public okhttp3.Call createManagementNetworkRouteCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + CreateManagementNetworkRoutePayload createManagementNetworkRoutePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -2933,17 +3233,17 @@ public okhttp3.Call createNetworkAreaRouteCall( basePath = null; } - Object localVarPostBody = createNetworkAreaRoutePayload; + Object localVarPostBody = createManagementNetworkRoutePayload; // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/routes" + "/v2beta1/projects/{projectId}/regions/{region}/management-network/routes" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -2980,48 +3280,51 @@ public okhttp3.Call createNetworkAreaRouteCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createNetworkAreaRouteValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload, + private okhttp3.Call createManagementNetworkRouteValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + CreateManagementNetworkRoutePayload createManagementNetworkRoutePayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling createNetworkAreaRoute(Async)"); + "Missing the required parameter 'projectId' when calling createManagementNetworkRoute(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling createNetworkAreaRoute(Async)"); + "Missing the required parameter 'region' when calling createManagementNetworkRoute(Async)"); } - // verify the required parameter 'createNetworkAreaRoutePayload' is set - if (createNetworkAreaRoutePayload == null) { + // verify the required parameter 'createManagementNetworkRoutePayload' is set + if (createManagementNetworkRoutePayload == null) { throw new ApiException( - "Missing the required parameter 'createNetworkAreaRoutePayload' when calling createNetworkAreaRoute(Async)"); + "Missing the required parameter 'createManagementNetworkRoutePayload' when calling createManagementNetworkRoute(Async)"); } - return createNetworkAreaRouteCall( - organizationId, areaId, createNetworkAreaRoutePayload, _callback); + return createManagementNetworkRouteCall( + projectId, region, createManagementNetworkRoutePayload, _callback); } /** - * Create new network routes. Create one or several new network routes in a network area. + * Create new management network routes. Create one or several new routes in a management + * network. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param createNetworkAreaRoutePayload Request an addition of routes to an area. (required) - * @return RouteListResponse + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createManagementNetworkRoutePayload Request an addition of routes to a management + * network. (required) + * @return ManagementRouteListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -3030,31 +3333,34 @@ private okhttp3.Call createNetworkAreaRouteValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
202 Create request for network routes has been accepted. -
201 Management network route created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public RouteListResponse createNetworkAreaRoute( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload) + public ManagementRouteListResponse createManagementNetworkRoute( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + CreateManagementNetworkRoutePayload createManagementNetworkRoutePayload) throws ApiException { - ApiResponse localVarResp = - createNetworkAreaRouteWithHttpInfo( - organizationId, areaId, createNetworkAreaRoutePayload); + ApiResponse localVarResp = + createManagementNetworkRouteWithHttpInfo( + projectId, region, createManagementNetworkRoutePayload); return localVarResp.getData(); } /** - * Create new network routes. Create one or several new network routes in a network area. + * Create new management network routes. Create one or several new routes in a management + * network. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param createNetworkAreaRoutePayload Request an addition of routes to an area. (required) - * @return ApiResponse<RouteListResponse> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createManagementNetworkRoutePayload Request an addition of routes to a management + * network. (required) + * @return ApiResponse<ManagementRouteListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -3063,25 +3369,27 @@ public RouteListResponse createNetworkAreaRoute( * *
Response Details
Status Code Description Response Headers
202 Create request for network routes has been accepted. -
201 Management network route created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createNetworkAreaRouteWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload) + public ApiResponse createManagementNetworkRouteWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + CreateManagementNetworkRoutePayload createManagementNetworkRoutePayload) throws ApiException { okhttp3.Call localVarCall = - createNetworkAreaRouteValidateBeforeCall( - organizationId, areaId, createNetworkAreaRoutePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + createManagementNetworkRouteValidateBeforeCall( + projectId, region, createManagementNetworkRoutePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new network routes. (asynchronously) Create one or several new network routes in a - * network area. + * Create new management network routes. (asynchronously) Create one or several new routes in a + * management network. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param createNetworkAreaRoutePayload Request an addition of routes to an area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createManagementNetworkRoutePayload Request an addition of routes to a management + * network. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -3090,7 +3398,7 @@ public ApiResponse createNetworkAreaRouteWithHttpInfo( * * * - * + * * * * @@ -3099,27 +3407,28 @@ public ApiResponse createNetworkAreaRouteWithHttpInfo( * *
Response Details
Status Code Description Response Headers
202 Create request for network routes has been accepted. -
201 Management network route created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNetworkAreaRouteAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload, - final ApiCallback _callback) + public okhttp3.Call createManagementNetworkRouteAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + CreateManagementNetworkRoutePayload createManagementNetworkRoutePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createNetworkAreaRouteValidateBeforeCall( - organizationId, areaId, createNetworkAreaRoutePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + createManagementNetworkRouteValidateBeforeCall( + projectId, region, createManagementNetworkRoutePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createNic + * Build call for createNetwork * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param createNicPayload Request a network interface creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkPayload Request a network creation. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3127,20 +3436,19 @@ public okhttp3.Call createNetworkAreaRouteAsync( * * * - * + * * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Network interface was created successfully. -
202 Network create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNicCall( + public okhttp3.Call createNetworkCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull CreateNicPayload createNicPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -3156,17 +3464,17 @@ public okhttp3.Call createNicCall( basePath = null; } - Object localVarPostBody = createNicPayload; + Object localVarPostBody = createNetworkPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}/nics" + "/v2beta1/projects/{projectId}/regions/{region}/networks" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -3203,106 +3511,113 @@ public okhttp3.Call createNicCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createNicValidateBeforeCall( + private okhttp3.Call createNetworkValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull CreateNicPayload createNicPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createNic(Async)"); + "Missing the required parameter 'projectId' when calling createNetwork(Async)"); } - // verify the required parameter 'networkId' is set - if (networkId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'networkId' when calling createNic(Async)"); + "Missing the required parameter 'region' when calling createNetwork(Async)"); } - // verify the required parameter 'createNicPayload' is set - if (createNicPayload == null) { + // verify the required parameter 'createNetworkPayload' is set + if (createNetworkPayload == null) { throw new ApiException( - "Missing the required parameter 'createNicPayload' when calling createNic(Async)"); + "Missing the required parameter 'createNetworkPayload' when calling createNetwork(Async)"); } - return createNicCall(projectId, networkId, createNicPayload, _callback); + return createNetworkCall(projectId, region, createNetworkPayload, _callback); } /** - * Create new network interface. Create a new network interface in a project. + * Create new network. Create a new network in a project. `nameservers` will be filled + * from `defaultNameservers` of the respective area if not specified. If the project + * has `internetAccess` enabled and this is the first network in the project this + * might incur cost. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param createNicPayload Request a network interface creation. (required) - * @return NIC + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkPayload Request a network creation. (required) + * @return Network * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Network interface was created successfully. -
202 Network create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NIC createNic( + public Network createNetwork( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull CreateNicPayload createNicPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload) throws ApiException { - ApiResponse localVarResp = - createNicWithHttpInfo(projectId, networkId, createNicPayload); + ApiResponse localVarResp = + createNetworkWithHttpInfo(projectId, region, createNetworkPayload); return localVarResp.getData(); } /** - * Create new network interface. Create a new network interface in a project. + * Create new network. Create a new network in a project. `nameservers` will be filled + * from `defaultNameservers` of the respective area if not specified. If the project + * has `internetAccess` enabled and this is the first network in the project this + * might incur cost. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param createNicPayload Request a network interface creation. (required) - * @return ApiResponse<NIC> + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkPayload Request a network creation. (required) + * @return ApiResponse<Network> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Network interface was created successfully. -
202 Network create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createNicWithHttpInfo( + public ApiResponse createNetworkWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull CreateNicPayload createNicPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload) throws ApiException { okhttp3.Call localVarCall = - createNicValidateBeforeCall(projectId, networkId, createNicPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + createNetworkValidateBeforeCall(projectId, region, createNetworkPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new network interface. (asynchronously) Create a new network interface in a project. + * Create new network. (asynchronously) Create a new network in a project. + * `nameservers` will be filled from `defaultNameservers` of the respective + * area if not specified. If the project has `internetAccess` enabled and this is the + * first network in the project this might incur cost. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param createNicPayload Request a network interface creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkPayload Request a network creation. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -3311,35 +3626,34 @@ public ApiResponse createNicWithHttpInfo( * * * - * + * * * * * * - * * *
Response Details
Status Code Description Response Headers
201 Network interface was created successfully. -
202 Network create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createNicAsync( + public okhttp3.Call createNetworkAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull CreateNicPayload createNicPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkPayload createNetworkPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createNicValidateBeforeCall(projectId, networkId, createNicPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + createNetworkValidateBeforeCall(projectId, region, createNetworkPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createPublicIP + * Build call for createNetworkArea * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createPublicIPPayload Request a public IP creation. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param createNetworkAreaPayload Request an Area creation. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3347,18 +3661,17 @@ public okhttp3.Call createNicAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 The public IP has been created. -
201 Area has been successfully created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createPublicIPCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload, + public okhttp3.Call createNetworkAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -3374,14 +3687,14 @@ public okhttp3.Call createPublicIPCall( basePath = null; } - Object localVarPostBody = createPublicIPPayload; + Object localVarPostBody = createNetworkAreaPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/public-ips" + "/v2beta1/organizations/{organizationId}/network-areas" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -3418,92 +3731,91 @@ public okhttp3.Call createPublicIPCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createPublicIPValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload, + private okhttp3.Call createNetworkAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createPublicIP(Async)"); + "Missing the required parameter 'organizationId' when calling createNetworkArea(Async)"); } - // verify the required parameter 'createPublicIPPayload' is set - if (createPublicIPPayload == null) { + // verify the required parameter 'createNetworkAreaPayload' is set + if (createNetworkAreaPayload == null) { throw new ApiException( - "Missing the required parameter 'createPublicIPPayload' when calling createPublicIP(Async)"); + "Missing the required parameter 'createNetworkAreaPayload' when calling createNetworkArea(Async)"); } - return createPublicIPCall(projectId, createPublicIPPayload, _callback); + return createNetworkAreaCall(organizationId, createNetworkAreaPayload, _callback); } /** - * Create new public IP. Create a new public IP in a project. + * Create new network area in an organization. Create a new network area in an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createPublicIPPayload Request a public IP creation. (required) - * @return PublicIp + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param createNetworkAreaPayload Request an Area creation. (required) + * @return NetworkArea * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 The public IP has been created. -
201 Area has been successfully created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public PublicIp createPublicIP( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload) + public NetworkArea createNetworkArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload) throws ApiException { - ApiResponse localVarResp = - createPublicIPWithHttpInfo(projectId, createPublicIPPayload); + ApiResponse localVarResp = + createNetworkAreaWithHttpInfo(organizationId, createNetworkAreaPayload); return localVarResp.getData(); } /** - * Create new public IP. Create a new public IP in a project. + * Create new network area in an organization. Create a new network area in an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createPublicIPPayload Request a public IP creation. (required) - * @return ApiResponse<PublicIp> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param createNetworkAreaPayload Request an Area creation. (required) + * @return ApiResponse<NetworkArea> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 The public IP has been created. -
201 Area has been successfully created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createPublicIPWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload) + public ApiResponse createNetworkAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload) throws ApiException { okhttp3.Call localVarCall = - createPublicIPValidateBeforeCall(projectId, createPublicIPPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + createNetworkAreaValidateBeforeCall(organizationId, createNetworkAreaPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new public IP. (asynchronously) Create a new public IP in a project. + * Create new network area in an organization. (asynchronously) Create a new network area in an + * organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createPublicIPPayload Request a public IP creation. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param createNetworkAreaPayload Request an Area creation. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -3512,33 +3824,36 @@ public ApiResponse createPublicIPWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
201 The public IP has been created. -
201 Area has been successfully created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createPublicIPAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload, - final ApiCallback _callback) + public okhttp3.Call createNetworkAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull CreateNetworkAreaPayload createNetworkAreaPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createPublicIPValidateBeforeCall(projectId, createPublicIPPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + createNetworkAreaValidateBeforeCall( + organizationId, createNetworkAreaPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for createSecurityGroup + * Build call for createNetworkAreaRange * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createSecurityGroupPayload Request a security group creation. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkAreaRangePayload Request an addition of network ranges to an area. + * (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3546,17 +3861,20 @@ public okhttp3.Call createPublicIPAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Security group create has been accepted. -
201 Adding network ranges was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createSecurityGroupCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload, + public okhttp3.Call createNetworkAreaRangeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -3572,14 +3890,20 @@ public okhttp3.Call createSecurityGroupCall( basePath = null; } - Object localVarPostBody = createSecurityGroupPayload; + Object localVarPostBody = createNetworkAreaRangePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/network-ranges" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -3616,90 +3940,4288 @@ public okhttp3.Call createSecurityGroupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createSecurityGroupValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload, + private okhttp3.Call createNetworkAreaRangeValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createSecurityGroup(Async)"); + "Missing the required parameter 'organizationId' when calling createNetworkAreaRange(Async)"); } - // verify the required parameter 'createSecurityGroupPayload' is set - if (createSecurityGroupPayload == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'createSecurityGroupPayload' when calling createSecurityGroup(Async)"); + "Missing the required parameter 'areaId' when calling createNetworkAreaRange(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createNetworkAreaRange(Async)"); + } + + // verify the required parameter 'createNetworkAreaRangePayload' is set + if (createNetworkAreaRangePayload == null) { + throw new ApiException( + "Missing the required parameter 'createNetworkAreaRangePayload' when calling createNetworkAreaRange(Async)"); } - return createSecurityGroupCall(projectId, createSecurityGroupPayload, _callback); + return createNetworkAreaRangeCall( + organizationId, areaId, region, createNetworkAreaRangePayload, _callback); } /** - * Create new security group. Create a new security group in a project. + * Create new network range in a network area. Create a new network range in an existing network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createSecurityGroupPayload Request a security group creation. (required) - * @return SecurityGroup + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkAreaRangePayload Request an addition of network ranges to an area. + * (required) + * @return NetworkRangeListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Security group create has been accepted. -
201 Adding network ranges was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public SecurityGroup createSecurityGroup( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload) + public NetworkRangeListResponse createNetworkAreaRange( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload) throws ApiException { - ApiResponse localVarResp = - createSecurityGroupWithHttpInfo(projectId, createSecurityGroupPayload); + ApiResponse localVarResp = + createNetworkAreaRangeWithHttpInfo( + organizationId, areaId, region, createNetworkAreaRangePayload); return localVarResp.getData(); } /** - * Create new security group. Create a new security group in a project. + * Create new network range in a network area. Create a new network range in an existing network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createSecurityGroupPayload Request a security group creation. (required) - * @return ApiResponse<SecurityGroup> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkAreaRangePayload Request an addition of network ranges to an area. + * (required) + * @return ApiResponse<NetworkRangeListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
201 Security group create has been accepted. -
201 Adding network ranges was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createSecurityGroupWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload) + public ApiResponse createNetworkAreaRangeWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload) throws ApiException { okhttp3.Call localVarCall = - createSecurityGroupValidateBeforeCall(projectId, createSecurityGroupPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + createNetworkAreaRangeValidateBeforeCall( + organizationId, areaId, region, createNetworkAreaRangePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Create new security group. (asynchronously) Create a new security group in a project. + * Create new network range in a network area. (asynchronously) Create a new network range in an + * existing network area. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkAreaRangePayload Request an addition of network ranges to an area. + * (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Adding network ranges was successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createNetworkAreaRangeAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRangePayload createNetworkAreaRangePayload, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + createNetworkAreaRangeValidateBeforeCall( + organizationId, areaId, region, createNetworkAreaRangePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + + /** + * Build call for createNetworkAreaRoute + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkAreaRoutePayload Request an addition of routes to an area. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Create request for network routes accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createNetworkAreaRouteCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = createNetworkAreaRoutePayload; + + // create path and map variables + String localVarPath = + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routes" + .replace( + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {"application/json"}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "POST", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createNetworkAreaRouteValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { + throw new ApiException( + "Missing the required parameter 'organizationId' when calling createNetworkAreaRoute(Async)"); + } + + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling createNetworkAreaRoute(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createNetworkAreaRoute(Async)"); + } + + // verify the required parameter 'createNetworkAreaRoutePayload' is set + if (createNetworkAreaRoutePayload == null) { + throw new ApiException( + "Missing the required parameter 'createNetworkAreaRoutePayload' when calling createNetworkAreaRoute(Async)"); + } + + return createNetworkAreaRouteCall( + organizationId, areaId, region, createNetworkAreaRoutePayload, _callback); + } + + /** + * Create new network routes. Create one or several new network routes in a network area. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkAreaRoutePayload Request an addition of routes to an area. (required) + * @return RouteListResponse + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Create request for network routes accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public RouteListResponse createNetworkAreaRoute( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload) + throws ApiException { + ApiResponse localVarResp = + createNetworkAreaRouteWithHttpInfo( + organizationId, areaId, region, createNetworkAreaRoutePayload); + return localVarResp.getData(); + } + + /** + * Create new network routes. Create one or several new network routes in a network area. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkAreaRoutePayload Request an addition of routes to an area. (required) + * @return ApiResponse<RouteListResponse> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Create request for network routes accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse createNetworkAreaRouteWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload) + throws ApiException { + okhttp3.Call localVarCall = + createNetworkAreaRouteValidateBeforeCall( + organizationId, areaId, region, createNetworkAreaRoutePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create new network routes. (asynchronously) Create one or several new network routes in a + * network area. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createNetworkAreaRoutePayload Request an addition of routes to an area. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Create request for network routes accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createNetworkAreaRouteAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + createNetworkAreaRouteValidateBeforeCall( + organizationId, areaId, region, createNetworkAreaRoutePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + + /** + * Build call for createNic + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param createNicPayload Request a network interface creation. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Network interface was created successfully. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createNicCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull CreateNicPayload createNicPayload, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = createNicPayload; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/networks/{networkId}/nics" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {"application/json"}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "POST", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createNicValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull CreateNicPayload createNicPayload, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling createNic(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createNic(Async)"); + } + + // verify the required parameter 'networkId' is set + if (networkId == null) { + throw new ApiException( + "Missing the required parameter 'networkId' when calling createNic(Async)"); + } + + // verify the required parameter 'createNicPayload' is set + if (createNicPayload == null) { + throw new ApiException( + "Missing the required parameter 'createNicPayload' when calling createNic(Async)"); + } + + return createNicCall(projectId, region, networkId, createNicPayload, _callback); + } + + /** + * Create new network interface. Create a new network interface in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param createNicPayload Request a network interface creation. (required) + * @return NIC + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Network interface was created successfully. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public NIC createNic( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull CreateNicPayload createNicPayload) + throws ApiException { + ApiResponse localVarResp = + createNicWithHttpInfo(projectId, region, networkId, createNicPayload); + return localVarResp.getData(); + } + + /** + * Create new network interface. Create a new network interface in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param createNicPayload Request a network interface creation. (required) + * @return ApiResponse<NIC> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Network interface was created successfully. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse createNicWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull CreateNicPayload createNicPayload) + throws ApiException { + okhttp3.Call localVarCall = + createNicValidateBeforeCall(projectId, region, networkId, createNicPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create new network interface. (asynchronously) Create a new network interface in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param createNicPayload Request a network interface creation. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Network interface was created successfully. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createNicAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull CreateNicPayload createNicPayload, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + createNicValidateBeforeCall( + projectId, region, networkId, createNicPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + + /** + * Build call for createPublicIP + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createPublicIPPayload Request a public IP creation. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 The public IP has been created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createPublicIPCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = createPublicIPPayload; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/public-ips" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {"application/json"}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "POST", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createPublicIPValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling createPublicIP(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createPublicIP(Async)"); + } + + // verify the required parameter 'createPublicIPPayload' is set + if (createPublicIPPayload == null) { + throw new ApiException( + "Missing the required parameter 'createPublicIPPayload' when calling createPublicIP(Async)"); + } + + return createPublicIPCall(projectId, region, createPublicIPPayload, _callback); + } + + /** + * Create new public IP. Create a new public IP in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createPublicIPPayload Request a public IP creation. (required) + * @return PublicIp + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 The public IP has been created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public PublicIp createPublicIP( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload) + throws ApiException { + ApiResponse localVarResp = + createPublicIPWithHttpInfo(projectId, region, createPublicIPPayload); + return localVarResp.getData(); + } + + /** + * Create new public IP. Create a new public IP in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createPublicIPPayload Request a public IP creation. (required) + * @return ApiResponse<PublicIp> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 The public IP has been created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse createPublicIPWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload) + throws ApiException { + okhttp3.Call localVarCall = + createPublicIPValidateBeforeCall(projectId, region, createPublicIPPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create new public IP. (asynchronously) Create a new public IP in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createPublicIPPayload Request a public IP creation. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 The public IP has been created. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
429 Too Many Requests. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createPublicIPAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreatePublicIPPayload createPublicIPPayload, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + createPublicIPValidateBeforeCall( + projectId, region, createPublicIPPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + + /** + * Build call for createSecurityGroup + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createSecurityGroupPayload Request a security group creation. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Security group create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createSecurityGroupCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = createSecurityGroupPayload; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/security-groups" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {"application/json"}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "POST", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createSecurityGroupValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling createSecurityGroup(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createSecurityGroup(Async)"); + } + + // verify the required parameter 'createSecurityGroupPayload' is set + if (createSecurityGroupPayload == null) { + throw new ApiException( + "Missing the required parameter 'createSecurityGroupPayload' when calling createSecurityGroup(Async)"); + } + + return createSecurityGroupCall(projectId, region, createSecurityGroupPayload, _callback); + } + + /** + * Create new security group. Create a new security group in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createSecurityGroupPayload Request a security group creation. (required) + * @return SecurityGroup + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Security group create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public SecurityGroup createSecurityGroup( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload) + throws ApiException { + ApiResponse localVarResp = + createSecurityGroupWithHttpInfo(projectId, region, createSecurityGroupPayload); + return localVarResp.getData(); + } + + /** + * Create new security group. Create a new security group in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createSecurityGroupPayload Request a security group creation. (required) + * @return ApiResponse<SecurityGroup> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Security group create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse createSecurityGroupWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload) + throws ApiException { + okhttp3.Call localVarCall = + createSecurityGroupValidateBeforeCall( + projectId, region, createSecurityGroupPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create new security group. (asynchronously) Create a new security group in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createSecurityGroupPayload Request a security group creation. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Security group create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createSecurityGroupAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + createSecurityGroupValidateBeforeCall( + projectId, region, createSecurityGroupPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + + /** + * Build call for createSecurityGroupRule + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param createSecurityGroupRulePayload Request for a security group rule creation. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Security group rule create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createSecurityGroupRuleCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = createSecurityGroupRulePayload; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/security-groups/{securityGroupId}/rules" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {"application/json"}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "POST", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createSecurityGroupRuleValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling createSecurityGroupRule(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createSecurityGroupRule(Async)"); + } + + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupId' when calling createSecurityGroupRule(Async)"); + } + + // verify the required parameter 'createSecurityGroupRulePayload' is set + if (createSecurityGroupRulePayload == null) { + throw new ApiException( + "Missing the required parameter 'createSecurityGroupRulePayload' when calling createSecurityGroupRule(Async)"); + } + + return createSecurityGroupRuleCall( + projectId, region, securityGroupId, createSecurityGroupRulePayload, _callback); + } + + /** + * Create new security group rule. Create a new security group rule in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param createSecurityGroupRulePayload Request for a security group rule creation. (required) + * @return SecurityGroupRule + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Security group rule create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public SecurityGroupRule createSecurityGroupRule( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload) + throws ApiException { + ApiResponse localVarResp = + createSecurityGroupRuleWithHttpInfo( + projectId, region, securityGroupId, createSecurityGroupRulePayload); + return localVarResp.getData(); + } + + /** + * Create new security group rule. Create a new security group rule in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param createSecurityGroupRulePayload Request for a security group rule creation. (required) + * @return ApiResponse<SecurityGroupRule> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Security group rule create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse createSecurityGroupRuleWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload) + throws ApiException { + okhttp3.Call localVarCall = + createSecurityGroupRuleValidateBeforeCall( + projectId, region, securityGroupId, createSecurityGroupRulePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create new security group rule. (asynchronously) Create a new security group rule in a + * project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param createSecurityGroupRulePayload Request for a security group rule creation. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Security group rule create has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createSecurityGroupRuleAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + createSecurityGroupRuleValidateBeforeCall( + projectId, + region, + securityGroupId, + createSecurityGroupRulePayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + + /** + * Build call for createServer + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createServerPayload Request a server creation. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Create request for server accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createServerCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateServerPayload createServerPayload, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = createServerPayload; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/servers" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {"application/json"}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "POST", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createServerValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateServerPayload createServerPayload, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling createServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createServer(Async)"); + } + + // verify the required parameter 'createServerPayload' is set + if (createServerPayload == null) { + throw new ApiException( + "Missing the required parameter 'createServerPayload' when calling createServer(Async)"); + } + + return createServerCall(projectId, region, createServerPayload, _callback); + } + + /** + * Create new server. Create a new server in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createServerPayload Request a server creation. (required) + * @return Server + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Create request for server accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public Server createServer( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateServerPayload createServerPayload) + throws ApiException { + ApiResponse localVarResp = + createServerWithHttpInfo(projectId, region, createServerPayload); + return localVarResp.getData(); + } + + /** + * Create new server. Create a new server in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createServerPayload Request a server creation. (required) + * @return ApiResponse<Server> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Create request for server accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse createServerWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateServerPayload createServerPayload) + throws ApiException { + okhttp3.Call localVarCall = + createServerValidateBeforeCall(projectId, region, createServerPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create new server. (asynchronously) Create a new server in a project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createServerPayload Request a server creation. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Create request for server accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createServerAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateServerPayload createServerPayload, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + createServerValidateBeforeCall(projectId, region, createServerPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + + /** + * Build call for createVolume + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createVolumePayload Request a volume creation. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Create request for volume accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createVolumeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateVolumePayload createVolumePayload, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = createVolumePayload; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/volumes" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {"application/json"}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "POST", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call createVolumeValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateVolumePayload createVolumePayload, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling createVolume(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling createVolume(Async)"); + } + + // verify the required parameter 'createVolumePayload' is set + if (createVolumePayload == null) { + throw new ApiException( + "Missing the required parameter 'createVolumePayload' when calling createVolume(Async)"); + } + + return createVolumeCall(projectId, region, createVolumePayload, _callback); + } + + /** + * Create new volume. Create a new volume in a project. If a volume source is not provided, an + * empty volume will be created. The size property is required if no source or an image source + * is provided. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createVolumePayload Request a volume creation. (required) + * @return Volume + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Create request for volume accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public Volume createVolume( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateVolumePayload createVolumePayload) + throws ApiException { + ApiResponse localVarResp = + createVolumeWithHttpInfo(projectId, region, createVolumePayload); + return localVarResp.getData(); + } + + /** + * Create new volume. Create a new volume in a project. If a volume source is not provided, an + * empty volume will be created. The size property is required if no source or an image source + * is provided. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createVolumePayload Request a volume creation. (required) + * @return ApiResponse<Volume> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Create request for volume accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse createVolumeWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateVolumePayload createVolumePayload) + throws ApiException { + okhttp3.Call localVarCall = + createVolumeValidateBeforeCall(projectId, region, createVolumePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); + } + + /** + * Create new volume. (asynchronously) Create a new volume in a project. If a volume source is + * not provided, an empty volume will be created. The size property is required if no source or + * an image source is provided. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param createVolumePayload Request a volume creation. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
201 Create request for volume accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call createVolumeAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull CreateVolumePayload createVolumePayload, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + createVolumeValidateBeforeCall(projectId, region, createVolumePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + return localVarCall; + } + + /** + * Build call for deallocateServer + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Server deallocation request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deallocateServerCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/deallocate" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "POST", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deallocateServerValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling deallocateServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deallocateServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling deallocateServer(Async)"); + } + + return deallocateServerCall(projectId, region, serverId, _callback); + } + + /** + * Deallocate an existing server. Deallocate an existing server. The server will be removed from + * the hypervisor so only the volume will be billed. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Server deallocation request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deallocateServer( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) + throws ApiException { + deallocateServerWithHttpInfo(projectId, region, serverId); + } + + /** + * Deallocate an existing server. Deallocate an existing server. The server will be removed from + * the hypervisor so only the volume will be billed. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Server deallocation request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deallocateServerWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) + throws ApiException { + okhttp3.Call localVarCall = + deallocateServerValidateBeforeCall(projectId, region, serverId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Deallocate an existing server. (asynchronously) Deallocate an existing server. The server + * will be removed from the hypervisor so only the volume will be billed. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Server deallocation request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deallocateServerAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deallocateServerValidateBeforeCall(projectId, region, serverId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteAffinityGroup + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for an server group was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteAffinityGroupCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/affinity-groups/{affinityGroupId}" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "affinityGroupId" + "}", + localVarApiClient.escapeString(affinityGroupId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteAffinityGroupValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling deleteAffinityGroup(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteAffinityGroup(Async)"); + } + + // verify the required parameter 'affinityGroupId' is set + if (affinityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'affinityGroupId' when calling deleteAffinityGroup(Async)"); + } + + return deleteAffinityGroupCall(projectId, region, affinityGroupId, _callback); + } + + /** + * Delete a affinity group in a project. Delete a affinity group in the given project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for an server group was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteAffinityGroup( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId) + throws ApiException { + deleteAffinityGroupWithHttpInfo(projectId, region, affinityGroupId); + } + + /** + * Delete a affinity group in a project. Delete a affinity group in the given project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for an server group was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteAffinityGroupWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId) + throws ApiException { + okhttp3.Call localVarCall = + deleteAffinityGroupValidateBeforeCall(projectId, region, affinityGroupId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete a affinity group in a project. (asynchronously) Delete a affinity group in the given + * project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for an server group was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteAffinityGroupAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteAffinityGroupValidateBeforeCall( + projectId, region, affinityGroupId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteBackup + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param force Force action. (optional, default to false) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Backup delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteBackupCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nullable Boolean force, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/backups/{backupId}" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "backupId" + "}", + localVarApiClient.escapeString(backupId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + if (force != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("force", force)); + } + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteBackupValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nullable Boolean force, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling deleteBackup(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteBackup(Async)"); + } + + // verify the required parameter 'backupId' is set + if (backupId == null) { + throw new ApiException( + "Missing the required parameter 'backupId' when calling deleteBackup(Async)"); + } + + return deleteBackupCall(projectId, region, backupId, force, _callback); + } + + /** + * Delete a backup. Delete a backup that is part of the project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param force Force action. (optional, default to false) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Backup delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteBackup( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nullable Boolean force) + throws ApiException { + deleteBackupWithHttpInfo(projectId, region, backupId, force); + } + + /** + * Delete a backup. Delete a backup that is part of the project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param force Force action. (optional, default to false) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Backup delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteBackupWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nullable Boolean force) + throws ApiException { + okhttp3.Call localVarCall = + deleteBackupValidateBeforeCall(projectId, region, backupId, force, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete a backup. (asynchronously) Delete a backup that is part of the project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param force Force action. (optional, default to false) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Backup delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteBackupAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nullable Boolean force, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteBackupValidateBeforeCall(projectId, region, backupId, force, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteImage + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteImageCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteImageValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling deleteImage(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteImage(Async)"); + } + + // verify the required parameter 'imageId' is set + if (imageId == null) { + throw new ApiException( + "Missing the required parameter 'imageId' when calling deleteImage(Async)"); + } + + return deleteImageCall(projectId, region, imageId, _callback); + } + + /** + * Delete an Image. Delete an image that is part of the project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteImage( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId) + throws ApiException { + deleteImageWithHttpInfo(projectId, region, imageId); + } + + /** + * Delete an Image. Delete an image that is part of the project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteImageWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId) + throws ApiException { + okhttp3.Call localVarCall = deleteImageValidateBeforeCall(projectId, region, imageId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete an Image. (asynchronously) Delete an image that is part of the project. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteImageAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteImageValidateBeforeCall(projectId, region, imageId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteImageShare + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image share removed. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteImageShareCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}/share" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteImageShareValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling deleteImageShare(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteImageShare(Async)"); + } + + // verify the required parameter 'imageId' is set + if (imageId == null) { + throw new ApiException( + "Missing the required parameter 'imageId' when calling deleteImageShare(Async)"); + } + + return deleteImageShareCall(projectId, region, imageId, _callback); + } + + /** + * Remove image share. Remove the image share. New scope will be local. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image share removed. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteImageShare( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId) + throws ApiException { + deleteImageShareWithHttpInfo(projectId, region, imageId); + } + + /** + * Remove image share. Remove the image share. New scope will be local. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image share removed. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteImageShareWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId) + throws ApiException { + okhttp3.Call localVarCall = + deleteImageShareValidateBeforeCall(projectId, region, imageId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Remove image share. (asynchronously) Remove the image share. New scope will be local. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image share removed. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteImageShareAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteImageShareValidateBeforeCall(projectId, region, imageId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteImageShareConsumer + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image + * share. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image share consumer removed. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteImageShareConsumerCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}/share/{consumerProjectId}" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())) + .replace( + "{" + "consumerProjectId" + "}", + localVarApiClient.escapeString(consumerProjectId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteImageShareConsumerValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling deleteImageShareConsumer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteImageShareConsumer(Async)"); + } + + // verify the required parameter 'imageId' is set + if (imageId == null) { + throw new ApiException( + "Missing the required parameter 'imageId' when calling deleteImageShareConsumer(Async)"); + } + + // verify the required parameter 'consumerProjectId' is set + if (consumerProjectId == null) { + throw new ApiException( + "Missing the required parameter 'consumerProjectId' when calling deleteImageShareConsumer(Async)"); + } + + return deleteImageShareConsumerCall( + projectId, region, imageId, consumerProjectId, _callback); + } + + /** + * Remove an image share consumer. Remove consumer from a shared image. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image + * share. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image share consumer removed. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteImageShareConsumer( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId) + throws ApiException { + deleteImageShareConsumerWithHttpInfo(projectId, region, imageId, consumerProjectId); + } + + /** + * Remove an image share consumer. Remove consumer from a shared image. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image + * share. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image share consumer removed. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteImageShareConsumerWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId) + throws ApiException { + okhttp3.Call localVarCall = + deleteImageShareConsumerValidateBeforeCall( + projectId, region, imageId, consumerProjectId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Remove an image share consumer. (asynchronously) Remove consumer from a shared image. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image + * share. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Image share consumer removed. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteImageShareConsumerAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteImageShareConsumerValidateBeforeCall( + projectId, region, imageId, consumerProjectId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteKeyPair + * + * @param keypairName The name of an SSH keypair. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for an SSH keypair was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteKeyPairCall( + @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/keypairs/{keypairName}" + .replace( + "{" + "keypairName" + "}", + localVarApiClient.escapeString(keypairName.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteKeyPairValidateBeforeCall( + @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'keypairName' is set + if (keypairName == null) { + throw new ApiException( + "Missing the required parameter 'keypairName' when calling deleteKeyPair(Async)"); + } + + return deleteKeyPairCall(keypairName, _callback); + } + + /** + * Delete an SSH keypair. Delete an SSH keypair from a user. + * + * @param keypairName The name of an SSH keypair. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for an SSH keypair was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteKeyPair(@javax.annotation.Nonnull String keypairName) throws ApiException { + deleteKeyPairWithHttpInfo(keypairName); + } + + /** + * Delete an SSH keypair. Delete an SSH keypair from a user. + * + * @param keypairName The name of an SSH keypair. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for an SSH keypair was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteKeyPairWithHttpInfo(@javax.annotation.Nonnull String keypairName) + throws ApiException { + okhttp3.Call localVarCall = deleteKeyPairValidateBeforeCall(keypairName, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete an SSH keypair. (asynchronously) Delete an SSH keypair from a user. + * + * @param keypairName The name of an SSH keypair. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for an SSH keypair was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteKeyPairAsync( + @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = deleteKeyPairValidateBeforeCall(keypairName, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteManagementNetworkRoute + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for the management network route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteManagementNetworkRouteCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/management-network/routes/{routeId}" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteManagementNetworkRouteValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling deleteManagementNetworkRoute(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteManagementNetworkRoute(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { + throw new ApiException( + "Missing the required parameter 'routeId' when calling deleteManagementNetworkRoute(Async)"); + } + + return deleteManagementNetworkRouteCall(projectId, region, routeId, _callback); + } + + /** + * Delete a management network route. Delete a management network route and its labels. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for the management network route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteManagementNetworkRoute( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId) + throws ApiException { + deleteManagementNetworkRouteWithHttpInfo(projectId, region, routeId); + } + + /** + * Delete a management network route. Delete a management network route and its labels. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for the management network route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteManagementNetworkRouteWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId) + throws ApiException { + okhttp3.Call localVarCall = + deleteManagementNetworkRouteValidateBeforeCall(projectId, region, routeId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete a management network route. (asynchronously) Delete a management network route and its + * labels. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for the management network route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteManagementNetworkRouteAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteManagementNetworkRouteValidateBeforeCall( + projectId, region, routeId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteNetwork + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for network has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteNetworkCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/networks/{networkId}" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteNetworkValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling deleteNetwork(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteNetwork(Async)"); + } + + // verify the required parameter 'networkId' is set + if (networkId == null) { + throw new ApiException( + "Missing the required parameter 'networkId' when calling deleteNetwork(Async)"); + } + + return deleteNetworkCall(projectId, region, networkId, _callback); + } + + /** + * Delete network. Delete a network. If the network is still in use, the deletion will fail. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for network has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteNetwork( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId) + throws ApiException { + deleteNetworkWithHttpInfo(projectId, region, networkId); + } + + /** + * Delete network. Delete a network. If the network is still in use, the deletion will fail. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for network has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteNetworkWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId) + throws ApiException { + okhttp3.Call localVarCall = + deleteNetworkValidateBeforeCall(projectId, region, networkId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete network. (asynchronously) Delete a network. If the network is still in use, the + * deletion will fail. + * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for network has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteNetworkAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteNetworkValidateBeforeCall(projectId, region, networkId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteNetworkArea + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for area has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteNetworkAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}" + .replace( + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteNetworkAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { + throw new ApiException( + "Missing the required parameter 'organizationId' when calling deleteNetworkArea(Async)"); + } + + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling deleteNetworkArea(Async)"); + } + + return deleteNetworkAreaCall(organizationId, areaId, _callback); + } + + /** + * Delete a network area. Delete an existing network area in an organization. This is only + * possible if no projects are using the area anymore. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for area has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteNetworkArea( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + throws ApiException { + deleteNetworkAreaWithHttpInfo(organizationId, areaId); + } + + /** + * Delete a network area. Delete an existing network area in an organization. This is only + * possible if no projects are using the area anymore. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for area has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteNetworkAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + throws ApiException { + okhttp3.Call localVarCall = + deleteNetworkAreaValidateBeforeCall(organizationId, areaId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete a network area. (asynchronously) Delete an existing network area in an organization. + * This is only possible if no projects are using the area anymore. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
204 Delete request for area has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteNetworkAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteNetworkAreaValidateBeforeCall(organizationId, areaId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteNetworkAreaRange + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for network range accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteNetworkAreaRangeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/network-ranges/{networkRangeId}" + .replace( + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkRangeId" + "}", + localVarApiClient.escapeString(networkRangeId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteNetworkAreaRangeValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { + throw new ApiException( + "Missing the required parameter 'organizationId' when calling deleteNetworkAreaRange(Async)"); + } + + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling deleteNetworkAreaRange(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteNetworkAreaRange(Async)"); + } + + // verify the required parameter 'networkRangeId' is set + if (networkRangeId == null) { + throw new ApiException( + "Missing the required parameter 'networkRangeId' when calling deleteNetworkAreaRange(Async)"); + } + + return deleteNetworkAreaRangeCall( + organizationId, areaId, region, networkRangeId, _callback); + } + + /** + * Delete a network range. Delete a network range of a network area. The deletion will fail if + * the network range is still used. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for network range accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteNetworkAreaRange( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId) + throws ApiException { + deleteNetworkAreaRangeWithHttpInfo(organizationId, areaId, region, networkRangeId); + } + + /** + * Delete a network range. Delete a network range of a network area. The deletion will fail if + * the network range is still used. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for network range accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteNetworkAreaRangeWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId) + throws ApiException { + okhttp3.Call localVarCall = + deleteNetworkAreaRangeValidateBeforeCall( + organizationId, areaId, region, networkRangeId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete a network range. (asynchronously) Delete a network range of a network area. The + * deletion will fail if the network range is still used. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @param _callback The callback to be executed when the API call finishes + * @return The request call + * @throws ApiException If fail to process the API call, e.g. serializing the request body + * object + * @http.response.details + * + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for network range accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteNetworkAreaRangeAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId, + final ApiCallback _callback) + throws ApiException { + + okhttp3.Call localVarCall = + deleteNetworkAreaRangeValidateBeforeCall( + organizationId, areaId, region, networkRangeId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); + return localVarCall; + } + + /** + * Build call for deleteNetworkAreaRoute + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param _callback Callback for upload/download progress + * @return Call to execute + * @throws ApiException If fail to serialize the request body object + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for the network route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public okhttp3.Call deleteNetworkAreaRouteCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) + throws ApiException { + String basePath = null; + // Operation Servers + String[] localBasePaths = new String[] {}; + + // Determine Base Path to Use + if (localCustomBaseUrl != null) { + basePath = localCustomBaseUrl; + } else if (localBasePaths.length > 0) { + basePath = localBasePaths[localHostIndex]; + } else { + basePath = null; + } + + Object localVarPostBody = null; + + // create path and map variables + String localVarPath = + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routes/{routeId}" + .replace( + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); + + List localVarQueryParams = new ArrayList(); + List localVarCollectionQueryParams = new ArrayList(); + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); + + final String[] localVarAccepts = {"application/json"}; + final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); + if (localVarAccept != null) { + localVarHeaderParams.put("Accept", localVarAccept); + } + + final String[] localVarContentTypes = {}; + final String localVarContentType = + localVarApiClient.selectHeaderContentType(localVarContentTypes); + if (localVarContentType != null) { + localVarHeaderParams.put("Content-Type", localVarContentType); + } + + String[] localVarAuthNames = new String[] {}; + return localVarApiClient.buildCall( + basePath, + localVarPath, + "DELETE", + localVarQueryParams, + localVarCollectionQueryParams, + localVarPostBody, + localVarHeaderParams, + localVarCookieParams, + localVarFormParams, + localVarAuthNames, + _callback); + } + + @SuppressWarnings("rawtypes") + private okhttp3.Call deleteNetworkAreaRouteValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { + throw new ApiException( + "Missing the required parameter 'organizationId' when calling deleteNetworkAreaRoute(Async)"); + } + + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling deleteNetworkAreaRoute(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteNetworkAreaRoute(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { + throw new ApiException( + "Missing the required parameter 'routeId' when calling deleteNetworkAreaRoute(Async)"); + } + + return deleteNetworkAreaRouteCall(organizationId, areaId, region, routeId, _callback); + } + + /** + * Delete a network route. Delete a network route of a network area. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for the network route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public void deleteNetworkAreaRoute( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId) + throws ApiException { + deleteNetworkAreaRouteWithHttpInfo(organizationId, areaId, region, routeId); + } + + /** + * Delete a network route. Delete a network route of a network area. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return ApiResponse<Void> + * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the + * response body + * @http.response.details + * + * + * + * + * + * + * + * + * + *
Response Details
Status Code Description Response Headers
202 Delete request for the network route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
+ */ + public ApiResponse deleteNetworkAreaRouteWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId) + throws ApiException { + okhttp3.Call localVarCall = + deleteNetworkAreaRouteValidateBeforeCall( + organizationId, areaId, region, routeId, null); + return localVarApiClient.execute(localVarCall); + } + + /** + * Delete a network route. (asynchronously) Delete a network route of a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createSecurityGroupPayload Request a security group creation. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -3708,7 +8230,7 @@ public ApiResponse createSecurityGroupWithHttpInfo( * * * - * + * * * * @@ -3716,26 +8238,28 @@ public ApiResponse createSecurityGroupWithHttpInfo( * *
Response Details
Status Code Description Response Headers
201 Security group create has been accepted. -
202 Delete request for the network route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createSecurityGroupAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSecurityGroupPayload createSecurityGroupPayload, - final ApiCallback _callback) + public okhttp3.Call deleteNetworkAreaRouteAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createSecurityGroupValidateBeforeCall( - projectId, createSecurityGroupPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + deleteNetworkAreaRouteValidateBeforeCall( + organizationId, areaId, region, routeId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for createSecurityGroupRule + * Build call for deleteNic * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param createSecurityGroupRulePayload Request for a security group rule creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3743,7 +8267,7 @@ public okhttp3.Call createSecurityGroupAsync( * * * - * + * * * * @@ -3751,10 +8275,11 @@ public okhttp3.Call createSecurityGroupAsync( * *
Response Details
Status Code Description Response Headers
201 Security group rule create has been accepted. -
204 Network interface delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createSecurityGroupRuleCall( + public okhttp3.Call deleteNicCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -3770,17 +8295,23 @@ public okhttp3.Call createSecurityGroupRuleCall( basePath = null; } - Object localVarPostBody = createSecurityGroupRulePayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}/rules" + "/v2beta1/projects/{projectId}/regions/{region}/networks/{networkId}/nics/{nicId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())) + .replace( + "{" + "nicId" + "}", + localVarApiClient.escapeString(nicId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -3794,7 +8325,7 @@ public okhttp3.Call createSecurityGroupRuleCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -3805,7 +8336,7 @@ public okhttp3.Call createSecurityGroupRuleCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -3817,48 +8348,54 @@ public okhttp3.Call createSecurityGroupRuleCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createSecurityGroupRuleValidateBeforeCall( + private okhttp3.Call deleteNicValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createSecurityGroupRule(Async)"); + "Missing the required parameter 'projectId' when calling deleteNic(Async)"); } - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling createSecurityGroupRule(Async)"); + "Missing the required parameter 'region' when calling deleteNic(Async)"); } - // verify the required parameter 'createSecurityGroupRulePayload' is set - if (createSecurityGroupRulePayload == null) { + // verify the required parameter 'networkId' is set + if (networkId == null) { throw new ApiException( - "Missing the required parameter 'createSecurityGroupRulePayload' when calling createSecurityGroupRule(Async)"); + "Missing the required parameter 'networkId' when calling deleteNic(Async)"); } - return createSecurityGroupRuleCall( - projectId, securityGroupId, createSecurityGroupRulePayload, _callback); + // verify the required parameter 'nicId' is set + if (nicId == null) { + throw new ApiException( + "Missing the required parameter 'nicId' when calling deleteNic(Async)"); + } + + return deleteNicCall(projectId, region, networkId, nicId, _callback); } /** - * Create new security group rule. Create a new security group rule in a project. + * Delete a network interface. Delete a network interface that is part of the project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param createSecurityGroupRulePayload Request for a security group rule creation. (required) - * @return SecurityGroupRule + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -3866,31 +8403,30 @@ private okhttp3.Call createSecurityGroupRuleValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
201 Security group rule create has been accepted. -
204 Network interface delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public SecurityGroupRule createSecurityGroupRule( + public void deleteNic( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId) throws ApiException { - ApiResponse localVarResp = - createSecurityGroupRuleWithHttpInfo( - projectId, securityGroupId, createSecurityGroupRulePayload); - return localVarResp.getData(); + deleteNicWithHttpInfo(projectId, region, networkId, nicId); } /** - * Create new security group rule. Create a new security group rule in a project. + * Delete a network interface. Delete a network interface that is part of the project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param createSecurityGroupRulePayload Request for a security group rule creation. (required) - * @return ApiResponse<SecurityGroupRule> + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -3898,25 +8434,25 @@ public SecurityGroupRule createSecurityGroupRule( * *
Response Details
Status Code Description Response Headers
201 Security group rule create has been accepted. -
204 Network interface delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createSecurityGroupRuleWithHttpInfo( + public ApiResponse deleteNicWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId) throws ApiException { okhttp3.Call localVarCall = - createSecurityGroupRuleValidateBeforeCall( - projectId, securityGroupId, createSecurityGroupRulePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + deleteNicValidateBeforeCall(projectId, region, networkId, nicId, null); + return localVarApiClient.execute(localVarCall); } /** - * Create new security group rule. (asynchronously) Create a new security group rule in a + * Delete a network interface. (asynchronously) Delete a network interface that is part of the * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param createSecurityGroupRulePayload Request for a security group rule creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -3925,7 +8461,7 @@ public ApiResponse createSecurityGroupRuleWithHttpInfo( * * * - * + * * * * @@ -3933,26 +8469,26 @@ public ApiResponse createSecurityGroupRuleWithHttpInfo( * *
Response Details
Status Code Description Response Headers
201 Security group rule create has been accepted. -
204 Network interface delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createSecurityGroupRuleAsync( + public okhttp3.Call deleteNicAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull CreateSecurityGroupRulePayload createSecurityGroupRulePayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createSecurityGroupRuleValidateBeforeCall( - projectId, securityGroupId, createSecurityGroupRulePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + deleteNicValidateBeforeCall(projectId, region, networkId, nicId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for createServer + * Build call for deletePublicIP * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createServerPayload Request a server creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -3960,7 +8496,7 @@ public okhttp3.Call createSecurityGroupRuleAsync( * * * - * + * * * * @@ -3968,9 +8504,10 @@ public okhttp3.Call createSecurityGroupRuleAsync( * *
Response Details
Status Code Description Response Headers
201 Create request for server accepted. -
204 The public IP has been deleted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createServerCall( + public okhttp3.Call deletePublicIPCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateServerPayload createServerPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -3986,14 +8523,20 @@ public okhttp3.Call createServerCall( basePath = null; } - Object localVarPostBody = createServerPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers" + "/v2beta1/projects/{projectId}/regions/{region}/public-ips/{publicIpId}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "publicIpId" + "}", + localVarApiClient.escapeString(publicIpId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -4007,7 +8550,7 @@ public okhttp3.Call createServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -4018,7 +8561,7 @@ public okhttp3.Call createServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -4030,39 +8573,46 @@ public okhttp3.Call createServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createServerValidateBeforeCall( + private okhttp3.Call deletePublicIPValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateServerPayload createServerPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createServer(Async)"); + "Missing the required parameter 'projectId' when calling deletePublicIP(Async)"); } - // verify the required parameter 'createServerPayload' is set - if (createServerPayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'createServerPayload' when calling createServer(Async)"); + "Missing the required parameter 'region' when calling deletePublicIP(Async)"); + } + + // verify the required parameter 'publicIpId' is set + if (publicIpId == null) { + throw new ApiException( + "Missing the required parameter 'publicIpId' when calling deletePublicIP(Async)"); } - return createServerCall(projectId, createServerPayload, _callback); + return deletePublicIPCall(projectId, region, publicIpId, _callback); } /** - * Create new server. Create a new server in a project. + * Delete a public IP. Delete a public IP that is part of the project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createServerPayload Request a server creation. (required) - * @return Server + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -4070,27 +8620,28 @@ private okhttp3.Call createServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
201 Create request for server accepted. -
204 The public IP has been deleted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Server createServer( + public void deletePublicIP( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateServerPayload createServerPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId) throws ApiException { - ApiResponse localVarResp = createServerWithHttpInfo(projectId, createServerPayload); - return localVarResp.getData(); + deletePublicIPWithHttpInfo(projectId, region, publicIpId); } /** - * Create new server. Create a new server in a project. + * Delete a public IP. Delete a public IP that is part of the project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createServerPayload Request a server creation. (required) - * @return ApiResponse<Server> + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -4098,21 +8649,22 @@ public Server createServer( * *
Response Details
Status Code Description Response Headers
201 Create request for server accepted. -
204 The public IP has been deleted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createServerWithHttpInfo( + public ApiResponse deletePublicIPWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateServerPayload createServerPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId) throws ApiException { okhttp3.Call localVarCall = - createServerValidateBeforeCall(projectId, createServerPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + deletePublicIPValidateBeforeCall(projectId, region, publicIpId, null); + return localVarApiClient.execute(localVarCall); } /** - * Create new server. (asynchronously) Create a new server in a project. + * Delete a public IP. (asynchronously) Delete a public IP that is part of the project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createServerPayload Request a server creation. (required) + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -4121,7 +8673,7 @@ public ApiResponse createServerWithHttpInfo( * * * - * + * * * * @@ -4129,24 +8681,27 @@ public ApiResponse createServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
201 Create request for server accepted. -
204 The public IP has been deleted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createServerAsync( + public okhttp3.Call deletePublicIPAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateServerPayload createServerPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createServerValidateBeforeCall(projectId, createServerPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + deletePublicIPValidateBeforeCall(projectId, region, publicIpId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for createSnapshot + * Build call for deleteRouteFromRoutingTable * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createSnapshotPayload Request a snapshot creation. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -4154,7 +8709,7 @@ public okhttp3.Call createServerAsync( * * * - * + * * * * @@ -4162,9 +8717,12 @@ public okhttp3.Call createServerAsync( * *
Response Details
Status Code Description Response Headers
201 Create request for Snapshot accepted. -
204 Delete request for the route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createSnapshotCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSnapshotPayload createSnapshotPayload, + public okhttp3.Call deleteRouteFromRoutingTableCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -4180,14 +8738,26 @@ public okhttp3.Call createSnapshotCall( basePath = null; } - Object localVarPostBody = createSnapshotPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables/{routingTableId}/routes/{routeId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -4201,7 +8771,7 @@ public okhttp3.Call createSnapshotCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -4212,7 +8782,7 @@ public okhttp3.Call createSnapshotCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -4224,39 +8794,63 @@ public okhttp3.Call createSnapshotCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createSnapshotValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSnapshotPayload createSnapshotPayload, + private okhttp3.Call deleteRouteFromRoutingTableValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { + throw new ApiException( + "Missing the required parameter 'organizationId' when calling deleteRouteFromRoutingTable(Async)"); + } + + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling deleteRouteFromRoutingTable(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createSnapshot(Async)"); + "Missing the required parameter 'region' when calling deleteRouteFromRoutingTable(Async)"); } - // verify the required parameter 'createSnapshotPayload' is set - if (createSnapshotPayload == null) { + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { + throw new ApiException( + "Missing the required parameter 'routingTableId' when calling deleteRouteFromRoutingTable(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { throw new ApiException( - "Missing the required parameter 'createSnapshotPayload' when calling createSnapshot(Async)"); + "Missing the required parameter 'routeId' when calling deleteRouteFromRoutingTable(Async)"); } - return createSnapshotCall(projectId, createSnapshotPayload, _callback); + return deleteRouteFromRoutingTableCall( + organizationId, areaId, region, routingTableId, routeId, _callback); } /** - * Create new Snapshot. Create a new Snapshot from a Volume in a project. + * Delete a route in a routing table. Delete a route in an existing routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createSnapshotPayload Request a snapshot creation. (required) - * @return Snapshot + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -4264,28 +8858,33 @@ private okhttp3.Call createSnapshotValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
201 Create request for Snapshot accepted. -
204 Delete request for the route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Snapshot createSnapshot( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSnapshotPayload createSnapshotPayload) + public void deleteRouteFromRoutingTable( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId) throws ApiException { - ApiResponse localVarResp = - createSnapshotWithHttpInfo(projectId, createSnapshotPayload); - return localVarResp.getData(); + deleteRouteFromRoutingTableWithHttpInfo( + organizationId, areaId, region, routingTableId, routeId); } /** - * Create new Snapshot. Create a new Snapshot from a Volume in a project. + * Delete a route in a routing table. Delete a route in an existing routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createSnapshotPayload Request a snapshot creation. (required) - * @return ApiResponse<Snapshot> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -4293,21 +8892,28 @@ public Snapshot createSnapshot( * *
Response Details
Status Code Description Response Headers
201 Create request for Snapshot accepted. -
204 Delete request for the route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createSnapshotWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSnapshotPayload createSnapshotPayload) + public ApiResponse deleteRouteFromRoutingTableWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId) throws ApiException { okhttp3.Call localVarCall = - createSnapshotValidateBeforeCall(projectId, createSnapshotPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + deleteRouteFromRoutingTableValidateBeforeCall( + organizationId, areaId, region, routingTableId, routeId, null); + return localVarApiClient.execute(localVarCall); } /** - * Create new Snapshot. (asynchronously) Create a new Snapshot from a Volume in a project. + * Delete a route in a routing table. (asynchronously) Delete a route in an existing routing + * table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createSnapshotPayload Request a snapshot creation. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -4316,7 +8922,7 @@ public ApiResponse createSnapshotWithHttpInfo( * * * - * + * * * * @@ -4324,24 +8930,29 @@ public ApiResponse createSnapshotWithHttpInfo( * *
Response Details
Status Code Description Response Headers
201 Create request for Snapshot accepted. -
204 Delete request for the route has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createSnapshotAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateSnapshotPayload createSnapshotPayload, - final ApiCallback _callback) + public okhttp3.Call deleteRouteFromRoutingTableAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createSnapshotValidateBeforeCall(projectId, createSnapshotPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + deleteRouteFromRoutingTableValidateBeforeCall( + organizationId, areaId, region, routingTableId, routeId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for createVolume + * Build call for deleteRoutingTableFromArea * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createVolumePayload Request a volume creation. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -4349,7 +8960,7 @@ public okhttp3.Call createSnapshotAsync( * * * - * + * * * * @@ -4357,9 +8968,11 @@ public okhttp3.Call createSnapshotAsync( * *
Response Details
Status Code Description Response Headers
201 Create request for volume accepted. -
204 Delete request for the routing table has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createVolumeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateVolumePayload createVolumePayload, + public okhttp3.Call deleteRoutingTableFromAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -4375,14 +8988,23 @@ public okhttp3.Call createVolumeCall( basePath = null; } - Object localVarPostBody = createVolumePayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables/{routingTableId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -4396,7 +9018,7 @@ public okhttp3.Call createVolumeCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -4407,7 +9029,7 @@ public okhttp3.Call createVolumeCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -4419,41 +9041,55 @@ public okhttp3.Call createVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call createVolumeValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateVolumePayload createVolumePayload, + private okhttp3.Call deleteRoutingTableFromAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling createVolume(Async)"); + "Missing the required parameter 'organizationId' when calling deleteRoutingTableFromArea(Async)"); } - // verify the required parameter 'createVolumePayload' is set - if (createVolumePayload == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'createVolumePayload' when calling createVolume(Async)"); + "Missing the required parameter 'areaId' when calling deleteRoutingTableFromArea(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling deleteRoutingTableFromArea(Async)"); } - return createVolumeCall(projectId, createVolumePayload, _callback); + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { + throw new ApiException( + "Missing the required parameter 'routingTableId' when calling deleteRoutingTableFromArea(Async)"); + } + + return deleteRoutingTableFromAreaCall( + organizationId, areaId, region, routingTableId, _callback); } /** - * Create new volume. Create a new volume in a project. If a volume source is not provided, an - * empty volume will be created. The size property is required if no source or an image source - * is provided. + * Delete a routing table. Delete a routing table of a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createVolumePayload Request a volume creation. (required) - * @return Volume + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -4461,29 +9097,30 @@ private okhttp3.Call createVolumeValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
201 Create request for volume accepted. -
204 Delete request for the routing table has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Volume createVolume( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateVolumePayload createVolumePayload) + public void deleteRoutingTableFromArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId) throws ApiException { - ApiResponse localVarResp = createVolumeWithHttpInfo(projectId, createVolumePayload); - return localVarResp.getData(); + deleteRoutingTableFromAreaWithHttpInfo(organizationId, areaId, region, routingTableId); } /** - * Create new volume. Create a new volume in a project. If a volume source is not provided, an - * empty volume will be created. The size property is required if no source or an image source - * is provided. + * Delete a routing table. Delete a routing table of a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createVolumePayload Request a volume creation. (required) - * @return ApiResponse<Volume> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -4491,23 +9128,25 @@ public Volume createVolume( * *
Response Details
Status Code Description Response Headers
201 Create request for volume accepted. -
204 Delete request for the routing table has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse createVolumeWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateVolumePayload createVolumePayload) + public ApiResponse deleteRoutingTableFromAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId) throws ApiException { okhttp3.Call localVarCall = - createVolumeValidateBeforeCall(projectId, createVolumePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + deleteRoutingTableFromAreaValidateBeforeCall( + organizationId, areaId, region, routingTableId, null); + return localVarApiClient.execute(localVarCall); } /** - * Create new volume. (asynchronously) Create a new volume in a project. If a volume source is - * not provided, an empty volume will be created. The size property is required if no source or - * an image source is provided. + * Delete a routing table. (asynchronously) Delete a routing table of a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param createVolumePayload Request a volume creation. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -4516,7 +9155,7 @@ public ApiResponse createVolumeWithHttpInfo( * * * - * + * * * * @@ -4524,24 +9163,27 @@ public ApiResponse createVolumeWithHttpInfo( * *
Response Details
Status Code Description Response Headers
201 Create request for volume accepted. -
204 Delete request for the routing table has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call createVolumeAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull CreateVolumePayload createVolumePayload, - final ApiCallback _callback) + public okhttp3.Call deleteRoutingTableFromAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - createVolumeValidateBeforeCall(projectId, createVolumePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + deleteRoutingTableFromAreaValidateBeforeCall( + organizationId, areaId, region, routingTableId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for deallocateServer + * Build call for deleteSecurityGroup * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -4549,7 +9191,7 @@ public okhttp3.Call createVolumeAsync( * * * - * + * * * * @@ -4558,9 +9200,10 @@ public okhttp3.Call createVolumeAsync( * *
Response Details
Status Code Description Response Headers
202 Server deallocation request accepted. -
204 Delete request for security group has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deallocateServerCall( + public okhttp3.Call deleteSecurityGroupCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -4580,13 +9223,16 @@ public okhttp3.Call deallocateServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/deallocate" + "/v2beta1/projects/{projectId}/regions/{region}/security-groups/{securityGroupId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -4611,7 +9257,7 @@ public okhttp3.Call deallocateServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -4623,39 +9269,46 @@ public okhttp3.Call deallocateServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deallocateServerValidateBeforeCall( + private okhttp3.Call deleteSecurityGroupValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deallocateServer(Async)"); + "Missing the required parameter 'projectId' when calling deleteSecurityGroup(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling deallocateServer(Async)"); + "Missing the required parameter 'region' when calling deleteSecurityGroup(Async)"); } - return deallocateServerCall(projectId, serverId, _callback); + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupId' when calling deleteSecurityGroup(Async)"); + } + + return deleteSecurityGroupCall(projectId, region, securityGroupId, _callback); } /** - * Deallocate an existing server. Deallocate an existing server. The server will be removed from - * the hypervisor so only the volume will be billed. + * Delete security group. Delete a security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -4664,18 +9317,20 @@ private okhttp3.Call deallocateServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
202 Server deallocation request accepted. -
204 Delete request for security group has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deallocateServer( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public void deleteSecurityGroup( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { - deallocateServerWithHttpInfo(projectId, serverId); + deleteSecurityGroupWithHttpInfo(projectId, region, securityGroupId); } /** - * Deallocate an existing server. Deallocate an existing server. The server will be removed from - * the hypervisor so only the volume will be billed. + * Delete security group. Delete a security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -4683,7 +9338,7 @@ public void deallocateServer( * * * - * + * * * * @@ -4692,19 +9347,22 @@ public void deallocateServer( * *
Response Details
Status Code Description Response Headers
202 Server deallocation request accepted. -
204 Delete request for security group has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deallocateServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse deleteSecurityGroupWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { - okhttp3.Call localVarCall = deallocateServerValidateBeforeCall(projectId, serverId, null); + okhttp3.Call localVarCall = + deleteSecurityGroupValidateBeforeCall(projectId, region, securityGroupId, null); return localVarApiClient.execute(localVarCall); } /** - * Deallocate an existing server. (asynchronously) Deallocate an existing server. The server - * will be removed from the hypervisor so only the volume will be billed. + * Delete security group. (asynchronously) Delete a security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -4713,7 +9371,7 @@ public ApiResponse deallocateServerWithHttpInfo( * * * - * + * * * * @@ -4722,23 +9380,27 @@ public ApiResponse deallocateServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
202 Server deallocation request accepted. -
204 Delete request for security group has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deallocateServerAsync( + public okhttp3.Call deleteSecurityGroupAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deallocateServerValidateBeforeCall(projectId, serverId, _callback); + deleteSecurityGroupValidateBeforeCall( + projectId, region, securityGroupId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for deleteAffinityGroup + * Build call for deleteSecurityGroupRule * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -4746,7 +9408,7 @@ public okhttp3.Call deallocateServerAsync( * * * - * + * * * * @@ -4754,9 +9416,11 @@ public okhttp3.Call deallocateServerAsync( * *
Response Details
Status Code Description Response Headers
204 Delete request for an server group was accepted. -
204 Delete request for security group rule has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteAffinityGroupCall( + public okhttp3.Call deleteSecurityGroupRuleCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -4776,13 +9440,19 @@ public okhttp3.Call deleteAffinityGroupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/affinity-groups/{affinityGroupId}" + "/v2beta1/projects/{projectId}/regions/{region}/security-groups/{securityGroupId}/rules/{securityGroupRuleId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "affinityGroupId" + "}", - localVarApiClient.escapeString(affinityGroupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())) + .replace( + "{" + "securityGroupRuleId" + "}", + localVarApiClient.escapeString(securityGroupRuleId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -4819,38 +9489,55 @@ public okhttp3.Call deleteAffinityGroupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteAffinityGroupValidateBeforeCall( + private okhttp3.Call deleteSecurityGroupRuleValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteAffinityGroup(Async)"); + "Missing the required parameter 'projectId' when calling deleteSecurityGroupRule(Async)"); } - // verify the required parameter 'affinityGroupId' is set - if (affinityGroupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'affinityGroupId' when calling deleteAffinityGroup(Async)"); + "Missing the required parameter 'region' when calling deleteSecurityGroupRule(Async)"); + } + + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupId' when calling deleteSecurityGroupRule(Async)"); + } + + // verify the required parameter 'securityGroupRuleId' is set + if (securityGroupRuleId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupRuleId' when calling deleteSecurityGroupRule(Async)"); } - return deleteAffinityGroupCall(projectId, affinityGroupId, _callback); + return deleteSecurityGroupRuleCall( + projectId, region, securityGroupId, securityGroupRuleId, _callback); } /** - * Delete a affinity group in a project. Delete a affinity group in the given project. + * Delete security group rule. Delete a security group rule. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -4858,18 +9545,23 @@ private okhttp3.Call deleteAffinityGroupValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Delete request for an server group was accepted. -
204 Delete request for security group rule has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteAffinityGroup( + public void deleteSecurityGroupRule( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId) throws ApiException { - deleteAffinityGroupWithHttpInfo(projectId, affinityGroupId); + deleteSecurityGroupRuleWithHttpInfo( + projectId, region, securityGroupId, securityGroupRuleId); } /** - * Delete a affinity group in a project. Delete a affinity group in the given project. + * Delete security group rule. Delete a security group rule. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -4877,7 +9569,7 @@ public void deleteAffinityGroup( * * * - * + * * * * @@ -4885,21 +9577,25 @@ public void deleteAffinityGroup( * *
Response Details
Status Code Description Response Headers
204 Delete request for an server group was accepted. -
204 Delete request for security group rule has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteAffinityGroupWithHttpInfo( + public ApiResponse deleteSecurityGroupRuleWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId) throws ApiException { okhttp3.Call localVarCall = - deleteAffinityGroupValidateBeforeCall(projectId, affinityGroupId, null); + deleteSecurityGroupRuleValidateBeforeCall( + projectId, region, securityGroupId, securityGroupRuleId, null); return localVarApiClient.execute(localVarCall); } /** - * Delete a affinity group in a project. (asynchronously) Delete a affinity group in the given - * project. + * Delete security group rule. (asynchronously) Delete a security group rule. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -4908,7 +9604,7 @@ public ApiResponse deleteAffinityGroupWithHttpInfo( * * * - * + * * * * @@ -4916,24 +9612,27 @@ public ApiResponse deleteAffinityGroupWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Delete request for an server group was accepted. -
204 Delete request for security group rule has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteAffinityGroupAsync( + public okhttp3.Call deleteSecurityGroupRuleAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteAffinityGroupValidateBeforeCall(projectId, affinityGroupId, _callback); + deleteSecurityGroupRuleValidateBeforeCall( + projectId, region, securityGroupId, securityGroupRuleId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for deleteBackup + * Build call for deleteServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @param force Force action. (optional, default to false) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -4941,7 +9640,7 @@ public okhttp3.Call deleteAffinityGroupAsync( * * * - * + * * * * @@ -4949,10 +9648,10 @@ public okhttp3.Call deleteAffinityGroupAsync( * *
Response Details
Status Code Description Response Headers
204 Backup delete request has been accepted. -
204 Delete request for server accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteBackupCall( + public okhttp3.Call deleteServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nullable Boolean force, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -4972,13 +9671,16 @@ public okhttp3.Call deleteBackupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups/{backupId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "backupId" + "}", - localVarApiClient.escapeString(backupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -4986,10 +9688,6 @@ public okhttp3.Call deleteBackupCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (force != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("force", force)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -5019,40 +9717,46 @@ public okhttp3.Call deleteBackupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteBackupValidateBeforeCall( + private okhttp3.Call deleteServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nullable Boolean force, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteBackup(Async)"); + "Missing the required parameter 'projectId' when calling deleteServer(Async)"); } - // verify the required parameter 'backupId' is set - if (backupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'backupId' when calling deleteBackup(Async)"); + "Missing the required parameter 'region' when calling deleteServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling deleteServer(Async)"); } - return deleteBackupCall(projectId, backupId, force, _callback); + return deleteServerCall(projectId, region, serverId, _callback); } /** - * Delete a backup. Delete a backup that is part of the project. + * Delete a server. Delete a server. Volumes won't be deleted. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @param force Force action. (optional, default to false) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -5060,20 +9764,20 @@ private okhttp3.Call deleteBackupValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Backup delete request has been accepted. -
204 Delete request for server accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteBackup( + public void deleteServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nullable Boolean force) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - deleteBackupWithHttpInfo(projectId, backupId, force); + deleteServerWithHttpInfo(projectId, region, serverId); } /** - * Delete a backup. Delete a backup that is part of the project. + * Delete a server. Delete a server. Volumes won't be deleted. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @param force Force action. (optional, default to false) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -5081,7 +9785,7 @@ public void deleteBackup( * * * - * + * * * * @@ -5089,22 +9793,22 @@ public void deleteBackup( * *
Response Details
Status Code Description Response Headers
204 Backup delete request has been accepted. -
204 Delete request for server accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteBackupWithHttpInfo( + public ApiResponse deleteServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nullable Boolean force) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { okhttp3.Call localVarCall = - deleteBackupValidateBeforeCall(projectId, backupId, force, null); + deleteServerValidateBeforeCall(projectId, region, serverId, null); return localVarApiClient.execute(localVarCall); } /** - * Delete a backup. (asynchronously) Delete a backup that is part of the project. + * Delete a server. (asynchronously) Delete a server. Volumes won't be deleted. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @param force Force action. (optional, default to false) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -5113,7 +9817,7 @@ public ApiResponse deleteBackupWithHttpInfo( * * * - * + * * * * @@ -5121,24 +9825,25 @@ public ApiResponse deleteBackupWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Backup delete request has been accepted. -
204 Delete request for server accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteBackupAsync( + public okhttp3.Call deleteServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nullable Boolean force, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteBackupValidateBeforeCall(projectId, backupId, force, _callback); + deleteServerValidateBeforeCall(projectId, region, serverId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for deleteImage + * Build call for deleteVolume * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -5146,17 +9851,19 @@ public okhttp3.Call deleteBackupAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
204 Image delete request has been accepted. -
204 Volume delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteImageCall( + public okhttp3.Call deleteVolumeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -5176,13 +9883,16 @@ public okhttp3.Call deleteImageCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}" + "/v2beta1/projects/{projectId}/regions/{region}/volumes/{volumeId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "volumeId" + "}", + localVarApiClient.escapeString(volumeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -5219,56 +9929,70 @@ public okhttp3.Call deleteImageCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteImageValidateBeforeCall( + private okhttp3.Call deleteVolumeValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteImage(Async)"); + "Missing the required parameter 'projectId' when calling deleteVolume(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling deleteImage(Async)"); + "Missing the required parameter 'region' when calling deleteVolume(Async)"); + } + + // verify the required parameter 'volumeId' is set + if (volumeId == null) { + throw new ApiException( + "Missing the required parameter 'volumeId' when calling deleteVolume(Async)"); } - return deleteImageCall(projectId, imageId, _callback); + return deleteVolumeCall(projectId, region, volumeId, _callback); } /** - * Delete an Image. Delete an image that is part of the project. + * Delete a volume. Delete a volume inside a project. The deletion will fail if the volume is + * still in use. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
204 Image delete request has been accepted. -
204 Volume delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteImage( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public void deleteVolume( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId) throws ApiException { - deleteImageWithHttpInfo(projectId, imageId); + deleteVolumeWithHttpInfo(projectId, region, volumeId); } /** - * Delete an Image. Delete an image that is part of the project. + * Delete a volume. Delete a volume inside a project. The deletion will fail if the volume is + * still in use. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -5276,26 +10000,32 @@ public void deleteImage( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
204 Image delete request has been accepted. -
204 Volume delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteImageWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public ApiResponse deleteVolumeWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId) throws ApiException { - okhttp3.Call localVarCall = deleteImageValidateBeforeCall(projectId, imageId, null); + okhttp3.Call localVarCall = + deleteVolumeValidateBeforeCall(projectId, region, volumeId, null); return localVarApiClient.execute(localVarCall); } /** - * Delete an Image. (asynchronously) Delete an image that is part of the project. + * Delete a volume. (asynchronously) Delete a volume inside a project. The deletion will fail if + * the volume is still in use. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -5304,30 +10034,34 @@ public ApiResponse deleteImageWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
204 Image delete request has been accepted. -
204 Volume delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteImageAsync( + public okhttp3.Call deleteVolumeAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = deleteImageValidateBeforeCall(projectId, imageId, _callback); + okhttp3.Call localVarCall = + deleteVolumeValidateBeforeCall(projectId, region, volumeId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for deleteImageShare + * Build call for getAffinityGroup * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -5335,7 +10069,7 @@ public okhttp3.Call deleteImageAsync( * * * - * + * * * * @@ -5343,9 +10077,10 @@ public okhttp3.Call deleteImageAsync( * *
Response Details
Status Code Description Response Headers
204 Image share removed. -
200 Show affinity group details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteImageShareCall( + public okhttp3.Call getAffinityGroupCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -5365,13 +10100,16 @@ public okhttp3.Call deleteImageShareCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share" + "/v2beta1/projects/{projectId}/regions/{region}/affinity-groups/{affinityGroupId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "affinityGroupId" + "}", + localVarApiClient.escapeString(affinityGroupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -5396,7 +10134,7 @@ public okhttp3.Call deleteImageShareCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -5408,38 +10146,47 @@ public okhttp3.Call deleteImageShareCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteImageShareValidateBeforeCall( + private okhttp3.Call getAffinityGroupValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteImageShare(Async)"); + "Missing the required parameter 'projectId' when calling getAffinityGroup(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling deleteImageShare(Async)"); + "Missing the required parameter 'region' when calling getAffinityGroup(Async)"); } - return deleteImageShareCall(projectId, imageId, _callback); + // verify the required parameter 'affinityGroupId' is set + if (affinityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'affinityGroupId' when calling getAffinityGroup(Async)"); + } + + return getAffinityGroupCall(projectId, region, affinityGroupId, _callback); } /** - * Remove image share. Remove the image share. New scope will be local. + * Get the affinity group. Get the affinity group created in a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @return AffinityGroup * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -5447,25 +10194,30 @@ private okhttp3.Call deleteImageShareValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Image share removed. -
200 Show affinity group details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteImageShare( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public AffinityGroup getAffinityGroup( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId) throws ApiException { - deleteImageShareWithHttpInfo(projectId, imageId); + ApiResponse localVarResp = + getAffinityGroupWithHttpInfo(projectId, region, affinityGroupId); + return localVarResp.getData(); } /** - * Remove image share. Remove the image share. New scope will be local. + * Get the affinity group. Get the affinity group created in a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @return ApiResponse<AffinityGroup> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -5473,18 +10225,23 @@ public void deleteImageShare( * *
Response Details
Status Code Description Response Headers
204 Image share removed. -
200 Show affinity group details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteImageShareWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public ApiResponse getAffinityGroupWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId) throws ApiException { - okhttp3.Call localVarCall = deleteImageShareValidateBeforeCall(projectId, imageId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + getAffinityGroupValidateBeforeCall(projectId, region, affinityGroupId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Remove image share. (asynchronously) Remove the image share. New scope will be local. + * Get the affinity group. (asynchronously) Get the affinity group created in a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -5493,7 +10250,7 @@ public ApiResponse deleteImageShareWithHttpInfo( * * * - * + * * * * @@ -5501,25 +10258,27 @@ public ApiResponse deleteImageShareWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Image share removed. -
200 Show affinity group details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteImageShareAsync( + public okhttp3.Call getAffinityGroupAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID affinityGroupId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteImageShareValidateBeforeCall(projectId, imageId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getAffinityGroupValidateBeforeCall(projectId, region, affinityGroupId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteImageShareConsumer + * Build call for getAttachedVolume * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image - * share. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -5527,7 +10286,7 @@ public okhttp3.Call deleteImageShareAsync( * * * - * + * * * * @@ -5535,10 +10294,11 @@ public okhttp3.Call deleteImageShareAsync( * *
Response Details
Status Code Description Response Headers
204 Image share consumer removed. -
200 Get details about a volume attachment. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteImageShareConsumerCall( + public okhttp3.Call getAttachedVolumeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -5558,16 +10318,19 @@ public okhttp3.Call deleteImageShareConsumerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share/{consumerProjectId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/volume-attachments/{volumeId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "consumerProjectId" + "}", - localVarApiClient.escapeString(consumerProjectId.toString())); + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "volumeId" + "}", + localVarApiClient.escapeString(volumeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -5592,7 +10355,7 @@ public okhttp3.Call deleteImageShareConsumerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -5604,47 +10367,55 @@ public okhttp3.Call deleteImageShareConsumerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteImageShareConsumerValidateBeforeCall( + private okhttp3.Call getAttachedVolumeValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteImageShareConsumer(Async)"); + "Missing the required parameter 'projectId' when calling getAttachedVolume(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling deleteImageShareConsumer(Async)"); + "Missing the required parameter 'region' when calling getAttachedVolume(Async)"); } - // verify the required parameter 'consumerProjectId' is set - if (consumerProjectId == null) { + // verify the required parameter 'serverId' is set + if (serverId == null) { throw new ApiException( - "Missing the required parameter 'consumerProjectId' when calling deleteImageShareConsumer(Async)"); + "Missing the required parameter 'serverId' when calling getAttachedVolume(Async)"); + } + + // verify the required parameter 'volumeId' is set + if (volumeId == null) { + throw new ApiException( + "Missing the required parameter 'volumeId' when calling getAttachedVolume(Async)"); } - return deleteImageShareConsumerCall(projectId, imageId, consumerProjectId, _callback); + return getAttachedVolumeCall(projectId, region, serverId, volumeId, _callback); } /** - * Remove an image share consumer. Remove consumer from a shared image. + * Get Volume Attachment details. Get the details of an existing Volume Attachment. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image - * share. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @return VolumeAttachment * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -5652,29 +10423,32 @@ private okhttp3.Call deleteImageShareConsumerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Image share consumer removed. -
200 Get details about a volume attachment. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteImageShareConsumer( + public VolumeAttachment getAttachedVolume( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId) throws ApiException { - deleteImageShareConsumerWithHttpInfo(projectId, imageId, consumerProjectId); + ApiResponse localVarResp = + getAttachedVolumeWithHttpInfo(projectId, region, serverId, volumeId); + return localVarResp.getData(); } /** - * Remove an image share consumer. Remove consumer from a shared image. + * Get Volume Attachment details. Get the details of an existing Volume Attachment. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image - * share. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @return ApiResponse<VolumeAttachment> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -5682,24 +10456,26 @@ public void deleteImageShareConsumer( * *
Response Details
Status Code Description Response Headers
204 Image share consumer removed. -
200 Get details about a volume attachment. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteImageShareConsumerWithHttpInfo( + public ApiResponse getAttachedVolumeWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId) throws ApiException { okhttp3.Call localVarCall = - deleteImageShareConsumerValidateBeforeCall( - projectId, imageId, consumerProjectId, null); - return localVarApiClient.execute(localVarCall); + getAttachedVolumeValidateBeforeCall(projectId, region, serverId, volumeId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Remove an image share consumer. (asynchronously) Remove consumer from a shared image. + * Get Volume Attachment details. (asynchronously) Get the details of an existing Volume + * Attachment. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image - * share. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -5708,7 +10484,7 @@ public ApiResponse deleteImageShareConsumerWithHttpInfo( * * * - * + * * * * @@ -5716,24 +10492,28 @@ public ApiResponse deleteImageShareConsumerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Image share consumer removed. -
200 Get details about a volume attachment. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteImageShareConsumerAsync( + public okhttp3.Call getAttachedVolumeAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteImageShareConsumerValidateBeforeCall( - projectId, imageId, consumerProjectId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getAttachedVolumeValidateBeforeCall( + projectId, region, serverId, volumeId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteKeyPair + * Build call for getBackup * - * @param keypairName The name of an SSH keypair. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -5741,7 +10521,7 @@ public okhttp3.Call deleteImageShareConsumerAsync( * * * - * + * * * * @@ -5749,8 +10529,11 @@ public okhttp3.Call deleteImageShareConsumerAsync( * *
Response Details
Status Code Description Response Headers
204 Delete request for an SSH keypair was accepted. -
200 Show backup details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteKeyPairCall( - @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + public okhttp3.Call getBackupCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -5769,10 +10552,16 @@ public okhttp3.Call deleteKeyPairCall( // create path and map variables String localVarPath = - "/v1/keypairs/{keypairName}" + "/v2beta1/projects/{projectId}/regions/{region}/backups/{backupId}" .replace( - "{" + "keypairName" + "}", - localVarApiClient.escapeString(keypairName.toString())); + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "backupId" + "}", + localVarApiClient.escapeString(backupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -5797,7 +10586,7 @@ public okhttp3.Call deleteKeyPairCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -5809,29 +10598,47 @@ public okhttp3.Call deleteKeyPairCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteKeyPairValidateBeforeCall( - @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + private okhttp3.Call getBackupValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + final ApiCallback _callback) throws ApiException { - // verify the required parameter 'keypairName' is set - if (keypairName == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'keypairName' when calling deleteKeyPair(Async)"); + "Missing the required parameter 'projectId' when calling getBackup(Async)"); } - return deleteKeyPairCall(keypairName, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling getBackup(Async)"); + } + + // verify the required parameter 'backupId' is set + if (backupId == null) { + throw new ApiException( + "Missing the required parameter 'backupId' when calling getBackup(Async)"); + } + + return getBackupCall(projectId, region, backupId, _callback); } /** - * Delete an SSH keypair. Delete an SSH keypair from a user. + * Get details about a backup. Get details about a block device backup. * - * @param keypairName The name of an SSH keypair. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @return Backup * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -5839,22 +10646,29 @@ private okhttp3.Call deleteKeyPairValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Delete request for an SSH keypair was accepted. -
200 Show backup details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteKeyPair(@javax.annotation.Nonnull String keypairName) throws ApiException { - deleteKeyPairWithHttpInfo(keypairName); + public Backup getBackup( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId) + throws ApiException { + ApiResponse localVarResp = getBackupWithHttpInfo(projectId, region, backupId); + return localVarResp.getData(); } /** - * Delete an SSH keypair. Delete an SSH keypair from a user. + * Get details about a backup. Get details about a block device backup. * - * @param keypairName The name of an SSH keypair. (required) - * @return ApiResponse<Void> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @return ApiResponse<Backup> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -5862,16 +10676,22 @@ public void deleteKeyPair(@javax.annotation.Nonnull String keypairName) throws A * *
Response Details
Status Code Description Response Headers
204 Delete request for an SSH keypair was accepted. -
200 Show backup details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteKeyPairWithHttpInfo(@javax.annotation.Nonnull String keypairName) + public ApiResponse getBackupWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId) throws ApiException { - okhttp3.Call localVarCall = deleteKeyPairValidateBeforeCall(keypairName, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = getBackupValidateBeforeCall(projectId, region, backupId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete an SSH keypair. (asynchronously) Delete an SSH keypair from a user. + * Get details about a backup. (asynchronously) Get details about a block device backup. * - * @param keypairName The name of an SSH keypair. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -5880,7 +10700,7 @@ public ApiResponse deleteKeyPairWithHttpInfo(@javax.annotation.Nonnull Str * * * - * + * * * * @@ -5888,20 +10708,26 @@ public ApiResponse deleteKeyPairWithHttpInfo(@javax.annotation.Nonnull Str * *
Response Details
Status Code Description Response Headers
204 Delete request for an SSH keypair was accepted. -
200 Show backup details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteKeyPairAsync( - @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + public okhttp3.Call getBackupAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = deleteKeyPairValidateBeforeCall(keypairName, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + okhttp3.Call localVarCall = + getBackupValidateBeforeCall(projectId, region, backupId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteNetwork + * Build call for getImage * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -5909,18 +10735,18 @@ public okhttp3.Call deleteKeyPairAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for network has been accepted. -
200 Show Image details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNetworkCall( + public okhttp3.Call getImageCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -5940,13 +10766,16 @@ public okhttp3.Call deleteNetworkCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}" + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -5971,7 +10800,7 @@ public okhttp3.Call deleteNetworkCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -5983,86 +10812,101 @@ public okhttp3.Call deleteNetworkCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteNetworkValidateBeforeCall( + private okhttp3.Call getImageValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteNetwork(Async)"); + "Missing the required parameter 'projectId' when calling getImage(Async)"); } - // verify the required parameter 'networkId' is set - if (networkId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'networkId' when calling deleteNetwork(Async)"); + "Missing the required parameter 'region' when calling getImage(Async)"); } - return deleteNetworkCall(projectId, networkId, _callback); + // verify the required parameter 'imageId' is set + if (imageId == null) { + throw new ApiException( + "Missing the required parameter 'imageId' when calling getImage(Async)"); + } + + return getImageCall(projectId, region, imageId, _callback); } /** - * Delete network. Delete a network. If the network is still in use, the deletion will fail. + * Get details about an image. Get details about a specific Image inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @return Image * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for network has been accepted. -
200 Show Image details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteNetwork( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID networkId) + public Image getImage( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId) throws ApiException { - deleteNetworkWithHttpInfo(projectId, networkId); + ApiResponse localVarResp = getImageWithHttpInfo(projectId, region, imageId); + return localVarResp.getData(); } /** - * Delete network. Delete a network. If the network is still in use, the deletion will fail. + * Get details about an image. Get details about a specific Image inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @return ApiResponse<Image> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for network has been accepted. -
200 Show Image details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteNetworkWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID networkId) + public ApiResponse getImageWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId) throws ApiException { - okhttp3.Call localVarCall = deleteNetworkValidateBeforeCall(projectId, networkId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = getImageValidateBeforeCall(projectId, region, imageId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete network. (asynchronously) Delete a network. If the network is still in use, the - * deletion will fail. + * Get details about an image. (asynchronously) Get details about a specific Image inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -6071,32 +10915,34 @@ public ApiResponse deleteNetworkWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for network has been accepted. -
200 Show Image details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNetworkAsync( + public okhttp3.Call getImageAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteNetworkValidateBeforeCall(projectId, networkId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getImageValidateBeforeCall(projectId, region, imageId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteNetworkArea + * Build call for getImageShare * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -6104,18 +10950,18 @@ public okhttp3.Call deleteNetworkAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for area has been accepted. -
200 Show Image share details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNetworkAreaCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + public okhttp3.Call getImageShareCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -6135,13 +10981,16 @@ public okhttp3.Call deleteNetworkAreaCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}" + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}/share" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -6166,7 +11015,7 @@ public okhttp3.Call deleteNetworkAreaCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6178,89 +11027,102 @@ public okhttp3.Call deleteNetworkAreaCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteNetworkAreaValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + private okhttp3.Call getImageShareValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling deleteNetworkArea(Async)"); + "Missing the required parameter 'projectId' when calling getImageShare(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling deleteNetworkArea(Async)"); + "Missing the required parameter 'region' when calling getImageShare(Async)"); } - return deleteNetworkAreaCall(organizationId, areaId, _callback); + // verify the required parameter 'imageId' is set + if (imageId == null) { + throw new ApiException( + "Missing the required parameter 'imageId' when calling getImageShare(Async)"); + } + + return getImageShareCall(projectId, region, imageId, _callback); } /** - * Delete a network area. Delete an existing network area in an organization. This is only - * possible if no projects are using the area anymore. + * Get share details of an image. Get share details about an shared image. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @return ImageShare * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for area has been accepted. -
200 Show Image share details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteNetworkArea( - @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + public ImageShare getImageShare( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId) throws ApiException { - deleteNetworkAreaWithHttpInfo(organizationId, areaId); + ApiResponse localVarResp = + getImageShareWithHttpInfo(projectId, region, imageId); + return localVarResp.getData(); } /** - * Delete a network area. Delete an existing network area in an organization. This is only - * possible if no projects are using the area anymore. + * Get share details of an image. Get share details about an shared image. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @return ApiResponse<Void> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @return ApiResponse<ImageShare> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for area has been accepted. -
200 Show Image share details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteNetworkAreaWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + public ApiResponse getImageShareWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId) throws ApiException { okhttp3.Call localVarCall = - deleteNetworkAreaValidateBeforeCall(organizationId, areaId, null); - return localVarApiClient.execute(localVarCall); + getImageShareValidateBeforeCall(projectId, region, imageId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete a network area. (asynchronously) Delete an existing network area in an organization. - * This is only possible if no projects are using the area anymore. + * Get share details of an image. (asynchronously) Get share details about an shared image. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -6269,33 +11131,36 @@ public ApiResponse deleteNetworkAreaWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for area has been accepted. -
200 Show Image share details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNetworkAreaAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - final ApiCallback _callback) + public okhttp3.Call getImageShareAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteNetworkAreaValidateBeforeCall(organizationId, areaId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getImageShareValidateBeforeCall(projectId, region, imageId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteNetworkAreaRange + * Build call for getImageShareConsumer * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image + * share. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -6303,19 +11168,19 @@ public okhttp3.Call deleteNetworkAreaAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for network range has been accepted. -
200 Show Image share consumer details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNetworkAreaRangeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId, + public okhttp3.Call getImageShareConsumerCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -6335,16 +11200,19 @@ public okhttp3.Call deleteNetworkAreaRangeCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/network-ranges/{networkRangeId}" + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}/share/{consumerProjectId}" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "networkRangeId" + "}", - localVarApiClient.escapeString(networkRangeId.toString())); + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())) + .replace( + "{" + "consumerProjectId" + "}", + localVarApiClient.escapeString(consumerProjectId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -6369,7 +11237,7 @@ public okhttp3.Call deleteNetworkAreaRangeCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6381,104 +11249,118 @@ public okhttp3.Call deleteNetworkAreaRangeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteNetworkAreaRangeValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId, + private okhttp3.Call getImageShareConsumerValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling deleteNetworkAreaRange(Async)"); + "Missing the required parameter 'projectId' when calling getImageShareConsumer(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling deleteNetworkAreaRange(Async)"); + "Missing the required parameter 'region' when calling getImageShareConsumer(Async)"); } - // verify the required parameter 'networkRangeId' is set - if (networkRangeId == null) { + // verify the required parameter 'imageId' is set + if (imageId == null) { throw new ApiException( - "Missing the required parameter 'networkRangeId' when calling deleteNetworkAreaRange(Async)"); + "Missing the required parameter 'imageId' when calling getImageShareConsumer(Async)"); + } + + // verify the required parameter 'consumerProjectId' is set + if (consumerProjectId == null) { + throw new ApiException( + "Missing the required parameter 'consumerProjectId' when calling getImageShareConsumer(Async)"); } - return deleteNetworkAreaRangeCall(organizationId, areaId, networkRangeId, _callback); + return getImageShareConsumerCall(projectId, region, imageId, consumerProjectId, _callback); } /** - * Delete a network range. Delete a network range of a network area. The deletion will fail if - * the network range is still used. + * Get image share consumer. Get details about an image share consumer. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image + * share. (required) + * @return ImageShareConsumer * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for network range has been accepted. -
200 Show Image share consumer details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteNetworkAreaRange( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId) + public ImageShareConsumer getImageShareConsumer( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId) throws ApiException { - deleteNetworkAreaRangeWithHttpInfo(organizationId, areaId, networkRangeId); + ApiResponse localVarResp = + getImageShareConsumerWithHttpInfo(projectId, region, imageId, consumerProjectId); + return localVarResp.getData(); } /** - * Delete a network range. Delete a network range of a network area. The deletion will fail if - * the network range is still used. + * Get image share consumer. Get details about an image share consumer. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) - * @return ApiResponse<Void> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image + * share. (required) + * @return ApiResponse<ImageShareConsumer> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Delete request for network range has been accepted. -
200 Show Image share consumer details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteNetworkAreaRangeWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId) + public ApiResponse getImageShareConsumerWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId) throws ApiException { okhttp3.Call localVarCall = - deleteNetworkAreaRangeValidateBeforeCall( - organizationId, areaId, networkRangeId, null); - return localVarApiClient.execute(localVarCall); + getImageShareConsumerValidateBeforeCall( + projectId, region, imageId, consumerProjectId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete a network range. (asynchronously) Delete a network range of a network area. The - * deletion will fail if the network range is still used. + * Get image share consumer. (asynchronously) Get details about an image share consumer. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image + * share. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -6487,35 +11369,34 @@ public ApiResponse deleteNetworkAreaRangeWithHttpInfo( * * * - * + * * * * * - * - * - *
Response Details
Status Code Description Response Headers
202 Delete request for network range has been accepted. -
200 Show Image share consumer details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
- */ - public okhttp3.Call deleteNetworkAreaRangeAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId, - final ApiCallback _callback) + * 500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. - + * + */ + public okhttp3.Call getImageShareConsumerAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UUID consumerProjectId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteNetworkAreaRangeValidateBeforeCall( - organizationId, areaId, networkRangeId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getImageShareConsumerValidateBeforeCall( + projectId, region, imageId, consumerProjectId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteNetworkAreaRoute + * Build call for getKeyPair * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param keypairName The name of an SSH keypair. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -6523,7 +11404,7 @@ public okhttp3.Call deleteNetworkAreaRangeAsync( * * * - * + * * * * @@ -6531,11 +11412,8 @@ public okhttp3.Call deleteNetworkAreaRangeAsync( * *
Response Details
Status Code Description Response Headers
202 Delete request for network route has been accepted. -
200 Show SSH keypair details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNetworkAreaRouteCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - final ApiCallback _callback) + public okhttp3.Call getKeyPairCall( + @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -6554,16 +11432,10 @@ public okhttp3.Call deleteNetworkAreaRouteCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/routes/{routeId}" - .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) - .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())) + "/v2beta1/keypairs/{keypairName}" .replace( - "{" + "routeId" + "}", - localVarApiClient.escapeString(routeId.toString())); + "{" + "keypairName" + "}", + localVarApiClient.escapeString(keypairName.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -6588,7 +11460,7 @@ public okhttp3.Call deleteNetworkAreaRouteCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6600,46 +11472,30 @@ public okhttp3.Call deleteNetworkAreaRouteCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteNetworkAreaRouteValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - final ApiCallback _callback) + private okhttp3.Call getKeyPairValidateBeforeCall( + @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { - throw new ApiException( - "Missing the required parameter 'organizationId' when calling deleteNetworkAreaRoute(Async)"); - } - - // verify the required parameter 'areaId' is set - if (areaId == null) { - throw new ApiException( - "Missing the required parameter 'areaId' when calling deleteNetworkAreaRoute(Async)"); - } - - // verify the required parameter 'routeId' is set - if (routeId == null) { + // verify the required parameter 'keypairName' is set + if (keypairName == null) { throw new ApiException( - "Missing the required parameter 'routeId' when calling deleteNetworkAreaRoute(Async)"); + "Missing the required parameter 'keypairName' when calling getKeyPair(Async)"); } - return deleteNetworkAreaRouteCall(organizationId, areaId, routeId, _callback); + return getKeyPairCall(keypairName, _callback); } /** - * Delete a network route. Delete a network route of a network area. + * Get SSH keypair details. Get details about an SSH keypair. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param keypairName The name of an SSH keypair. (required) + * @return Keypair * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -6647,28 +11503,23 @@ private okhttp3.Call deleteNetworkAreaRouteValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
202 Delete request for network route has been accepted. -
200 Show SSH keypair details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteNetworkAreaRoute( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId) - throws ApiException { - deleteNetworkAreaRouteWithHttpInfo(organizationId, areaId, routeId); + public Keypair getKeyPair(@javax.annotation.Nonnull String keypairName) throws ApiException { + ApiResponse localVarResp = getKeyPairWithHttpInfo(keypairName); + return localVarResp.getData(); } /** - * Delete a network route. Delete a network route of a network area. + * Get SSH keypair details. Get details about an SSH keypair. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) - * @return ApiResponse<Void> + * @param keypairName The name of an SSH keypair. (required) + * @return ApiResponse<Keypair> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -6676,22 +11527,17 @@ public void deleteNetworkAreaRoute( * *
Response Details
Status Code Description Response Headers
202 Delete request for network route has been accepted. -
200 Show SSH keypair details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteNetworkAreaRouteWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId) + public ApiResponse getKeyPairWithHttpInfo(@javax.annotation.Nonnull String keypairName) throws ApiException { - okhttp3.Call localVarCall = - deleteNetworkAreaRouteValidateBeforeCall(organizationId, areaId, routeId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = getKeyPairValidateBeforeCall(keypairName, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete a network route. (asynchronously) Delete a network route of a network area. + * Get SSH keypair details. (asynchronously) Get details about an SSH keypair. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param keypairName The name of an SSH keypair. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -6700,7 +11546,7 @@ public ApiResponse deleteNetworkAreaRouteWithHttpInfo( * * * - * + * * * * @@ -6708,26 +11554,22 @@ public ApiResponse deleteNetworkAreaRouteWithHttpInfo( * *
Response Details
Status Code Description Response Headers
202 Delete request for network route has been accepted. -
200 Show SSH keypair details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNetworkAreaRouteAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - final ApiCallback _callback) + public okhttp3.Call getKeyPairAsync( + @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = - deleteNetworkAreaRouteValidateBeforeCall( - organizationId, areaId, routeId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + okhttp3.Call localVarCall = getKeyPairValidateBeforeCall(keypairName, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteNic + * Build call for getMachineType * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param machineType STACKIT machine type Name. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -6735,7 +11577,7 @@ public okhttp3.Call deleteNetworkAreaRouteAsync( * * * - * + * * * * @@ -6743,10 +11585,10 @@ public okhttp3.Call deleteNetworkAreaRouteAsync( * *
Response Details
Status Code Description Response Headers
204 Network interface delete request has been accepted. -
200 Show machine type details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNicCall( + public okhttp3.Call getMachineTypeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String machineType, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -6766,16 +11608,16 @@ public okhttp3.Call deleteNicCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}/nics/{nicId}" + "/v2beta1/projects/{projectId}/regions/{region}/machine-types/{machineType}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "nicId" + "}", - localVarApiClient.escapeString(nicId.toString())); + "{" + "machineType" + "}", + localVarApiClient.escapeString(machineType.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -6800,7 +11642,7 @@ public okhttp3.Call deleteNicCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6812,46 +11654,47 @@ public okhttp3.Call deleteNicCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteNicValidateBeforeCall( + private okhttp3.Call getMachineTypeValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String machineType, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteNic(Async)"); + "Missing the required parameter 'projectId' when calling getMachineType(Async)"); } - // verify the required parameter 'networkId' is set - if (networkId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'networkId' when calling deleteNic(Async)"); + "Missing the required parameter 'region' when calling getMachineType(Async)"); } - // verify the required parameter 'nicId' is set - if (nicId == null) { + // verify the required parameter 'machineType' is set + if (machineType == null) { throw new ApiException( - "Missing the required parameter 'nicId' when calling deleteNic(Async)"); + "Missing the required parameter 'machineType' when calling getMachineType(Async)"); } - return deleteNicCall(projectId, networkId, nicId, _callback); + return getMachineTypeCall(projectId, region, machineType, _callback); } /** - * Delete a network interface. Delete a network interface that is part of the project. + * Get details about a machine type. Get details about a specific machine type. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param machineType STACKIT machine type Name. (required) + * @return MachineType * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -6859,28 +11702,30 @@ private okhttp3.Call deleteNicValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Network interface delete request has been accepted. -
200 Show machine type details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteNic( + public MachineType getMachineType( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String machineType) throws ApiException { - deleteNicWithHttpInfo(projectId, networkId, nicId); + ApiResponse localVarResp = + getMachineTypeWithHttpInfo(projectId, region, machineType); + return localVarResp.getData(); } /** - * Delete a network interface. Delete a network interface that is part of the project. + * Get details about a machine type. Get details about a specific machine type. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param machineType STACKIT machine type Name. (required) + * @return ApiResponse<MachineType> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -6888,22 +11733,23 @@ public void deleteNic( * *
Response Details
Status Code Description Response Headers
204 Network interface delete request has been accepted. -
200 Show machine type details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteNicWithHttpInfo( + public ApiResponse getMachineTypeWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String machineType) throws ApiException { - okhttp3.Call localVarCall = deleteNicValidateBeforeCall(projectId, networkId, nicId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + getMachineTypeValidateBeforeCall(projectId, region, machineType, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete a network interface. (asynchronously) Delete a network interface that is part of the - * project. + * Get details about a machine type. (asynchronously) Get details about a specific machine type. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param machineType STACKIT machine type Name. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -6912,7 +11758,7 @@ public ApiResponse deleteNicWithHttpInfo( * * * - * + * * * * @@ -6920,24 +11766,26 @@ public ApiResponse deleteNicWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Network interface delete request has been accepted. -
200 Show machine type details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteNicAsync( + public okhttp3.Call getMachineTypeAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String machineType, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteNicValidateBeforeCall(projectId, networkId, nicId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getMachineTypeValidateBeforeCall(projectId, region, machineType, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deletePublicIP + * Build call for getManagementNetworkRoute * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -6945,7 +11793,7 @@ public okhttp3.Call deleteNicAsync( * * * - * + * * * * @@ -6953,9 +11801,10 @@ public okhttp3.Call deleteNicAsync( * *
Response Details
Status Code Description Response Headers
204 The public IP has been deleted. -
200 Show management route details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deletePublicIPCall( + public okhttp3.Call getManagementNetworkRouteCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -6975,13 +11824,16 @@ public okhttp3.Call deletePublicIPCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/public-ips/{publicIpId}" + "/v2beta1/projects/{projectId}/regions/{region}/management-network/routes/{routeId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "publicIpId" + "}", - localVarApiClient.escapeString(publicIpId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -7006,7 +11858,7 @@ public okhttp3.Call deletePublicIPCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7018,38 +11870,47 @@ public okhttp3.Call deletePublicIPCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deletePublicIPValidateBeforeCall( + private okhttp3.Call getManagementNetworkRouteValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deletePublicIP(Async)"); + "Missing the required parameter 'projectId' when calling getManagementNetworkRoute(Async)"); } - // verify the required parameter 'publicIpId' is set - if (publicIpId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'publicIpId' when calling deletePublicIP(Async)"); + "Missing the required parameter 'region' when calling getManagementNetworkRoute(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { + throw new ApiException( + "Missing the required parameter 'routeId' when calling getManagementNetworkRoute(Async)"); } - return deletePublicIPCall(projectId, publicIpId, _callback); + return getManagementNetworkRouteCall(projectId, region, routeId, _callback); } /** - * Delete a public IP. Delete a public IP that is part of the project. + * Get management network route details. Get details about a management network route. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return ManagementRoute * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -7057,25 +11918,30 @@ private okhttp3.Call deletePublicIPValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 The public IP has been deleted. -
200 Show management route details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deletePublicIP( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID publicIpId) + public ManagementRoute getManagementNetworkRoute( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId) throws ApiException { - deletePublicIPWithHttpInfo(projectId, publicIpId); + ApiResponse localVarResp = + getManagementNetworkRouteWithHttpInfo(projectId, region, routeId); + return localVarResp.getData(); } /** - * Delete a public IP. Delete a public IP that is part of the project. + * Get management network route details. Get details about a management network route. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return ApiResponse<ManagementRoute> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -7083,18 +11949,24 @@ public void deletePublicIP( * *
Response Details
Status Code Description Response Headers
204 The public IP has been deleted. -
200 Show management route details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deletePublicIPWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID publicIpId) + public ApiResponse getManagementNetworkRouteWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId) throws ApiException { - okhttp3.Call localVarCall = deletePublicIPValidateBeforeCall(projectId, publicIpId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + getManagementNetworkRouteValidateBeforeCall(projectId, region, routeId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete a public IP. (asynchronously) Delete a public IP that is part of the project. + * Get management network route details. (asynchronously) Get details about a management network + * route. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -7103,7 +11975,7 @@ public ApiResponse deletePublicIPWithHttpInfo( * * * - * + * * * * @@ -7111,23 +11983,26 @@ public ApiResponse deletePublicIPWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 The public IP has been deleted. -
200 Show management route details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deletePublicIPAsync( + public okhttp3.Call getManagementNetworkRouteAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deletePublicIPValidateBeforeCall(projectId, publicIpId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getManagementNetworkRouteValidateBeforeCall(projectId, region, routeId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteSecurityGroup + * Build call for getNetwork * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -7135,18 +12010,18 @@ public okhttp3.Call deletePublicIPAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Delete request for security group has been accepted. -
200 Show network details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteSecurityGroupCall( + public okhttp3.Call getNetworkCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -7166,13 +12041,16 @@ public okhttp3.Call deleteSecurityGroupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}" + "/v2beta1/projects/{projectId}/regions/{region}/networks/{networkId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -7197,7 +12075,7 @@ public okhttp3.Call deleteSecurityGroupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7209,88 +12087,101 @@ public okhttp3.Call deleteSecurityGroupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteSecurityGroupValidateBeforeCall( + private okhttp3.Call getNetworkValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteSecurityGroup(Async)"); + "Missing the required parameter 'projectId' when calling getNetwork(Async)"); } - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling deleteSecurityGroup(Async)"); + "Missing the required parameter 'region' when calling getNetwork(Async)"); + } + + // verify the required parameter 'networkId' is set + if (networkId == null) { + throw new ApiException( + "Missing the required parameter 'networkId' when calling getNetwork(Async)"); } - return deleteSecurityGroupCall(projectId, securityGroupId, _callback); + return getNetworkCall(projectId, region, networkId, _callback); } /** - * Delete security group. Delete a security group. + * Get network details. Get details about a network of a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @return Network * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Delete request for security group has been accepted. -
200 Show network details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteSecurityGroup( + public Network getNetwork( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId) throws ApiException { - deleteSecurityGroupWithHttpInfo(projectId, securityGroupId); + ApiResponse localVarResp = getNetworkWithHttpInfo(projectId, region, networkId); + return localVarResp.getData(); } /** - * Delete security group. Delete a security group. + * Get network details. Get details about a network of a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @return ApiResponse<Network> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Delete request for security group has been accepted. -
200 Show network details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteSecurityGroupWithHttpInfo( + public ApiResponse getNetworkWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId) throws ApiException { okhttp3.Call localVarCall = - deleteSecurityGroupValidateBeforeCall(projectId, securityGroupId, null); - return localVarApiClient.execute(localVarCall); + getNetworkValidateBeforeCall(projectId, region, networkId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete security group. (asynchronously) Delete a security group. + * Get network details. (asynchronously) Get details about a network of a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -7299,33 +12190,33 @@ public ApiResponse deleteSecurityGroupWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Delete request for security group has been accepted. -
200 Show network details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteSecurityGroupAsync( + public okhttp3.Call getNetworkAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteSecurityGroupValidateBeforeCall(projectId, securityGroupId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getNetworkValidateBeforeCall(projectId, region, networkId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteSecurityGroupRule + * Build call for getNetworkArea * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -7333,7 +12224,7 @@ public okhttp3.Call deleteSecurityGroupAsync( * * * - * + * * * * @@ -7341,10 +12232,9 @@ public okhttp3.Call deleteSecurityGroupAsync( * *
Response Details
Status Code Description Response Headers
204 Delete request for security group rule has been accepted. -
200 Show network area details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteSecurityGroupRuleCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId, + public okhttp3.Call getNetworkAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -7364,16 +12254,13 @@ public okhttp3.Call deleteSecurityGroupRuleCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}/rules/{securityGroupRuleId}" - .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}" .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "securityGroupRuleId" + "}", - localVarApiClient.escapeString(securityGroupRuleId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -7398,7 +12285,7 @@ public okhttp3.Call deleteSecurityGroupRuleCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7410,47 +12297,39 @@ public okhttp3.Call deleteSecurityGroupRuleCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteSecurityGroupRuleValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId, + private okhttp3.Call getNetworkAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { - throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteSecurityGroupRule(Async)"); - } - - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling deleteSecurityGroupRule(Async)"); + "Missing the required parameter 'organizationId' when calling getNetworkArea(Async)"); } - // verify the required parameter 'securityGroupRuleId' is set - if (securityGroupRuleId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'securityGroupRuleId' when calling deleteSecurityGroupRule(Async)"); + "Missing the required parameter 'areaId' when calling getNetworkArea(Async)"); } - return deleteSecurityGroupRuleCall( - projectId, securityGroupId, securityGroupRuleId, _callback); + return getNetworkAreaCall(organizationId, areaId, _callback); } /** - * Delete security group rule. Delete a security group rule. + * Get details about a network area. Get details about a network area in an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @return NetworkArea * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -7458,28 +12337,26 @@ private okhttp3.Call deleteSecurityGroupRuleValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Delete request for security group rule has been accepted. -
200 Show network area details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteSecurityGroupRule( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId) + public NetworkArea getNetworkArea( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) throws ApiException { - deleteSecurityGroupRuleWithHttpInfo(projectId, securityGroupId, securityGroupRuleId); + ApiResponse localVarResp = getNetworkAreaWithHttpInfo(organizationId, areaId); + return localVarResp.getData(); } /** - * Delete security group rule. Delete a security group rule. + * Get details about a network area. Get details about a network area in an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) - * @return ApiResponse<Void> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @return ApiResponse<NetworkArea> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -7487,23 +12364,20 @@ public void deleteSecurityGroupRule( * *
Response Details
Status Code Description Response Headers
204 Delete request for security group rule has been accepted. -
200 Show network area details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteSecurityGroupRuleWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId) + public ApiResponse getNetworkAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) throws ApiException { - okhttp3.Call localVarCall = - deleteSecurityGroupRuleValidateBeforeCall( - projectId, securityGroupId, securityGroupRuleId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = getNetworkAreaValidateBeforeCall(organizationId, areaId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete security group rule. (asynchronously) Delete a security group rule. + * Get details about a network area. (asynchronously) Get details about a network area in an + * organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -7512,7 +12386,7 @@ public ApiResponse deleteSecurityGroupRuleWithHttpInfo( * * * - * + * * * * @@ -7520,25 +12394,26 @@ public ApiResponse deleteSecurityGroupRuleWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Delete request for security group rule has been accepted. -
200 Show network area details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteSecurityGroupRuleAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId, - final ApiCallback _callback) + public okhttp3.Call getNetworkAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteSecurityGroupRuleValidateBeforeCall( - projectId, securityGroupId, securityGroupRuleId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getNetworkAreaValidateBeforeCall(organizationId, areaId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteServer + * Build call for getNetworkAreaRange * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -7546,7 +12421,7 @@ public okhttp3.Call deleteSecurityGroupRuleAsync( * * * - * + * * * * @@ -7554,9 +12429,11 @@ public okhttp3.Call deleteSecurityGroupRuleAsync( * *
Response Details
Status Code Description Response Headers
204 Delete request for server accepted. -
200 Show network range details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteServerCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + public okhttp3.Call getNetworkAreaRangeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -7576,13 +12453,19 @@ public okhttp3.Call deleteServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/network-ranges/{networkRangeId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkRangeId" + "}", + localVarApiClient.escapeString(networkRangeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -7607,7 +12490,7 @@ public okhttp3.Call deleteServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7619,38 +12502,55 @@ public okhttp3.Call deleteServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteServerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + private okhttp3.Call getNetworkAreaRangeValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteServer(Async)"); + "Missing the required parameter 'organizationId' when calling getNetworkAreaRange(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling getNetworkAreaRange(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling getNetworkAreaRange(Async)"); + } + + // verify the required parameter 'networkRangeId' is set + if (networkRangeId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling deleteServer(Async)"); + "Missing the required parameter 'networkRangeId' when calling getNetworkAreaRange(Async)"); } - return deleteServerCall(projectId, serverId, _callback); + return getNetworkAreaRangeCall(organizationId, areaId, region, networkRangeId, _callback); } /** - * Delete a server. Delete a server. Volumes won't be deleted. + * Get details about a network range. Get details about a network range in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @return NetworkRange * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -7658,25 +12558,32 @@ private okhttp3.Call deleteServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Delete request for server accepted. -
200 Show network range details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteServer( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public NetworkRange getNetworkAreaRange( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId) throws ApiException { - deleteServerWithHttpInfo(projectId, serverId); + ApiResponse localVarResp = + getNetworkAreaRangeWithHttpInfo(organizationId, areaId, region, networkRangeId); + return localVarResp.getData(); } /** - * Delete a server. Delete a server. Volumes won't be deleted. + * Get details about a network range. Get details about a network range in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ApiResponse<Void> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @return ApiResponse<NetworkRange> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -7684,18 +12591,27 @@ public void deleteServer( * *
Response Details
Status Code Description Response Headers
204 Delete request for server accepted. -
200 Show network range details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse getNetworkAreaRangeWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId) throws ApiException { - okhttp3.Call localVarCall = deleteServerValidateBeforeCall(projectId, serverId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + getNetworkAreaRangeValidateBeforeCall( + organizationId, areaId, region, networkRangeId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete a server. (asynchronously) Delete a server. Volumes won't be deleted. + * Get details about a network range. (asynchronously) Get details about a network range in a + * network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -7704,7 +12620,7 @@ public ApiResponse deleteServerWithHttpInfo( * * * - * + * * * * @@ -7712,22 +12628,29 @@ public ApiResponse deleteServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Delete request for server accepted. -
200 Show network range details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteServerAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) + public okhttp3.Call getNetworkAreaRangeAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkRangeId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = deleteServerValidateBeforeCall(projectId, serverId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + okhttp3.Call localVarCall = + getNetworkAreaRangeValidateBeforeCall( + organizationId, areaId, region, networkRangeId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteSnapshot + * Build call for getNetworkAreaRoute * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -7735,7 +12658,7 @@ public okhttp3.Call deleteServerAsync( * * * - * + * * * * @@ -7743,9 +12666,11 @@ public okhttp3.Call deleteServerAsync( * *
Response Details
Status Code Description Response Headers
204 Snapshot delete request has been accepted. -
200 Show route details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteSnapshotCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, + public okhttp3.Call getNetworkAreaRouteCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -7765,13 +12690,19 @@ public okhttp3.Call deleteSnapshotCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots/{snapshotId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routes/{routeId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "snapshotId" + "}", - localVarApiClient.escapeString(snapshotId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -7796,7 +12727,7 @@ public okhttp3.Call deleteSnapshotCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7808,38 +12739,56 @@ public okhttp3.Call deleteSnapshotCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteSnapshotValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, + private okhttp3.Call getNetworkAreaRouteValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteSnapshot(Async)"); + "Missing the required parameter 'organizationId' when calling getNetworkAreaRoute(Async)"); } - // verify the required parameter 'snapshotId' is set - if (snapshotId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling getNetworkAreaRoute(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling getNetworkAreaRoute(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { throw new ApiException( - "Missing the required parameter 'snapshotId' when calling deleteSnapshot(Async)"); + "Missing the required parameter 'routeId' when calling getNetworkAreaRoute(Async)"); } - return deleteSnapshotCall(projectId, snapshotId, _callback); + return getNetworkAreaRouteCall(organizationId, areaId, region, routeId, _callback); } /** - * Delete a snapshot. Delete a snapshot that is part of the project. + * Get details about a network route. Get details about a network route defined in a network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return Route * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -7847,25 +12796,33 @@ private okhttp3.Call deleteSnapshotValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Snapshot delete request has been accepted. -
200 Show route details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteSnapshot( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID snapshotId) + public Route getNetworkAreaRoute( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId) throws ApiException { - deleteSnapshotWithHttpInfo(projectId, snapshotId); + ApiResponse localVarResp = + getNetworkAreaRouteWithHttpInfo(organizationId, areaId, region, routeId); + return localVarResp.getData(); } /** - * Delete a snapshot. Delete a snapshot that is part of the project. + * Get details about a network route. Get details about a network route defined in a network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) - * @return ApiResponse<Void> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return ApiResponse<Route> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -7873,18 +12830,27 @@ public void deleteSnapshot( * *
Response Details
Status Code Description Response Headers
204 Snapshot delete request has been accepted. -
200 Show route details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteSnapshotWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID snapshotId) + public ApiResponse getNetworkAreaRouteWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId) throws ApiException { - okhttp3.Call localVarCall = deleteSnapshotValidateBeforeCall(projectId, snapshotId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + getNetworkAreaRouteValidateBeforeCall( + organizationId, areaId, region, routeId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete a snapshot. (asynchronously) Delete a snapshot that is part of the project. + * Get details about a network route. (asynchronously) Get details about a network route defined + * in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -7893,7 +12859,7 @@ public ApiResponse deleteSnapshotWithHttpInfo( * * * - * + * * * * @@ -7901,23 +12867,29 @@ public ApiResponse deleteSnapshotWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Snapshot delete request has been accepted. -
200 Show route details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteSnapshotAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, - final ApiCallback _callback) + public okhttp3.Call getNetworkAreaRouteAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - deleteSnapshotValidateBeforeCall(projectId, snapshotId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + getNetworkAreaRouteValidateBeforeCall( + organizationId, areaId, region, routeId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for deleteVolume + * Build call for getNic * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -7925,18 +12897,19 @@ public okhttp3.Call deleteSnapshotAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Volume delete request has been accepted. -
200 Show network interface details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteVolumeCall( + public okhttp3.Call getNicCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -7956,13 +12929,19 @@ public okhttp3.Call deleteVolumeCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes/{volumeId}" + "/v2beta1/projects/{projectId}/regions/{region}/networks/{networkId}/nics/{nicId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "volumeId" + "}", - localVarApiClient.escapeString(volumeId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())) + .replace( + "{" + "nicId" + "}", + localVarApiClient.escapeString(nicId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -7987,7 +12966,7 @@ public okhttp3.Call deleteVolumeCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7999,88 +12978,116 @@ public okhttp3.Call deleteVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call deleteVolumeValidateBeforeCall( + private okhttp3.Call getNicValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling deleteVolume(Async)"); + "Missing the required parameter 'projectId' when calling getNic(Async)"); } - // verify the required parameter 'volumeId' is set - if (volumeId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'volumeId' when calling deleteVolume(Async)"); + "Missing the required parameter 'region' when calling getNic(Async)"); + } + + // verify the required parameter 'networkId' is set + if (networkId == null) { + throw new ApiException( + "Missing the required parameter 'networkId' when calling getNic(Async)"); } - return deleteVolumeCall(projectId, volumeId, _callback); + // verify the required parameter 'nicId' is set + if (nicId == null) { + throw new ApiException( + "Missing the required parameter 'nicId' when calling getNic(Async)"); + } + + return getNicCall(projectId, region, networkId, nicId, _callback); } /** - * Delete a volume. Delete a volume inside a project. The deletion will fail if the volume is - * still in use. + * Get details about a network interface. Get details about a network interface inside a + * network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @return NIC * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Volume delete request has been accepted. -
200 Show network interface details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void deleteVolume( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID volumeId) + public NIC getNic( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId) throws ApiException { - deleteVolumeWithHttpInfo(projectId, volumeId); + ApiResponse localVarResp = getNicWithHttpInfo(projectId, region, networkId, nicId); + return localVarResp.getData(); } /** - * Delete a volume. Delete a volume inside a project. The deletion will fail if the volume is - * still in use. + * Get details about a network interface. Get details about a network interface inside a + * network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @return ApiResponse<NIC> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Volume delete request has been accepted. -
200 Show network interface details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse deleteVolumeWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID volumeId) + public ApiResponse getNicWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId) throws ApiException { - okhttp3.Call localVarCall = deleteVolumeValidateBeforeCall(projectId, volumeId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + getNicValidateBeforeCall(projectId, region, networkId, nicId, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Delete a volume. (asynchronously) Delete a volume inside a project. The deletion will fail if - * the volume is still in use. + * Get details about a network interface. (asynchronously) Get details about a network interface + * inside a network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -8089,31 +13096,34 @@ public ApiResponse deleteVolumeWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Volume delete request has been accepted. -
200 Show network interface details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call deleteVolumeAsync( + public okhttp3.Call getNicAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = deleteVolumeValidateBeforeCall(projectId, volumeId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + okhttp3.Call localVarCall = + getNicValidateBeforeCall(projectId, region, networkId, nicId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getAffinityGroup + * Build call for getOrganizationRequest * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param requestId The identifier (ID) of a STACKIT Request. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -8121,7 +13131,7 @@ public okhttp3.Call deleteVolumeAsync( * * * - * + * * * * @@ -8129,9 +13139,9 @@ public okhttp3.Call deleteVolumeAsync( * *
Response Details
Status Code Description Response Headers
200 Show affinity group details. -
200 Show organization request details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getAffinityGroupCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId, + public okhttp3.Call getOrganizationRequestCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull String requestId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -8151,13 +13161,13 @@ public okhttp3.Call getAffinityGroupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/affinity-groups/{affinityGroupId}" + "/v2beta1/organizations/{organizationId}/requests/{requestId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "affinityGroupId" + "}", - localVarApiClient.escapeString(affinityGroupId.toString())); + "{" + "requestId" + "}", + localVarApiClient.escapeString(requestId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -8194,39 +13204,40 @@ public okhttp3.Call getAffinityGroupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getAffinityGroupValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId, + private okhttp3.Call getOrganizationRequestValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull String requestId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getAffinityGroup(Async)"); + "Missing the required parameter 'organizationId' when calling getOrganizationRequest(Async)"); } - // verify the required parameter 'affinityGroupId' is set - if (affinityGroupId == null) { + // verify the required parameter 'requestId' is set + if (requestId == null) { throw new ApiException( - "Missing the required parameter 'affinityGroupId' when calling getAffinityGroup(Async)"); + "Missing the required parameter 'requestId' when calling getOrganizationRequest(Async)"); } - return getAffinityGroupCall(projectId, affinityGroupId, _callback); + return getOrganizationRequestCall(organizationId, requestId, _callback); } /** - * Get the affinity group. Get the affinity group created in a project. + * Lookup an organization request ID. Lookup an organization request ID from a previous request. + * This allows to find resource IDs of resources generated during a organization request. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) - * @return AffinityGroup + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param requestId The identifier (ID) of a STACKIT Request. (required) + * @return Request * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -8234,28 +13245,29 @@ private okhttp3.Call getAffinityGroupValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show affinity group details. -
200 Show organization request details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public AffinityGroup getAffinityGroup( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId) + public Request getOrganizationRequest( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull String requestId) throws ApiException { - ApiResponse localVarResp = - getAffinityGroupWithHttpInfo(projectId, affinityGroupId); + ApiResponse localVarResp = + getOrganizationRequestWithHttpInfo(organizationId, requestId); return localVarResp.getData(); } /** - * Get the affinity group. Get the affinity group created in a project. + * Lookup an organization request ID. Lookup an organization request ID from a previous request. + * This allows to find resource IDs of resources generated during a organization request. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) - * @return ApiResponse<AffinityGroup> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param requestId The identifier (ID) of a STACKIT Request. (required) + * @return ApiResponse<Request> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -8263,21 +13275,23 @@ public AffinityGroup getAffinityGroup( * *
Response Details
Status Code Description Response Headers
200 Show affinity group details. -
200 Show organization request details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getAffinityGroupWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId) + public ApiResponse getOrganizationRequestWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull String requestId) throws ApiException { okhttp3.Call localVarCall = - getAffinityGroupValidateBeforeCall(projectId, affinityGroupId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + getOrganizationRequestValidateBeforeCall(organizationId, requestId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get the affinity group. (asynchronously) Get the affinity group created in a project. + * Lookup an organization request ID. (asynchronously) Lookup an organization request ID from a + * previous request. This allows to find resource IDs of resources generated during a + * organization request. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param affinityGroupId The identifier (ID) of a STACKIT Affinity Group. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param requestId The identifier (ID) of a STACKIT Request. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -8286,7 +13300,7 @@ public ApiResponse getAffinityGroupWithHttpInfo( * * * - * + * * * * @@ -8294,25 +13308,23 @@ public ApiResponse getAffinityGroupWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show affinity group details. -
200 Show organization request details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getAffinityGroupAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID affinityGroupId, - final ApiCallback _callback) + public okhttp3.Call getOrganizationRequestAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull String requestId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getAffinityGroupValidateBeforeCall(projectId, affinityGroupId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + getOrganizationRequestValidateBeforeCall(organizationId, requestId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getAttachedVolume + * Build call for getProjectDetails * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -8320,7 +13332,7 @@ public okhttp3.Call getAffinityGroupAsync( * * * - * + * * * * @@ -8328,11 +13340,8 @@ public okhttp3.Call getAffinityGroupAsync( * *
Response Details
Status Code Description Response Headers
200 Get details about a volume attachment. -
200 Show project details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getAttachedVolumeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - final ApiCallback _callback) + public okhttp3.Call getProjectDetailsCall( + @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -8351,16 +13360,10 @@ public okhttp3.Call getAttachedVolumeCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/volume-attachments/{volumeId}" + "/v2beta1/projects/{projectId}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) - .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) - .replace( - "{" + "volumeId" + "}", - localVarApiClient.escapeString(volumeId.toString())); + localVarApiClient.escapeString(projectId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -8397,47 +13400,30 @@ public okhttp3.Call getAttachedVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getAttachedVolumeValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - final ApiCallback _callback) + private okhttp3.Call getProjectDetailsValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getAttachedVolume(Async)"); - } - - // verify the required parameter 'serverId' is set - if (serverId == null) { - throw new ApiException( - "Missing the required parameter 'serverId' when calling getAttachedVolume(Async)"); - } - - // verify the required parameter 'volumeId' is set - if (volumeId == null) { - throw new ApiException( - "Missing the required parameter 'volumeId' when calling getAttachedVolume(Async)"); + "Missing the required parameter 'projectId' when calling getProjectDetails(Async)"); } - return getAttachedVolumeCall(projectId, serverId, volumeId, _callback); + return getProjectDetailsCall(projectId, _callback); } /** - * Get Volume Attachment details. Get the details of an existing Volume Attachment. + * Get project details. Get details about a STACKIT project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @return VolumeAttachment + * @return Project * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -8445,30 +13431,23 @@ private okhttp3.Call getAttachedVolumeValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Get details about a volume attachment. -
200 Show project details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public VolumeAttachment getAttachedVolume( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId) - throws ApiException { - ApiResponse localVarResp = - getAttachedVolumeWithHttpInfo(projectId, serverId, volumeId); + public Project getProjectDetails(@javax.annotation.Nonnull UUID projectId) throws ApiException { + ApiResponse localVarResp = getProjectDetailsWithHttpInfo(projectId); return localVarResp.getData(); } /** - * Get Volume Attachment details. Get the details of an existing Volume Attachment. + * Get project details. Get details about a STACKIT project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @return ApiResponse<VolumeAttachment> + * @return ApiResponse<Project> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -8476,24 +13455,17 @@ public VolumeAttachment getAttachedVolume( * *
Response Details
Status Code Description Response Headers
200 Get details about a volume attachment. -
200 Show project details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getAttachedVolumeWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId) - throws ApiException { - okhttp3.Call localVarCall = - getAttachedVolumeValidateBeforeCall(projectId, serverId, volumeId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + public ApiResponse getProjectDetailsWithHttpInfo( + @javax.annotation.Nonnull UUID projectId) throws ApiException { + okhttp3.Call localVarCall = getProjectDetailsValidateBeforeCall(projectId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get Volume Attachment details. (asynchronously) Get the details of an existing Volume - * Attachment. + * Get project details. (asynchronously) Get details about a STACKIT project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -8502,7 +13474,7 @@ public ApiResponse getAttachedVolumeWithHttpInfo( * * * - * + * * * * @@ -8510,25 +13482,22 @@ public ApiResponse getAttachedVolumeWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Get details about a volume attachment. -
200 Show project details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getAttachedVolumeAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - final ApiCallback _callback) + public okhttp3.Call getProjectDetailsAsync( + @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = - getAttachedVolumeValidateBeforeCall(projectId, serverId, volumeId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = getProjectDetailsValidateBeforeCall(projectId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getBackup + * Build call for getProjectNIC * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param region The STACKIT Region of the resources. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -8536,7 +13505,7 @@ public okhttp3.Call getAttachedVolumeAsync( * * * - * + * * * * @@ -8544,9 +13513,10 @@ public okhttp3.Call getAttachedVolumeAsync( * *
Response Details
Status Code Description Response Headers
200 Show backup details. -
200 Show details of network interface. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getBackupCall( + public okhttp3.Call getProjectNICCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -8566,13 +13536,16 @@ public okhttp3.Call getBackupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups/{backupId}" + "/v2beta1/projects/{projectId}/regions/{region}/nics/{nicId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "backupId" + "}", - localVarApiClient.escapeString(backupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "nicId" + "}", + localVarApiClient.escapeString(nicId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -8609,39 +13582,48 @@ public okhttp3.Call getBackupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getBackupValidateBeforeCall( + private okhttp3.Call getProjectNICValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getBackup(Async)"); + "Missing the required parameter 'projectId' when calling getProjectNIC(Async)"); } - // verify the required parameter 'backupId' is set - if (backupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'backupId' when calling getBackup(Async)"); + "Missing the required parameter 'region' when calling getProjectNIC(Async)"); + } + + // verify the required parameter 'nicId' is set + if (nicId == null) { + throw new ApiException( + "Missing the required parameter 'nicId' when calling getProjectNIC(Async)"); } - return getBackupCall(projectId, backupId, _callback); + return getProjectNICCall(projectId, region, nicId, _callback); } /** - * Get details about a backup. Get details about a block device backup. + * Get details about a network interface of a project. Get details about a network interface + * inside a project. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @return Backup + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @return NIC * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -8649,26 +13631,30 @@ private okhttp3.Call getBackupValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show backup details. -
200 Show details of network interface. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Backup getBackup( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID backupId) + public NIC getProjectNIC( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID nicId) throws ApiException { - ApiResponse localVarResp = getBackupWithHttpInfo(projectId, backupId); + ApiResponse localVarResp = getProjectNICWithHttpInfo(projectId, region, nicId); return localVarResp.getData(); } /** - * Get details about a backup. Get details about a block device backup. + * Get details about a network interface of a project. Get details about a network interface + * inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @return ApiResponse<Backup> + * @param region The STACKIT Region of the resources. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @return ApiResponse<NIC> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -8676,19 +13662,23 @@ public Backup getBackup( * *
Response Details
Status Code Description Response Headers
200 Show backup details. -
200 Show details of network interface. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getBackupWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID backupId) + public ApiResponse getProjectNICWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID nicId) throws ApiException { - okhttp3.Call localVarCall = getBackupValidateBeforeCall(projectId, backupId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = getProjectNICValidateBeforeCall(projectId, region, nicId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a backup. (asynchronously) Get details about a block device backup. + * Get details about a network interface of a project. (asynchronously) Get details about a + * network interface inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param region The STACKIT Region of the resources. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -8697,7 +13687,7 @@ public ApiResponse getBackupWithHttpInfo( * * * - * + * * * * @@ -8705,23 +13695,26 @@ public ApiResponse getBackupWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show backup details. -
200 Show details of network interface. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getBackupAsync( + public okhttp3.Call getProjectNICAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID nicId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getBackupValidateBeforeCall(projectId, backupId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getProjectNICValidateBeforeCall(projectId, region, nicId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getImage + * Build call for getProjectRequest * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param requestId The identifier (ID) of a STACKIT Request. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -8729,7 +13722,7 @@ public okhttp3.Call getBackupAsync( * * * - * + * * * * @@ -8737,9 +13730,10 @@ public okhttp3.Call getBackupAsync( * *
Response Details
Status Code Description Response Headers
200 Show Image details. -
200 Show project request details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getImageCall( + public okhttp3.Call getProjectRequestCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String requestId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -8759,13 +13753,16 @@ public okhttp3.Call getImageCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}" + "/v2beta1/projects/{projectId}/regions/{region}/requests/{requestId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "requestId" + "}", + localVarApiClient.escapeString(requestId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -8802,39 +13799,48 @@ public okhttp3.Call getImageCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getImageValidateBeforeCall( + private okhttp3.Call getProjectRequestValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String requestId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getImage(Async)"); + "Missing the required parameter 'projectId' when calling getProjectRequest(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling getImage(Async)"); + "Missing the required parameter 'region' when calling getProjectRequest(Async)"); } - return getImageCall(projectId, imageId, _callback); + // verify the required parameter 'requestId' is set + if (requestId == null) { + throw new ApiException( + "Missing the required parameter 'requestId' when calling getProjectRequest(Async)"); + } + + return getProjectRequestCall(projectId, region, requestId, _callback); } /** - * Get details about an image. Get details about a specific Image inside a project. + * Lookup a project request ID. Lookup a project request ID from a previous request. This allows + * to find resource IDs of resources generated during a projects request. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return Image + * @param region The STACKIT Region of the resources. (required) + * @param requestId The identifier (ID) of a STACKIT Request. (required) + * @return Request * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -8842,26 +13848,31 @@ private okhttp3.Call getImageValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show Image details. -
200 Show project request details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Image getImage( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public Request getProjectRequest( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String requestId) throws ApiException { - ApiResponse localVarResp = getImageWithHttpInfo(projectId, imageId); + ApiResponse localVarResp = + getProjectRequestWithHttpInfo(projectId, region, requestId); return localVarResp.getData(); } /** - * Get details about an image. Get details about a specific Image inside a project. + * Lookup a project request ID. Lookup a project request ID from a previous request. This allows + * to find resource IDs of resources generated during a projects request. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return ApiResponse<Image> + * @param region The STACKIT Region of the resources. (required) + * @param requestId The identifier (ID) of a STACKIT Request. (required) + * @return ApiResponse<Request> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -8869,20 +13880,24 @@ public Image getImage( * *
Response Details
Status Code Description Response Headers
200 Show Image details. -
200 Show project request details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getImageWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public ApiResponse getProjectRequestWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String requestId) throws ApiException { - okhttp3.Call localVarCall = getImageValidateBeforeCall(projectId, imageId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getProjectRequestValidateBeforeCall(projectId, region, requestId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about an image. (asynchronously) Get details about a specific Image inside a - * project. + * Lookup a project request ID. (asynchronously) Lookup a project request ID from a previous + * request. This allows to find resource IDs of resources generated during a projects request. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param requestId The identifier (ID) of a STACKIT Request. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -8891,7 +13906,7 @@ public ApiResponse getImageWithHttpInfo( * * * - * + * * * * @@ -8899,23 +13914,26 @@ public ApiResponse getImageWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show Image details. -
200 Show project request details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getImageAsync( + public okhttp3.Call getProjectRequestAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String requestId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getImageValidateBeforeCall(projectId, imageId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getProjectRequestValidateBeforeCall(projectId, region, requestId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getImageShare + * Build call for getPublicIP * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -8923,7 +13941,7 @@ public okhttp3.Call getImageAsync( * * * - * + * * * * @@ -8931,9 +13949,10 @@ public okhttp3.Call getImageAsync( * *
Response Details
Status Code Description Response Headers
200 Show Image share details. -
200 Show public IP details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getImageShareCall( + public okhttp3.Call getPublicIPCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -8953,13 +13972,16 @@ public okhttp3.Call getImageShareCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share" + "/v2beta1/projects/{projectId}/regions/{region}/public-ips/{publicIpId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "publicIpId" + "}", + localVarApiClient.escapeString(publicIpId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -8996,39 +14018,47 @@ public okhttp3.Call getImageShareCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getImageShareValidateBeforeCall( + private okhttp3.Call getPublicIPValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getImageShare(Async)"); + "Missing the required parameter 'projectId' when calling getPublicIP(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling getImageShare(Async)"); + "Missing the required parameter 'region' when calling getPublicIP(Async)"); + } + + // verify the required parameter 'publicIpId' is set + if (publicIpId == null) { + throw new ApiException( + "Missing the required parameter 'publicIpId' when calling getPublicIP(Async)"); } - return getImageShareCall(projectId, imageId, _callback); + return getPublicIPCall(projectId, region, publicIpId, _callback); } /** - * Get share details of an image. Get share details about an shared image. + * Get details about a public IP. Get details about a public IP inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return ImageShare + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) + * @return PublicIp * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9036,26 +14066,29 @@ private okhttp3.Call getImageShareValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show Image share details. -
200 Show public IP details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ImageShare getImageShare( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public PublicIp getPublicIP( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId) throws ApiException { - ApiResponse localVarResp = getImageShareWithHttpInfo(projectId, imageId); + ApiResponse localVarResp = getPublicIPWithHttpInfo(projectId, region, publicIpId); return localVarResp.getData(); } /** - * Get share details of an image. Get share details about an shared image. + * Get details about a public IP. Get details about a public IP inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return ApiResponse<ImageShare> + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) + * @return ApiResponse<PublicIp> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9063,19 +14096,24 @@ public ImageShare getImageShare( * *
Response Details
Status Code Description Response Headers
200 Show Image share details. -
200 Show public IP details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getImageShareWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public ApiResponse getPublicIPWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId) throws ApiException { - okhttp3.Call localVarCall = getImageShareValidateBeforeCall(projectId, imageId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getPublicIPValidateBeforeCall(projectId, region, publicIpId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get share details of an image. (asynchronously) Get share details about an shared image. + * Get details about a public IP. (asynchronously) Get details about a public IP inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -9084,7 +14122,7 @@ public ApiResponse getImageShareWithHttpInfo( * * * - * + * * * * @@ -9092,25 +14130,28 @@ public ApiResponse getImageShareWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show Image share details. -
200 Show public IP details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getImageShareAsync( + public okhttp3.Call getPublicIPAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getImageShareValidateBeforeCall(projectId, imageId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getPublicIPValidateBeforeCall(projectId, region, publicIpId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getImageShareConsumer + * Build call for getRouteOfRoutingTable * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image - * share. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -9118,7 +14159,7 @@ public okhttp3.Call getImageShareAsync( * * * - * + * * * * @@ -9126,10 +14167,12 @@ public okhttp3.Call getImageShareAsync( * *
Response Details
Status Code Description Response Headers
200 Show Image share consumer details. -
200 Show the details of a route in a routing table. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getImageShareConsumerCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId, + public okhttp3.Call getRouteOfRoutingTableCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -9149,16 +14192,22 @@ public okhttp3.Call getImageShareConsumerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share/{consumerProjectId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables/{routingTableId}/routes/{routeId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())) + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) .replace( - "{" + "consumerProjectId" + "}", - localVarApiClient.escapeString(consumerProjectId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -9195,48 +14244,65 @@ public okhttp3.Call getImageShareConsumerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getImageShareConsumerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId, + private okhttp3.Call getRouteOfRoutingTableValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getImageShareConsumer(Async)"); + "Missing the required parameter 'organizationId' when calling getRouteOfRoutingTable(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling getImageShareConsumer(Async)"); + "Missing the required parameter 'areaId' when calling getRouteOfRoutingTable(Async)"); } - // verify the required parameter 'consumerProjectId' is set - if (consumerProjectId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'consumerProjectId' when calling getImageShareConsumer(Async)"); + "Missing the required parameter 'region' when calling getRouteOfRoutingTable(Async)"); } - return getImageShareConsumerCall(projectId, imageId, consumerProjectId, _callback); + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { + throw new ApiException( + "Missing the required parameter 'routingTableId' when calling getRouteOfRoutingTable(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { + throw new ApiException( + "Missing the required parameter 'routeId' when calling getRouteOfRoutingTable(Async)"); + } + + return getRouteOfRoutingTableCall( + organizationId, areaId, region, routingTableId, routeId, _callback); } - /** - * Get image share consumer. Get details about an image share consumer. - * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image - * share. (required) - * @return ImageShareConsumer + /** + * Get details about a route of a routing table. Get details about a route defined in a routing + * table. + * + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return Route * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9244,31 +14310,36 @@ private okhttp3.Call getImageShareConsumerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show Image share consumer details. -
200 Show the details of a route in a routing table. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ImageShareConsumer getImageShareConsumer( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId) + public Route getRouteOfRoutingTable( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId) throws ApiException { - ApiResponse localVarResp = - getImageShareConsumerWithHttpInfo(projectId, imageId, consumerProjectId); + ApiResponse localVarResp = + getRouteOfRoutingTableWithHttpInfo( + organizationId, areaId, region, routingTableId, routeId); return localVarResp.getData(); } /** - * Get image share consumer. Get details about an image share consumer. + * Get details about a route of a routing table. Get details about a route defined in a routing + * table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image - * share. (required) - * @return ApiResponse<ImageShareConsumer> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @return ApiResponse<Route> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9276,25 +14347,29 @@ public ImageShareConsumer getImageShareConsumer( * *
Response Details
Status Code Description Response Headers
200 Show Image share consumer details. -
200 Show the details of a route in a routing table. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getImageShareConsumerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId) + public ApiResponse getRouteOfRoutingTableWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId) throws ApiException { okhttp3.Call localVarCall = - getImageShareConsumerValidateBeforeCall( - projectId, imageId, consumerProjectId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + getRouteOfRoutingTableValidateBeforeCall( + organizationId, areaId, region, routingTableId, routeId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get image share consumer. (asynchronously) Get details about an image share consumer. + * Get details about a route of a routing table. (asynchronously) Get details about a route + * defined in a routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param consumerProjectId The identifier (ID) of a STACKIT Project that consumes an image - * share. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -9303,7 +14378,7 @@ public ApiResponse getImageShareConsumerWithHttpInfo( * * * - * + * * * * @@ -9311,25 +14386,30 @@ public ApiResponse getImageShareConsumerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show Image share consumer details. -
200 Show the details of a route in a routing table. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getImageShareConsumerAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UUID consumerProjectId, - final ApiCallback _callback) + public okhttp3.Call getRouteOfRoutingTableAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getImageShareConsumerValidateBeforeCall( - projectId, imageId, consumerProjectId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + getRouteOfRoutingTableValidateBeforeCall( + organizationId, areaId, region, routingTableId, routeId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getKeyPair + * Build call for getRoutingTableOfArea * - * @param keypairName The name of an SSH keypair. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -9337,7 +14417,7 @@ public okhttp3.Call getImageShareConsumerAsync( * * * - * + * * * * @@ -9345,8 +14425,12 @@ public okhttp3.Call getImageShareConsumerAsync( * *
Response Details
Status Code Description Response Headers
200 Show SSH keypair details. -
200 Show routing table details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getKeyPairCall( - @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + public okhttp3.Call getRoutingTableOfAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -9365,10 +14449,19 @@ public okhttp3.Call getKeyPairCall( // create path and map variables String localVarPath = - "/v1/keypairs/{keypairName}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables/{routingTableId}" .replace( - "{" + "keypairName" + "}", - localVarApiClient.escapeString(keypairName.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -9405,30 +14498,56 @@ public okhttp3.Call getKeyPairCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getKeyPairValidateBeforeCall( - @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + private okhttp3.Call getRoutingTableOfAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + final ApiCallback _callback) throws ApiException { - // verify the required parameter 'keypairName' is set - if (keypairName == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'keypairName' when calling getKeyPair(Async)"); + "Missing the required parameter 'organizationId' when calling getRoutingTableOfArea(Async)"); } - return getKeyPairCall(keypairName, _callback); + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling getRoutingTableOfArea(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling getRoutingTableOfArea(Async)"); + } + + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { + throw new ApiException( + "Missing the required parameter 'routingTableId' when calling getRoutingTableOfArea(Async)"); + } + + return getRoutingTableOfAreaCall(organizationId, areaId, region, routingTableId, _callback); } /** - * Get SSH keypair details. Get details about an SSH keypair. + * Get details about a routing table. Get details about a routing table defined in a network + * area. * - * @param keypairName The name of an SSH keypair. (required) - * @return Keypair + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @return RoutingTable * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9436,23 +14555,33 @@ private okhttp3.Call getKeyPairValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show SSH keypair details. -
200 Show routing table details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Keypair getKeyPair(@javax.annotation.Nonnull String keypairName) throws ApiException { - ApiResponse localVarResp = getKeyPairWithHttpInfo(keypairName); + public RoutingTable getRoutingTableOfArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId) + throws ApiException { + ApiResponse localVarResp = + getRoutingTableOfAreaWithHttpInfo(organizationId, areaId, region, routingTableId); return localVarResp.getData(); } /** - * Get SSH keypair details. Get details about an SSH keypair. + * Get details about a routing table. Get details about a routing table defined in a network + * area. * - * @param keypairName The name of an SSH keypair. (required) - * @return ApiResponse<Keypair> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @return ApiResponse<RoutingTable> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9460,17 +14589,27 @@ public Keypair getKeyPair(@javax.annotation.Nonnull String keypairName) throws A * *
Response Details
Status Code Description Response Headers
200 Show SSH keypair details. -
200 Show routing table details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getKeyPairWithHttpInfo(@javax.annotation.Nonnull String keypairName) + public ApiResponse getRoutingTableOfAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId) throws ApiException { - okhttp3.Call localVarCall = getKeyPairValidateBeforeCall(keypairName, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getRoutingTableOfAreaValidateBeforeCall( + organizationId, areaId, region, routingTableId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get SSH keypair details. (asynchronously) Get details about an SSH keypair. + * Get details about a routing table. (asynchronously) Get details about a routing table defined + * in a network area. * - * @param keypairName The name of an SSH keypair. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -9479,7 +14618,7 @@ public ApiResponse getKeyPairWithHttpInfo(@javax.annotation.Nonnull Str * * * - * + * * * * @@ -9487,21 +14626,28 @@ public ApiResponse getKeyPairWithHttpInfo(@javax.annotation.Nonnull Str * *
Response Details
Status Code Description Response Headers
200 Show SSH keypair details. -
200 Show routing table details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getKeyPairAsync( - @javax.annotation.Nonnull String keypairName, final ApiCallback _callback) + public okhttp3.Call getRoutingTableOfAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getKeyPairValidateBeforeCall(keypairName, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getRoutingTableOfAreaValidateBeforeCall( + organizationId, areaId, region, routingTableId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getMachineType + * Build call for getSecurityGroup * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param machineType STACKIT machine type Name. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -9509,7 +14655,7 @@ public okhttp3.Call getKeyPairAsync( * * * - * + * * * * @@ -9517,9 +14663,10 @@ public okhttp3.Call getKeyPairAsync( * *
Response Details
Status Code Description Response Headers
200 Show machine type details. -
200 Show security group details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getMachineTypeCall( + public okhttp3.Call getSecurityGroupCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String machineType, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -9539,13 +14686,16 @@ public okhttp3.Call getMachineTypeCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/machine-types/{machineType}" + "/v2beta1/projects/{projectId}/regions/{region}/security-groups/{securityGroupId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "machineType" + "}", - localVarApiClient.escapeString(machineType.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -9582,39 +14732,47 @@ public okhttp3.Call getMachineTypeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getMachineTypeValidateBeforeCall( + private okhttp3.Call getSecurityGroupValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String machineType, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getMachineType(Async)"); + "Missing the required parameter 'projectId' when calling getSecurityGroup(Async)"); } - // verify the required parameter 'machineType' is set - if (machineType == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'machineType' when calling getMachineType(Async)"); + "Missing the required parameter 'region' when calling getSecurityGroup(Async)"); + } + + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupId' when calling getSecurityGroup(Async)"); } - return getMachineTypeCall(projectId, machineType, _callback); + return getSecurityGroupCall(projectId, region, securityGroupId, _callback); } /** - * Get details about a machine type. Get details about a specific machine type. + * Get security group details. Get details about a security group of a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param machineType STACKIT machine type Name. (required) - * @return MachineType + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @return SecurityGroup * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9622,26 +14780,30 @@ private okhttp3.Call getMachineTypeValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show machine type details. -
200 Show security group details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public MachineType getMachineType( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String machineType) + public SecurityGroup getSecurityGroup( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { - ApiResponse localVarResp = getMachineTypeWithHttpInfo(projectId, machineType); + ApiResponse localVarResp = + getSecurityGroupWithHttpInfo(projectId, region, securityGroupId); return localVarResp.getData(); } /** - * Get details about a machine type. Get details about a specific machine type. + * Get security group details. Get details about a security group of a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param machineType STACKIT machine type Name. (required) - * @return ApiResponse<MachineType> + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @return ApiResponse<SecurityGroup> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9649,19 +14811,23 @@ public MachineType getMachineType( * *
Response Details
Status Code Description Response Headers
200 Show machine type details. -
200 Show security group details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getMachineTypeWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String machineType) + public ApiResponse getSecurityGroupWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { - okhttp3.Call localVarCall = getMachineTypeValidateBeforeCall(projectId, machineType, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getSecurityGroupValidateBeforeCall(projectId, region, securityGroupId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a machine type. (asynchronously) Get details about a specific machine type. + * Get security group details. (asynchronously) Get details about a security group of a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param machineType STACKIT machine type Name. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -9670,7 +14836,7 @@ public ApiResponse getMachineTypeWithHttpInfo( * * * - * + * * * * @@ -9678,24 +14844,27 @@ public ApiResponse getMachineTypeWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show machine type details. -
200 Show security group details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getMachineTypeAsync( + public okhttp3.Call getSecurityGroupAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String machineType, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getMachineTypeValidateBeforeCall(projectId, machineType, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + getSecurityGroupValidateBeforeCall(projectId, region, securityGroupId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getNetwork + * Build call for getSecurityGroupRule * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -9703,7 +14872,7 @@ public okhttp3.Call getMachineTypeAsync( * * * - * + * * * * @@ -9711,9 +14880,11 @@ public okhttp3.Call getMachineTypeAsync( * *
Response Details
Status Code Description Response Headers
200 Show network details. -
200 Show security group rule details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNetworkCall( + public okhttp3.Call getSecurityGroupRuleCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -9733,13 +14904,19 @@ public okhttp3.Call getNetworkCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}" + "/v2beta1/projects/{projectId}/regions/{region}/security-groups/{securityGroupId}/rules/{securityGroupRuleId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())) + .replace( + "{" + "securityGroupRuleId" + "}", + localVarApiClient.escapeString(securityGroupRuleId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -9776,39 +14953,56 @@ public okhttp3.Call getNetworkCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getNetworkValidateBeforeCall( + private okhttp3.Call getSecurityGroupRuleValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getNetwork(Async)"); + "Missing the required parameter 'projectId' when calling getSecurityGroupRule(Async)"); } - // verify the required parameter 'networkId' is set - if (networkId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'networkId' when calling getNetwork(Async)"); + "Missing the required parameter 'region' when calling getSecurityGroupRule(Async)"); + } + + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupId' when calling getSecurityGroupRule(Async)"); + } + + // verify the required parameter 'securityGroupRuleId' is set + if (securityGroupRuleId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupRuleId' when calling getSecurityGroupRule(Async)"); } - return getNetworkCall(projectId, networkId, _callback); + return getSecurityGroupRuleCall( + projectId, region, securityGroupId, securityGroupRuleId, _callback); } /** - * Get network details. Get details about a network of a project. + * Get security group rule details. Get details about a security group rule of a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @return Network + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) + * @return SecurityGroupRule * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9816,26 +15010,33 @@ private okhttp3.Call getNetworkValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show network details. -
200 Show security group rule details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Network getNetwork( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID networkId) + public SecurityGroupRule getSecurityGroupRule( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId) throws ApiException { - ApiResponse localVarResp = getNetworkWithHttpInfo(projectId, networkId); + ApiResponse localVarResp = + getSecurityGroupRuleWithHttpInfo( + projectId, region, securityGroupId, securityGroupRuleId); return localVarResp.getData(); } /** - * Get network details. Get details about a network of a project. + * Get security group rule details. Get details about a security group rule of a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @return ApiResponse<Network> + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) + * @return ApiResponse<SecurityGroupRule> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -9843,19 +15044,27 @@ public Network getNetwork( * *
Response Details
Status Code Description Response Headers
200 Show network details. -
200 Show security group rule details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getNetworkWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID networkId) + public ApiResponse getSecurityGroupRuleWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId) throws ApiException { - okhttp3.Call localVarCall = getNetworkValidateBeforeCall(projectId, networkId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getSecurityGroupRuleValidateBeforeCall( + projectId, region, securityGroupId, securityGroupRuleId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get network details. (asynchronously) Get details about a network of a project. + * Get security group rule details. (asynchronously) Get details about a security group rule of + * a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -9864,7 +15073,7 @@ public ApiResponse getNetworkWithHttpInfo( * * * - * + * * * * @@ -9872,23 +15081,29 @@ public ApiResponse getNetworkWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show network details. -
200 Show security group rule details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNetworkAsync( + public okhttp3.Call getSecurityGroupRuleAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull UUID securityGroupRuleId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getNetworkValidateBeforeCall(projectId, networkId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getSecurityGroupRuleValidateBeforeCall( + projectId, region, securityGroupId, securityGroupRuleId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getNetworkArea + * Build call for getServer * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param details Show detailed information about server. (optional, default to false) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -9896,7 +15111,7 @@ public okhttp3.Call getNetworkAsync( * * * - * + * * * * @@ -9904,9 +15119,11 @@ public okhttp3.Call getNetworkAsync( * *
Response Details
Status Code Description Response Headers
200 Show network area details. -
200 Show server details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNetworkAreaCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + public okhttp3.Call getServerCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Boolean details, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -9926,13 +15143,16 @@ public okhttp3.Call getNetworkAreaCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -9940,6 +15160,10 @@ public okhttp3.Call getNetworkAreaCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (details != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("details", details)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -9969,39 +15193,49 @@ public okhttp3.Call getNetworkAreaCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getNetworkAreaValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + private okhttp3.Call getServerValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Boolean details, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling getNetworkArea(Async)"); + "Missing the required parameter 'projectId' when calling getServer(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling getNetworkArea(Async)"); + "Missing the required parameter 'region' when calling getServer(Async)"); } - return getNetworkAreaCall(organizationId, areaId, _callback); + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling getServer(Async)"); + } + + return getServerCall(projectId, region, serverId, details, _callback); } /** - * Get details about a network area. Get details about a network area in an organization. + * Get server details. Get details about a server by its ID. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @return NetworkArea + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param details Show detailed information about server. (optional, default to false) + * @return Server * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10009,26 +15243,32 @@ private okhttp3.Call getNetworkAreaValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show network area details. -
200 Show server details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NetworkArea getNetworkArea( - @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + public Server getServer( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Boolean details) throws ApiException { - ApiResponse localVarResp = getNetworkAreaWithHttpInfo(organizationId, areaId); + ApiResponse localVarResp = + getServerWithHttpInfo(projectId, region, serverId, details); return localVarResp.getData(); } /** - * Get details about a network area. Get details about a network area in an organization. + * Get server details. Get details about a server by its ID. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @return ApiResponse<NetworkArea> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param details Show detailed information about server. (optional, default to false) + * @return ApiResponse<Server> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10036,20 +15276,25 @@ public NetworkArea getNetworkArea( * *
Response Details
Status Code Description Response Headers
200 Show network area details. -
200 Show server details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getNetworkAreaWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + public ApiResponse getServerWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Boolean details) throws ApiException { - okhttp3.Call localVarCall = getNetworkAreaValidateBeforeCall(organizationId, areaId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + getServerValidateBeforeCall(projectId, region, serverId, details, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a network area. (asynchronously) Get details about a network area in an - * organization. + * Get server details. (asynchronously) Get details about a server by its ID. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param details Show detailed information about server. (optional, default to false) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -10058,7 +15303,7 @@ public ApiResponse getNetworkAreaWithHttpInfo( * * * - * + * * * * @@ -10066,25 +15311,27 @@ public ApiResponse getNetworkAreaWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show network area details. -
200 Show server details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNetworkAreaAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - final ApiCallback _callback) + public okhttp3.Call getServerAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Boolean details, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getNetworkAreaValidateBeforeCall(organizationId, areaId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + getServerValidateBeforeCall(projectId, region, serverId, details, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getNetworkAreaRange + * Build call for getServerConsole * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -10092,7 +15339,7 @@ public okhttp3.Call getNetworkAreaAsync( * * * - * + * * * * @@ -10100,10 +15347,10 @@ public okhttp3.Call getNetworkAreaAsync( * *
Response Details
Status Code Description Response Headers
200 Show network range details. -
200 Show server console URL. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNetworkAreaRangeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId, + public okhttp3.Call getServerConsoleCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -10123,16 +15370,16 @@ public okhttp3.Call getNetworkAreaRangeCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/network-ranges/{networkRangeId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/console" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "networkRangeId" + "}", - localVarApiClient.escapeString(networkRangeId.toString())); + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -10169,47 +15416,47 @@ public okhttp3.Call getNetworkAreaRangeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getNetworkAreaRangeValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId, + private okhttp3.Call getServerConsoleValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling getNetworkAreaRange(Async)"); + "Missing the required parameter 'projectId' when calling getServerConsole(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling getNetworkAreaRange(Async)"); + "Missing the required parameter 'region' when calling getServerConsole(Async)"); } - // verify the required parameter 'networkRangeId' is set - if (networkRangeId == null) { + // verify the required parameter 'serverId' is set + if (serverId == null) { throw new ApiException( - "Missing the required parameter 'networkRangeId' when calling getNetworkAreaRange(Async)"); + "Missing the required parameter 'serverId' when calling getServerConsole(Async)"); } - return getNetworkAreaRangeCall(organizationId, areaId, networkRangeId, _callback); + return getServerConsoleCall(projectId, region, serverId, _callback); } /** - * Get details about a network range. Get details about a network range in a network area. + * Get server console. Get a URL for server remote console. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) - * @return NetworkRange + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return ServerConsoleUrl * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10217,30 +15464,30 @@ private okhttp3.Call getNetworkAreaRangeValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show network range details. -
200 Show server console URL. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NetworkRange getNetworkAreaRange( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId) + public ServerConsoleUrl getServerConsole( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - ApiResponse localVarResp = - getNetworkAreaRangeWithHttpInfo(organizationId, areaId, networkRangeId); + ApiResponse localVarResp = + getServerConsoleWithHttpInfo(projectId, region, serverId); return localVarResp.getData(); } /** - * Get details about a network range. Get details about a network range in a network area. + * Get server console. Get a URL for server remote console. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) - * @return ApiResponse<NetworkRange> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return ApiResponse<ServerConsoleUrl> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10248,24 +15495,23 @@ public NetworkRange getNetworkAreaRange( * *
Response Details
Status Code Description Response Headers
200 Show network range details. -
200 Show server console URL. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getNetworkAreaRangeWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId) + public ApiResponse getServerConsoleWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { okhttp3.Call localVarCall = - getNetworkAreaRangeValidateBeforeCall(organizationId, areaId, networkRangeId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + getServerConsoleValidateBeforeCall(projectId, region, serverId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a network range. (asynchronously) Get details about a network range in a - * network area. + * Get server console. (asynchronously) Get a URL for server remote console. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param networkRangeId The identifier (ID) of a STACKIT Network Range. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -10274,7 +15520,7 @@ public ApiResponse getNetworkAreaRangeWithHttpInfo( * * * - * + * * * * @@ -10282,27 +15528,28 @@ public ApiResponse getNetworkAreaRangeWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show network range details. -
200 Show server console URL. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNetworkAreaRangeAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID networkRangeId, - final ApiCallback _callback) + public okhttp3.Call getServerConsoleAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getNetworkAreaRangeValidateBeforeCall( - organizationId, areaId, networkRangeId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + getServerConsoleValidateBeforeCall(projectId, region, serverId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getNetworkAreaRoute + * Build call for getServerLog * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param length Request the server log. By default the length is limited to 2000 lines. Set to + * 0 to retrieve the complete log. (optional, default to 2000) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -10310,7 +15557,7 @@ public okhttp3.Call getNetworkAreaRangeAsync( * * * - * + * * * * @@ -10318,10 +15565,11 @@ public okhttp3.Call getNetworkAreaRangeAsync( * *
Response Details
Status Code Description Response Headers
200 Show route details. -
200 Show server console log. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNetworkAreaRouteCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, + public okhttp3.Call getServerLogCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Long length, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -10341,16 +15589,16 @@ public okhttp3.Call getNetworkAreaRouteCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/routes/{routeId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/log" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "routeId" + "}", - localVarApiClient.escapeString(routeId.toString())); + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -10358,6 +15606,10 @@ public okhttp3.Call getNetworkAreaRouteCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (length != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("length", length)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -10387,48 +15639,50 @@ public okhttp3.Call getNetworkAreaRouteCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getNetworkAreaRouteValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, + private okhttp3.Call getServerLogValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Long length, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling getNetworkAreaRoute(Async)"); + "Missing the required parameter 'projectId' when calling getServerLog(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling getNetworkAreaRoute(Async)"); + "Missing the required parameter 'region' when calling getServerLog(Async)"); } - // verify the required parameter 'routeId' is set - if (routeId == null) { + // verify the required parameter 'serverId' is set + if (serverId == null) { throw new ApiException( - "Missing the required parameter 'routeId' when calling getNetworkAreaRoute(Async)"); + "Missing the required parameter 'serverId' when calling getServerLog(Async)"); } - return getNetworkAreaRouteCall(organizationId, areaId, routeId, _callback); + return getServerLogCall(projectId, region, serverId, length, _callback); } /** - * Get details about a network route. Get details about a network route defined in a network - * area. + * Get server log. Get server console log. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) - * @return Route + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param length Request the server log. By default the length is limited to 2000 lines. Set to + * 0 to retrieve the complete log. (optional, default to 2000) + * @return GetServerLog200Response * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10436,31 +15690,33 @@ private okhttp3.Call getNetworkAreaRouteValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show route details. -
200 Show server console log. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Route getNetworkAreaRoute( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId) + public GetServerLog200Response getServerLog( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Long length) throws ApiException { - ApiResponse localVarResp = - getNetworkAreaRouteWithHttpInfo(organizationId, areaId, routeId); + ApiResponse localVarResp = + getServerLogWithHttpInfo(projectId, region, serverId, length); return localVarResp.getData(); } /** - * Get details about a network route. Get details about a network route defined in a network - * area. + * Get server log. Get server console log. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) - * @return ApiResponse<Route> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param length Request the server log. By default the length is limited to 2000 lines. Set to + * 0 to retrieve the complete log. (optional, default to 2000) + * @return ApiResponse<GetServerLog200Response> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10468,24 +15724,26 @@ public Route getNetworkAreaRoute( * *
Response Details
Status Code Description Response Headers
200 Show route details. -
200 Show server console log. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getNetworkAreaRouteWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId) + public ApiResponse getServerLogWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Long length) throws ApiException { okhttp3.Call localVarCall = - getNetworkAreaRouteValidateBeforeCall(organizationId, areaId, routeId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + getServerLogValidateBeforeCall(projectId, region, serverId, length, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a network route. (asynchronously) Get details about a network route defined - * in a network area. + * Get server log. (asynchronously) Get server console log. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param length Request the server log. By default the length is limited to 2000 lines. Set to + * 0 to retrieve the complete log. (optional, default to 2000) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -10494,7 +15752,7 @@ public ApiResponse getNetworkAreaRouteWithHttpInfo( * * * - * + * * * * @@ -10502,26 +15760,27 @@ public ApiResponse getNetworkAreaRouteWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show route details. -
200 Show server console log. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNetworkAreaRouteAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - final ApiCallback _callback) + public okhttp3.Call getServerLogAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable Long length, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getNetworkAreaRouteValidateBeforeCall(organizationId, areaId, routeId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + getServerLogValidateBeforeCall(projectId, region, serverId, length, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getNic + * Build call for getVolume * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -10529,7 +15788,7 @@ public okhttp3.Call getNetworkAreaRouteAsync( * * * - * + * * * * @@ -10537,10 +15796,10 @@ public okhttp3.Call getNetworkAreaRouteAsync( * *
Response Details
Status Code Description Response Headers
200 Show network interface details. -
200 Show volume details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNicCall( + public okhttp3.Call getVolumeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -10560,16 +15819,16 @@ public okhttp3.Call getNicCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}/nics/{nicId}" + "/v2beta1/projects/{projectId}/regions/{region}/volumes/{volumeId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "nicId" + "}", - localVarApiClient.escapeString(nicId.toString())); + "{" + "volumeId" + "}", + localVarApiClient.escapeString(volumeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -10606,48 +15865,47 @@ public okhttp3.Call getNicCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getNicValidateBeforeCall( + private okhttp3.Call getVolumeValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getNic(Async)"); + "Missing the required parameter 'projectId' when calling getVolume(Async)"); } - // verify the required parameter 'networkId' is set - if (networkId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'networkId' when calling getNic(Async)"); + "Missing the required parameter 'region' when calling getVolume(Async)"); } - // verify the required parameter 'nicId' is set - if (nicId == null) { + // verify the required parameter 'volumeId' is set + if (volumeId == null) { throw new ApiException( - "Missing the required parameter 'nicId' when calling getNic(Async)"); + "Missing the required parameter 'volumeId' when calling getVolume(Async)"); } - return getNicCall(projectId, networkId, nicId, _callback); + return getVolumeCall(projectId, region, volumeId, _callback); } /** - * Get details about a network interface of a network. Get details about a network interface - * inside a network. + * Get details about a volume. Get details about a block device volume. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @return NIC + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @return Volume * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10655,30 +15913,29 @@ private okhttp3.Call getNicValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show network interface details. -
200 Show volume details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NIC getNic( + public Volume getVolume( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId) throws ApiException { - ApiResponse localVarResp = getNicWithHttpInfo(projectId, networkId, nicId); + ApiResponse localVarResp = getVolumeWithHttpInfo(projectId, region, volumeId); return localVarResp.getData(); } /** - * Get details about a network interface of a network. Get details about a network interface - * inside a network. + * Get details about a volume. Get details about a block device volume. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @return ApiResponse<NIC> + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @return ApiResponse<Volume> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10686,23 +15943,22 @@ public NIC getNic( * *
Response Details
Status Code Description Response Headers
200 Show network interface details. -
200 Show volume details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getNicWithHttpInfo( + public ApiResponse getVolumeWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId) throws ApiException { - okhttp3.Call localVarCall = getNicValidateBeforeCall(projectId, networkId, nicId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = getVolumeValidateBeforeCall(projectId, region, volumeId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a network interface of a network. (asynchronously) Get details about a - * network interface inside a network. + * Get details about a volume. (asynchronously) Get details about a block device volume. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -10711,7 +15967,7 @@ public ApiResponse getNicWithHttpInfo( * * * - * + * * * * @@ -10719,25 +15975,26 @@ public ApiResponse getNicWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show network interface details. -
200 Show volume details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getNicAsync( + public okhttp3.Call getVolumeAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getNicValidateBeforeCall(projectId, networkId, nicId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + getVolumeValidateBeforeCall(projectId, region, volumeId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getOrganizationRequest + * Build call for getVolumePerformanceClass * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param requestId The identifier (ID) of a STACKIT Request. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumePerformanceClass The name of a STACKIT Volume performance class. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -10745,7 +16002,7 @@ public okhttp3.Call getNicAsync( * * * - * + * * * * @@ -10753,9 +16010,10 @@ public okhttp3.Call getNicAsync( * *
Response Details
Status Code Description Response Headers
200 Show organization request details. -
200 Show volume performance class details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getOrganizationRequestCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull String requestId, + public okhttp3.Call getVolumePerformanceClassCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String volumePerformanceClass, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -10775,13 +16033,16 @@ public okhttp3.Call getOrganizationRequestCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/requests/{requestId}" + "/v2beta1/projects/{projectId}/regions/{region}/volume-performance-classes/{volumePerformanceClass}" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "requestId" + "}", - localVarApiClient.escapeString(requestId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "volumePerformanceClass" + "}", + localVarApiClient.escapeString(volumePerformanceClass.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -10818,40 +16079,48 @@ public okhttp3.Call getOrganizationRequestCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getOrganizationRequestValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull String requestId, + private okhttp3.Call getVolumePerformanceClassValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String volumePerformanceClass, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling getVolumePerformanceClass(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling getOrganizationRequest(Async)"); + "Missing the required parameter 'region' when calling getVolumePerformanceClass(Async)"); } - // verify the required parameter 'requestId' is set - if (requestId == null) { + // verify the required parameter 'volumePerformanceClass' is set + if (volumePerformanceClass == null) { throw new ApiException( - "Missing the required parameter 'requestId' when calling getOrganizationRequest(Async)"); + "Missing the required parameter 'volumePerformanceClass' when calling getVolumePerformanceClass(Async)"); } - return getOrganizationRequestCall(organizationId, requestId, _callback); + return getVolumePerformanceClassCall(projectId, region, volumePerformanceClass, _callback); } /** - * Lookup an organization request ID. Lookup an organization request ID from a previous request. - * This allows to find resource IDs of resources generated during a organization request. + * Get details about a volume performance class. Get details about a specific volume performance + * class. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param requestId The identifier (ID) of a STACKIT Request. (required) - * @return Request + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumePerformanceClass The name of a STACKIT Volume performance class. (required) + * @return VolumePerformanceClass * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10859,29 +16128,31 @@ private okhttp3.Call getOrganizationRequestValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show organization request details. -
200 Show volume performance class details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Request getOrganizationRequest( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull String requestId) + public VolumePerformanceClass getVolumePerformanceClass( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String volumePerformanceClass) throws ApiException { - ApiResponse localVarResp = - getOrganizationRequestWithHttpInfo(organizationId, requestId); + ApiResponse localVarResp = + getVolumePerformanceClassWithHttpInfo(projectId, region, volumePerformanceClass); return localVarResp.getData(); } /** - * Lookup an organization request ID. Lookup an organization request ID from a previous request. - * This allows to find resource IDs of resources generated during a organization request. + * Get details about a volume performance class. Get details about a specific volume performance + * class. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param requestId The identifier (ID) of a STACKIT Request. (required) - * @return ApiResponse<Request> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumePerformanceClass The name of a STACKIT Volume performance class. (required) + * @return ApiResponse<VolumePerformanceClass> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -10889,23 +16160,25 @@ public Request getOrganizationRequest( * *
Response Details
Status Code Description Response Headers
200 Show organization request details. -
200 Show volume performance class details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getOrganizationRequestWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull String requestId) + public ApiResponse getVolumePerformanceClassWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String volumePerformanceClass) throws ApiException { okhttp3.Call localVarCall = - getOrganizationRequestValidateBeforeCall(organizationId, requestId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + getVolumePerformanceClassValidateBeforeCall( + projectId, region, volumePerformanceClass, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Lookup an organization request ID. (asynchronously) Lookup an organization request ID from a - * previous request. This allows to find resource IDs of resources generated during a - * organization request. + * Get details about a volume performance class. (asynchronously) Get details about a specific + * volume performance class. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param requestId The identifier (ID) of a STACKIT Request. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumePerformanceClass The name of a STACKIT Volume performance class. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -10914,7 +16187,7 @@ public ApiResponse getOrganizationRequestWithHttpInfo( * * * - * + * * * * @@ -10922,23 +16195,26 @@ public ApiResponse getOrganizationRequestWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show organization request details. -
200 Show volume performance class details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getOrganizationRequestAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull String requestId, - final ApiCallback _callback) + public okhttp3.Call getVolumePerformanceClassAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull String volumePerformanceClass, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getOrganizationRequestValidateBeforeCall(organizationId, requestId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + getVolumePerformanceClassValidateBeforeCall( + projectId, region, volumePerformanceClass, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getProjectDetails + * Build call for listAffinityGroups * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -10946,16 +16222,19 @@ public okhttp3.Call getOrganizationRequestAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Show project details. -
200 List affinity groups. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getProjectDetailsCall( - @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) + public okhttp3.Call listAffinityGroupsCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -10974,10 +16253,13 @@ public okhttp3.Call getProjectDetailsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}" + "/v2beta1/projects/{projectId}/regions/{region}/affinity-groups" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -11014,72 +16296,98 @@ public okhttp3.Call getProjectDetailsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getProjectDetailsValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) + private okhttp3.Call listAffinityGroupsValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getProjectDetails(Async)"); + "Missing the required parameter 'projectId' when calling listAffinityGroups(Async)"); } - return getProjectDetailsCall(projectId, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listAffinityGroups(Async)"); + } + + return listAffinityGroupsCall(projectId, region, _callback); } /** - * Get project details. Get details about a STACKIT project. + * Get the affinity groups setup for a project. Get the affinity groups created in a project. + * Affinity groups are an indication of locality of a server relative to another group of + * servers. They can be either running on the same host (affinity) or on different ones + * (anti-affinity). * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @return Project + * @param region The STACKIT Region of the resources. (required) + * @return AffinityGroupListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Show project details. -
200 List affinity groups. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Project getProjectDetails(@javax.annotation.Nonnull UUID projectId) throws ApiException { - ApiResponse localVarResp = getProjectDetailsWithHttpInfo(projectId); + public AffinityGroupListResponse listAffinityGroups( + @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String region) + throws ApiException { + ApiResponse localVarResp = + listAffinityGroupsWithHttpInfo(projectId, region); return localVarResp.getData(); } /** - * Get project details. Get details about a STACKIT project. + * Get the affinity groups setup for a project. Get the affinity groups created in a project. + * Affinity groups are an indication of locality of a server relative to another group of + * servers. They can be either running on the same host (affinity) or on different ones + * (anti-affinity). * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @return ApiResponse<Project> + * @param region The STACKIT Region of the resources. (required) + * @return ApiResponse<AffinityGroupListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Show project details. -
200 List affinity groups. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getProjectDetailsWithHttpInfo( - @javax.annotation.Nonnull UUID projectId) throws ApiException { - okhttp3.Call localVarCall = getProjectDetailsValidateBeforeCall(projectId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + public ApiResponse listAffinityGroupsWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String region) + throws ApiException { + okhttp3.Call localVarCall = listAffinityGroupsValidateBeforeCall(projectId, region, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get project details. (asynchronously) Get details about a STACKIT project. + * Get the affinity groups setup for a project. (asynchronously) Get the affinity groups created + * in a project. Affinity groups are an indication of locality of a server relative to another + * group of servers. They can be either running on the same host (affinity) or on different ones + * (anti-affinity). * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -11088,29 +16396,34 @@ public ApiResponse getProjectDetailsWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Show project details. -
200 List affinity groups. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getProjectDetailsAsync( - @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) + public okhttp3.Call listAffinityGroupsAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getProjectDetailsValidateBeforeCall(projectId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listAffinityGroupsValidateBeforeCall(projectId, region, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getProjectNIC + * Build call for listAttachedVolumes * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param nicId The identifier (ID) of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -11118,7 +16431,7 @@ public okhttp3.Call getProjectDetailsAsync( * * * - * + * * * * @@ -11126,9 +16439,10 @@ public okhttp3.Call getProjectDetailsAsync( * *
Response Details
Status Code Description Response Headers
200 Show details of network interface. -
200 List volume attachments. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getProjectNICCall( + public okhttp3.Call listAttachedVolumesCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -11148,13 +16462,16 @@ public okhttp3.Call getProjectNICCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/nics/{nicId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/volume-attachments" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "nicId" + "}", - localVarApiClient.escapeString(nicId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -11191,40 +16508,47 @@ public okhttp3.Call getProjectNICCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getProjectNICValidateBeforeCall( + private okhttp3.Call listAttachedVolumesValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getProjectNIC(Async)"); + "Missing the required parameter 'projectId' when calling listAttachedVolumes(Async)"); } - // verify the required parameter 'nicId' is set - if (nicId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'nicId' when calling getProjectNIC(Async)"); + "Missing the required parameter 'region' when calling listAttachedVolumes(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling listAttachedVolumes(Async)"); } - return getProjectNICCall(projectId, nicId, _callback); + return listAttachedVolumesCall(projectId, region, serverId, _callback); } /** - * Get details about a network interface of a project. Get details about a network interface - * inside a project. + * List all volume attachments of a server. Get a list of all volume attachments of a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @return NIC + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return VolumeAttachmentListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -11232,27 +16556,30 @@ private okhttp3.Call getProjectNICValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show details of network interface. -
200 List volume attachments. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NIC getProjectNIC( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID nicId) + public VolumeAttachmentListResponse listAttachedVolumes( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - ApiResponse localVarResp = getProjectNICWithHttpInfo(projectId, nicId); + ApiResponse localVarResp = + listAttachedVolumesWithHttpInfo(projectId, region, serverId); return localVarResp.getData(); } /** - * Get details about a network interface of a project. Get details about a network interface - * inside a project. + * List all volume attachments of a server. Get a list of all volume attachments of a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @return ApiResponse<NIC> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return ApiResponse<VolumeAttachmentListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -11260,20 +16587,24 @@ public NIC getProjectNIC( * *
Response Details
Status Code Description Response Headers
200 Show details of network interface. -
200 List volume attachments. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getProjectNICWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID nicId) + public ApiResponse listAttachedVolumesWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - okhttp3.Call localVarCall = getProjectNICValidateBeforeCall(projectId, nicId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listAttachedVolumesValidateBeforeCall(projectId, region, serverId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a network interface of a project. (asynchronously) Get details about a - * network interface inside a project. + * List all volume attachments of a server. (asynchronously) Get a list of all volume + * attachments of a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param nicId The identifier (ID) of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -11282,7 +16613,7 @@ public ApiResponse getProjectNICWithHttpInfo( * * * - * + * * * * @@ -11290,23 +16621,24 @@ public ApiResponse getProjectNICWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show details of network interface. -
200 List volume attachments. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getProjectNICAsync( + public okhttp3.Call listAttachedVolumesAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID nicId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getProjectNICValidateBeforeCall(projectId, nicId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listAttachedVolumesValidateBeforeCall(projectId, region, serverId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getProjectRequest + * Build call for listAvailabilityZones * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param requestId The identifier (ID) of a STACKIT Request. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -11314,7 +16646,7 @@ public okhttp3.Call getProjectNICAsync( * * * - * + * * * * @@ -11322,10 +16654,8 @@ public okhttp3.Call getProjectNICAsync( * *
Response Details
Status Code Description Response Headers
200 Show project request details. -
200 Get a list of availability zones. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getProjectRequestCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String requestId, - final ApiCallback _callback) + public okhttp3.Call listAvailabilityZonesCall( + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -11344,13 +16674,10 @@ public okhttp3.Call getProjectRequestCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/requests/{requestId}" + "/v2beta1/regions/{region}/availability-zones" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) - .replace( - "{" + "requestId" + "}", - localVarApiClient.escapeString(requestId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -11387,40 +16714,30 @@ public okhttp3.Call getProjectRequestCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getProjectRequestValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String requestId, - final ApiCallback _callback) + private okhttp3.Call listAvailabilityZonesValidateBeforeCall( + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { - throw new ApiException( - "Missing the required parameter 'projectId' when calling getProjectRequest(Async)"); - } - - // verify the required parameter 'requestId' is set - if (requestId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'requestId' when calling getProjectRequest(Async)"); + "Missing the required parameter 'region' when calling listAvailabilityZones(Async)"); } - return getProjectRequestCall(projectId, requestId, _callback); + return listAvailabilityZonesCall(region, _callback); } /** - * Lookup a project request ID. Lookup a project request ID from a previous request. This allows - * to find resource IDs of resources generated during a projects request. + * List all availability zones. Get a list of all availability zones. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param requestId The identifier (ID) of a STACKIT Request. (required) - * @return Request + * @param region The STACKIT Region of the resources. (required) + * @return AvailabilityZoneListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -11428,27 +16745,25 @@ private okhttp3.Call getProjectRequestValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show project request details. -
200 Get a list of availability zones. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Request getProjectRequest( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String requestId) - throws ApiException { - ApiResponse localVarResp = getProjectRequestWithHttpInfo(projectId, requestId); + public AvailabilityZoneListResponse listAvailabilityZones( + @javax.annotation.Nonnull String region) throws ApiException { + ApiResponse localVarResp = + listAvailabilityZonesWithHttpInfo(region); return localVarResp.getData(); } /** - * Lookup a project request ID. Lookup a project request ID from a previous request. This allows - * to find resource IDs of resources generated during a projects request. + * List all availability zones. Get a list of all availability zones. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param requestId The identifier (ID) of a STACKIT Request. (required) - * @return ApiResponse<Request> + * @param region The STACKIT Region of the resources. (required) + * @return ApiResponse<AvailabilityZoneListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -11456,20 +16771,17 @@ public Request getProjectRequest( * *
Response Details
Status Code Description Response Headers
200 Show project request details. -
200 Get a list of availability zones. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getProjectRequestWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String requestId) - throws ApiException { - okhttp3.Call localVarCall = getProjectRequestValidateBeforeCall(projectId, requestId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + public ApiResponse listAvailabilityZonesWithHttpInfo( + @javax.annotation.Nonnull String region) throws ApiException { + okhttp3.Call localVarCall = listAvailabilityZonesValidateBeforeCall(region, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Lookup a project request ID. (asynchronously) Lookup a project request ID from a previous - * request. This allows to find resource IDs of resources generated during a projects request. + * List all availability zones. (asynchronously) Get a list of all availability zones. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param requestId The identifier (ID) of a STACKIT Request. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -11478,7 +16790,7 @@ public ApiResponse getProjectRequestWithHttpInfo( * * * - * + * * * * @@ -11486,24 +16798,23 @@ public ApiResponse getProjectRequestWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show project request details. -
200 Get a list of availability zones. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getProjectRequestAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String requestId, - final ApiCallback _callback) + public okhttp3.Call listAvailabilityZonesAsync( + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = - getProjectRequestValidateBeforeCall(projectId, requestId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = listAvailabilityZonesValidateBeforeCall(region, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getPublicIP + * Build call for listBackups * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -11511,7 +16822,7 @@ public okhttp3.Call getProjectRequestAsync( * * * - * + * * * * @@ -11519,9 +16830,10 @@ public okhttp3.Call getProjectRequestAsync( * *
Response Details
Status Code Description Response Headers
200 Show public IP details. -
200 List project backups. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getPublicIPCall( + public okhttp3.Call listBackupsCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -11541,13 +16853,13 @@ public okhttp3.Call getPublicIPCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/public-ips/{publicIpId}" + "/v2beta1/projects/{projectId}/regions/{region}/backups" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "publicIpId" + "}", - localVarApiClient.escapeString(publicIpId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -11555,6 +16867,11 @@ public okhttp3.Call getPublicIPCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -11584,39 +16901,41 @@ public okhttp3.Call getPublicIPCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getPublicIPValidateBeforeCall( + private okhttp3.Call listBackupsValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getPublicIP(Async)"); + "Missing the required parameter 'projectId' when calling listBackups(Async)"); } - // verify the required parameter 'publicIpId' is set - if (publicIpId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'publicIpId' when calling getPublicIP(Async)"); + "Missing the required parameter 'region' when calling listBackups(Async)"); } - return getPublicIPCall(projectId, publicIpId, _callback); + return listBackupsCall(projectId, region, labelSelector, _callback); } /** - * Get details about a public IP. Get details about a public IP inside a project. + * List all backups inside a project. Get a list of all backups inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) - * @return PublicIp + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return BackupListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -11624,26 +16943,30 @@ private okhttp3.Call getPublicIPValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show public IP details. -
200 List project backups. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public PublicIp getPublicIP( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID publicIpId) + public BackupListResponse listBackups( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = getPublicIPWithHttpInfo(projectId, publicIpId); + ApiResponse localVarResp = + listBackupsWithHttpInfo(projectId, region, labelSelector); return localVarResp.getData(); } /** - * Get details about a public IP. Get details about a public IP inside a project. + * List all backups inside a project. Get a list of all backups inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) - * @return ApiResponse<PublicIp> + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<BackupListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -11651,20 +16974,24 @@ public PublicIp getPublicIP( * *
Response Details
Status Code Description Response Headers
200 Show public IP details. -
200 List project backups. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getPublicIPWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID publicIpId) + public ApiResponse listBackupsWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - okhttp3.Call localVarCall = getPublicIPValidateBeforeCall(projectId, publicIpId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listBackupsValidateBeforeCall(projectId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a public IP. (asynchronously) Get details about a public IP inside a + * List all backups inside a project. (asynchronously) Get a list of all backups inside a * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -11673,7 +17000,7 @@ public ApiResponse getPublicIPWithHttpInfo( * * * - * + * * * * @@ -11681,23 +17008,27 @@ public ApiResponse getPublicIPWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show public IP details. -
200 List project backups. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getPublicIPAsync( + public okhttp3.Call listBackupsAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getPublicIPValidateBeforeCall(projectId, publicIpId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listBackupsValidateBeforeCall(projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getSecurityGroup + * Build call for listImages * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param all List all Images. (optional, default to false) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -11705,7 +17036,7 @@ public okhttp3.Call getPublicIPAsync( * * * - * + * * * * @@ -11713,9 +17044,11 @@ public okhttp3.Call getPublicIPAsync( * *
Response Details
Status Code Description Response Headers
200 Show security group details. -
200 List project images. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getSecurityGroupCall( + public okhttp3.Call listImagesCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean all, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -11735,13 +17068,13 @@ public okhttp3.Call getSecurityGroupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}" + "/v2beta1/projects/{projectId}/regions/{region}/images" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -11749,6 +17082,15 @@ public okhttp3.Call getSecurityGroupCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (all != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("all", all)); + } + + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -11778,39 +17120,43 @@ public okhttp3.Call getSecurityGroupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getSecurityGroupValidateBeforeCall( + private okhttp3.Call listImagesValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean all, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getSecurityGroup(Async)"); + "Missing the required parameter 'projectId' when calling listImages(Async)"); } - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling getSecurityGroup(Async)"); + "Missing the required parameter 'region' when calling listImages(Async)"); } - return getSecurityGroupCall(projectId, securityGroupId, _callback); + return listImagesCall(projectId, region, all, labelSelector, _callback); } /** - * Get security group details. Get details about a security group of a project. + * List all Images inside a project. Get a list of all images inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @return SecurityGroup + * @param region The STACKIT Region of the resources. (required) + * @param all List all Images. (optional, default to false) + * @param labelSelector Filter resources by labels. (optional) + * @return ImageListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -11818,28 +17164,32 @@ private okhttp3.Call getSecurityGroupValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show security group details. -
200 List project images. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public SecurityGroup getSecurityGroup( + public ImageListResponse listImages( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean all, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - getSecurityGroupWithHttpInfo(projectId, securityGroupId); + ApiResponse localVarResp = + listImagesWithHttpInfo(projectId, region, all, labelSelector); return localVarResp.getData(); } /** - * Get security group details. Get details about a security group of a project. + * List all Images inside a project. Get a list of all images inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @return ApiResponse<SecurityGroup> + * @param region The STACKIT Region of the resources. (required) + * @param all List all Images. (optional, default to false) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<ImageListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -11847,21 +17197,25 @@ public SecurityGroup getSecurityGroup( * *
Response Details
Status Code Description Response Headers
200 Show security group details. -
200 List project images. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getSecurityGroupWithHttpInfo( + public ApiResponse listImagesWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean all, + @javax.annotation.Nullable String labelSelector) throws ApiException { okhttp3.Call localVarCall = - getSecurityGroupValidateBeforeCall(projectId, securityGroupId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listImagesValidateBeforeCall(projectId, region, all, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get security group details. (asynchronously) Get details about a security group of a project. + * List all Images inside a project. (asynchronously) Get a list of all images inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param all List all Images. (optional, default to false) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -11870,7 +17224,7 @@ public ApiResponse getSecurityGroupWithHttpInfo( * * * - * + * * * * @@ -11878,25 +17232,25 @@ public ApiResponse getSecurityGroupWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show security group details. -
200 List project images. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getSecurityGroupAsync( + public okhttp3.Call listImagesAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean all, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getSecurityGroupValidateBeforeCall(projectId, securityGroupId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listImagesValidateBeforeCall(projectId, region, all, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getSecurityGroupRule + * Build call for listKeyPairs * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -11904,7 +17258,7 @@ public okhttp3.Call getSecurityGroupAsync( * * * - * + * * * * @@ -11912,11 +17266,8 @@ public okhttp3.Call getSecurityGroupAsync( * *
Response Details
Status Code Description Response Headers
200 Show security group rule details. -
200 List SSH keypairs. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getSecurityGroupRuleCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId, - final ApiCallback _callback) + public okhttp3.Call listKeyPairsCall( + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -11934,17 +17285,7 @@ public okhttp3.Call getSecurityGroupRuleCall( Object localVarPostBody = null; // create path and map variables - String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}/rules/{securityGroupRuleId}" - .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) - .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())) - .replace( - "{" + "securityGroupRuleId" + "}", - localVarApiClient.escapeString(securityGroupRuleId.toString())); + String localVarPath = "/v2beta1/keypairs"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -11952,6 +17293,11 @@ public okhttp3.Call getSecurityGroupRuleCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -11981,47 +17327,25 @@ public okhttp3.Call getSecurityGroupRuleCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getSecurityGroupRuleValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId, - final ApiCallback _callback) + private okhttp3.Call listKeyPairsValidateBeforeCall( + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { - throw new ApiException( - "Missing the required parameter 'projectId' when calling getSecurityGroupRule(Async)"); - } - - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { - throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling getSecurityGroupRule(Async)"); - } - - // verify the required parameter 'securityGroupRuleId' is set - if (securityGroupRuleId == null) { - throw new ApiException( - "Missing the required parameter 'securityGroupRuleId' when calling getSecurityGroupRule(Async)"); - } - - return getSecurityGroupRuleCall(projectId, securityGroupId, securityGroupRuleId, _callback); + return listKeyPairsCall(labelSelector, _callback); } /** - * Get security group rule details. Get details about a security group rule of a project. + * List all SSH keypairs for the requesting user. Get a list of all SSH keypairs assigned to the + * requesting user. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) - * @return SecurityGroupRule + * @param labelSelector Filter resources by labels. (optional) + * @return KeyPairListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12029,30 +17353,25 @@ private okhttp3.Call getSecurityGroupRuleValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show security group rule details. -
200 List SSH keypairs. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public SecurityGroupRule getSecurityGroupRule( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId) + public KeyPairListResponse listKeyPairs(@javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - getSecurityGroupRuleWithHttpInfo(projectId, securityGroupId, securityGroupRuleId); + ApiResponse localVarResp = listKeyPairsWithHttpInfo(labelSelector); return localVarResp.getData(); } /** - * Get security group rule details. Get details about a security group rule of a project. + * List all SSH keypairs for the requesting user. Get a list of all SSH keypairs assigned to the + * requesting user. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) - * @return ApiResponse<SecurityGroupRule> + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<KeyPairListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12060,25 +17379,18 @@ public SecurityGroupRule getSecurityGroupRule( * *
Response Details
Status Code Description Response Headers
200 Show security group rule details. -
200 List SSH keypairs. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getSecurityGroupRuleWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId) - throws ApiException { - okhttp3.Call localVarCall = - getSecurityGroupRuleValidateBeforeCall( - projectId, securityGroupId, securityGroupRuleId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + public ApiResponse listKeyPairsWithHttpInfo( + @javax.annotation.Nullable String labelSelector) throws ApiException { + okhttp3.Call localVarCall = listKeyPairsValidateBeforeCall(labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get security group rule details. (asynchronously) Get details about a security group rule of - * a project. + * List all SSH keypairs for the requesting user. (asynchronously) Get a list of all SSH + * keypairs assigned to the requesting user. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param securityGroupRuleId The identifier (ID) of a STACKIT Security Group Rule. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -12087,7 +17399,7 @@ public ApiResponse getSecurityGroupRuleWithHttpInfo( * * * - * + * * * * @@ -12095,27 +17407,24 @@ public ApiResponse getSecurityGroupRuleWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show security group rule details. -
200 List SSH keypairs. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getSecurityGroupRuleAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UUID securityGroupRuleId, - final ApiCallback _callback) + public okhttp3.Call listKeyPairsAsync( + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = - getSecurityGroupRuleValidateBeforeCall( - projectId, securityGroupId, securityGroupRuleId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = listKeyPairsValidateBeforeCall(labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getServer + * Build call for listMachineTypes * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param details Show detailed information about server. (optional, default to false) + * @param region The STACKIT Region of the resources. (required) + * @param filter Filter resources by fields. A subset of expr-lang is supported. See + * https://expr-lang.org/docs/language-definition for usage details. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -12123,7 +17432,7 @@ public okhttp3.Call getSecurityGroupRuleAsync( * * * - * + * * * * @@ -12131,10 +17440,10 @@ public okhttp3.Call getSecurityGroupRuleAsync( * *
Response Details
Status Code Description Response Headers
200 Show server details. -
200 List of machine types. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getServerCall( + public okhttp3.Call listMachineTypesCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Boolean details, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String filter, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -12154,13 +17463,13 @@ public okhttp3.Call getServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}" + "/v2beta1/projects/{projectId}/regions/{region}/machine-types" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -12168,8 +17477,8 @@ public okhttp3.Call getServerCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (details != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("details", details)); + if (filter != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("filter", filter)); } final String[] localVarAccepts = {"application/json"}; @@ -12201,41 +17510,43 @@ public okhttp3.Call getServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getServerValidateBeforeCall( + private okhttp3.Call listMachineTypesValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Boolean details, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String filter, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getServer(Async)"); + "Missing the required parameter 'projectId' when calling listMachineTypes(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling getServer(Async)"); + "Missing the required parameter 'region' when calling listMachineTypes(Async)"); } - return getServerCall(projectId, serverId, details, _callback); + return listMachineTypesCall(projectId, region, filter, _callback); } /** - * Get server details. Get details about a server by its ID. + * List all machine types available for a project. Get a list of all machine type available in a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param details Show detailed information about server. (optional, default to false) - * @return Server + * @param region The STACKIT Region of the resources. (required) + * @param filter Filter resources by fields. A subset of expr-lang is supported. See + * https://expr-lang.org/docs/language-definition for usage details. (optional) + * @return MachineTypeListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12243,29 +17554,32 @@ private okhttp3.Call getServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show server details. -
200 List of machine types. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Server getServer( + public MachineTypeListResponse listMachineTypes( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Boolean details) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String filter) throws ApiException { - ApiResponse localVarResp = getServerWithHttpInfo(projectId, serverId, details); + ApiResponse localVarResp = + listMachineTypesWithHttpInfo(projectId, region, filter); return localVarResp.getData(); } /** - * Get server details. Get details about a server by its ID. + * List all machine types available for a project. Get a list of all machine type available in a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param details Show detailed information about server. (optional, default to false) - * @return ApiResponse<Server> + * @param region The STACKIT Region of the resources. (required) + * @param filter Filter resources by fields. A subset of expr-lang is supported. See + * https://expr-lang.org/docs/language-definition for usage details. (optional) + * @return ApiResponse<MachineTypeListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12273,22 +17587,25 @@ public Server getServer( * *
Response Details
Status Code Description Response Headers
200 Show server details. -
200 List of machine types. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getServerWithHttpInfo( + public ApiResponse listMachineTypesWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Boolean details) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String filter) throws ApiException { - okhttp3.Call localVarCall = getServerValidateBeforeCall(projectId, serverId, details, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listMachineTypesValidateBeforeCall(projectId, region, filter, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get server details. (asynchronously) Get details about a server by its ID. + * List all machine types available for a project. (asynchronously) Get a list of all machine + * type available in a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param details Show detailed information about server. (optional, default to false) + * @param region The STACKIT Region of the resources. (required) + * @param filter Filter resources by fields. A subset of expr-lang is supported. See + * https://expr-lang.org/docs/language-definition for usage details. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -12297,7 +17614,7 @@ public ApiResponse getServerWithHttpInfo( * * * - * + * * * * @@ -12305,25 +17622,25 @@ public ApiResponse getServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show server details. -
200 List of machine types. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getServerAsync( + public okhttp3.Call listMachineTypesAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Boolean details, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String filter, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getServerValidateBeforeCall(projectId, serverId, details, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listMachineTypesValidateBeforeCall(projectId, region, filter, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getServerConsole + * Build call for listNetworkAreaProjects * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -12331,7 +17648,7 @@ public okhttp3.Call getServerAsync( * * * - * + * * * * @@ -12339,9 +17656,9 @@ public okhttp3.Call getServerAsync( * *
Response Details
Status Code Description Response Headers
200 Show server console URL. -
200 List projects for a network area. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getServerConsoleCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + public okhttp3.Call listNetworkAreaProjectsCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -12361,13 +17678,13 @@ public okhttp3.Call getServerConsoleCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/console" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/projects" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -12404,39 +17721,39 @@ public okhttp3.Call getServerConsoleCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getServerConsoleValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + private okhttp3.Call listNetworkAreaProjectsValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getServerConsole(Async)"); + "Missing the required parameter 'organizationId' when calling listNetworkAreaProjects(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling getServerConsole(Async)"); + "Missing the required parameter 'areaId' when calling listNetworkAreaProjects(Async)"); } - return getServerConsoleCall(projectId, serverId, _callback); + return listNetworkAreaProjectsCall(organizationId, areaId, _callback); } /** - * Get server console. Get a URL for server remote console. + * List all projects using a network area. Get a list of all projects using a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ServerConsoleUrl + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @return ProjectListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12444,27 +17761,27 @@ private okhttp3.Call getServerConsoleValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show server console URL. -
200 List projects for a network area. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ServerConsoleUrl getServerConsole( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ProjectListResponse listNetworkAreaProjects( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) throws ApiException { - ApiResponse localVarResp = - getServerConsoleWithHttpInfo(projectId, serverId); + ApiResponse localVarResp = + listNetworkAreaProjectsWithHttpInfo(organizationId, areaId); return localVarResp.getData(); } /** - * Get server console. Get a URL for server remote console. + * List all projects using a network area. Get a list of all projects using a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ApiResponse<ServerConsoleUrl> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @return ApiResponse<ProjectListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12472,19 +17789,21 @@ public ServerConsoleUrl getServerConsole( * *
Response Details
Status Code Description Response Headers
200 Show server console URL. -
200 List projects for a network area. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getServerConsoleWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse listNetworkAreaProjectsWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) throws ApiException { - okhttp3.Call localVarCall = getServerConsoleValidateBeforeCall(projectId, serverId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listNetworkAreaProjectsValidateBeforeCall(organizationId, areaId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get server console. (asynchronously) Get a URL for server remote console. + * List all projects using a network area. (asynchronously) Get a list of all projects using a + * network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -12493,7 +17812,7 @@ public ApiResponse getServerConsoleWithHttpInfo( * * * - * + * * * * @@ -12501,26 +17820,25 @@ public ApiResponse getServerConsoleWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show server console URL. -
200 List projects for a network area. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getServerConsoleAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) + public okhttp3.Call listNetworkAreaProjectsAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getServerConsoleValidateBeforeCall(projectId, serverId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listNetworkAreaProjectsValidateBeforeCall(organizationId, areaId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getServerLog + * Build call for listNetworkAreaRanges * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param length Request the server log. By default the length is limited to 2000 lines. Set to - * 0 to retrieve the complete log. (optional, default to 2000) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -12528,7 +17846,7 @@ public okhttp3.Call getServerConsoleAsync( * * * - * + * * * * @@ -12536,10 +17854,10 @@ public okhttp3.Call getServerConsoleAsync( * *
Response Details
Status Code Description Response Headers
200 Show server console log. -
200 List all network ranges. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getServerLogCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Long length, + public okhttp3.Call listNetworkAreaRangesCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -12559,23 +17877,22 @@ public okhttp3.Call getServerLogCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/log" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/network-ranges" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); - Map localVarHeaderParams = new HashMap(); - Map localVarCookieParams = new HashMap(); - Map localVarFormParams = new HashMap(); - - if (length != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("length", length)); - } + Map localVarHeaderParams = new HashMap(); + Map localVarCookieParams = new HashMap(); + Map localVarFormParams = new HashMap(); final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); @@ -12606,42 +17923,48 @@ public okhttp3.Call getServerLogCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getServerLogValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Long length, + private okhttp3.Call listNetworkAreaRangesValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getServerLog(Async)"); + "Missing the required parameter 'organizationId' when calling listNetworkAreaRanges(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling getServerLog(Async)"); + "Missing the required parameter 'areaId' when calling listNetworkAreaRanges(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listNetworkAreaRanges(Async)"); } - return getServerLogCall(projectId, serverId, length, _callback); + return listNetworkAreaRangesCall(organizationId, areaId, region, _callback); } /** - * Get server log. Get server console log. + * List all network ranges in a network area. Get a list of all network ranges in a network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param length Request the server log. By default the length is limited to 2000 lines. Set to - * 0 to retrieve the complete log. (optional, default to 2000) - * @return GetServerLog200Response + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @return NetworkRangeListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12649,31 +17972,31 @@ private okhttp3.Call getServerLogValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show server console log. -
200 List all network ranges. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public GetServerLog200Response getServerLog( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Long length) + public NetworkRangeListResponse listNetworkAreaRanges( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region) throws ApiException { - ApiResponse localVarResp = - getServerLogWithHttpInfo(projectId, serverId, length); + ApiResponse localVarResp = + listNetworkAreaRangesWithHttpInfo(organizationId, areaId, region); return localVarResp.getData(); } /** - * Get server log. Get server console log. + * List all network ranges in a network area. Get a list of all network ranges in a network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param length Request the server log. By default the length is limited to 2000 lines. Set to - * 0 to retrieve the complete log. (optional, default to 2000) - * @return ApiResponse<GetServerLog200Response> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @return ApiResponse<NetworkRangeListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12681,24 +18004,24 @@ public GetServerLog200Response getServerLog( * *
Response Details
Status Code Description Response Headers
200 Show server console log. -
200 List all network ranges. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getServerLogWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Long length) + public ApiResponse listNetworkAreaRangesWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region) throws ApiException { okhttp3.Call localVarCall = - getServerLogValidateBeforeCall(projectId, serverId, length, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listNetworkAreaRangesValidateBeforeCall(organizationId, areaId, region, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get server log. (asynchronously) Get server console log. + * List all network ranges in a network area. (asynchronously) Get a list of all network ranges + * in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param length Request the server log. By default the length is limited to 2000 lines. Set to - * 0 to retrieve the complete log. (optional, default to 2000) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -12707,7 +18030,7 @@ public ApiResponse getServerLogWithHttpInfo( * * * - * + * * * * @@ -12715,25 +18038,27 @@ public ApiResponse getServerLogWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show server console log. -
200 List all network ranges. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getServerLogAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable Long length, - final ApiCallback _callback) + public okhttp3.Call listNetworkAreaRangesAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getServerLogValidateBeforeCall(projectId, serverId, length, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listNetworkAreaRangesValidateBeforeCall(organizationId, areaId, region, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getSnapshot + * Build call for listNetworkAreaRoutes * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -12741,7 +18066,7 @@ public okhttp3.Call getServerLogAsync( * * * - * + * * * * @@ -12749,9 +18074,11 @@ public okhttp3.Call getServerLogAsync( * *
Response Details
Status Code Description Response Headers
200 Show snapshot details. -
200 List network routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getSnapshotCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, + public okhttp3.Call listNetworkAreaRoutesCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -12771,13 +18098,16 @@ public okhttp3.Call getSnapshotCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots/{snapshotId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routes" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "snapshotId" + "}", - localVarApiClient.escapeString(snapshotId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -12785,6 +18115,11 @@ public okhttp3.Call getSnapshotCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -12814,39 +18149,50 @@ public okhttp3.Call getSnapshotCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getSnapshotValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, + private okhttp3.Call listNetworkAreaRoutesValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getSnapshot(Async)"); + "Missing the required parameter 'organizationId' when calling listNetworkAreaRoutes(Async)"); } - // verify the required parameter 'snapshotId' is set - if (snapshotId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling listNetworkAreaRoutes(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'snapshotId' when calling getSnapshot(Async)"); + "Missing the required parameter 'region' when calling listNetworkAreaRoutes(Async)"); } - return getSnapshotCall(projectId, snapshotId, _callback); + return listNetworkAreaRoutesCall(organizationId, areaId, region, labelSelector, _callback); } /** - * Get details about a snapshot. Get details about a block device snapshot. + * List all network routes in a network area. Get a list of all network routes defined in a + * network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) - * @return Snapshot + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return RouteListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12854,26 +18200,33 @@ private okhttp3.Call getSnapshotValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show snapshot details. -
200 List network routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Snapshot getSnapshot( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID snapshotId) + public RouteListResponse listNetworkAreaRoutes( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = getSnapshotWithHttpInfo(projectId, snapshotId); + ApiResponse localVarResp = + listNetworkAreaRoutesWithHttpInfo(organizationId, areaId, region, labelSelector); return localVarResp.getData(); } /** - * Get details about a snapshot. Get details about a block device snapshot. + * List all network routes in a network area. Get a list of all network routes defined in a + * network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) - * @return ApiResponse<Snapshot> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<RouteListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -12881,19 +18234,27 @@ public Snapshot getSnapshot( * *
Response Details
Status Code Description Response Headers
200 Show snapshot details. -
200 List network routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getSnapshotWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID snapshotId) + public ApiResponse listNetworkAreaRoutesWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - okhttp3.Call localVarCall = getSnapshotValidateBeforeCall(projectId, snapshotId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listNetworkAreaRoutesValidateBeforeCall( + organizationId, areaId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a snapshot. (asynchronously) Get details about a block device snapshot. + * List all network routes in a network area. (asynchronously) Get a list of all network routes + * defined in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -12902,7 +18263,7 @@ public ApiResponse getSnapshotWithHttpInfo( * * * - * + * * * * @@ -12910,23 +18271,27 @@ public ApiResponse getSnapshotWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show snapshot details. -
200 List network routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getSnapshotAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, - final ApiCallback _callback) + public okhttp3.Call listNetworkAreaRoutesAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getSnapshotValidateBeforeCall(projectId, snapshotId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listNetworkAreaRoutesValidateBeforeCall( + organizationId, areaId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getVolume + * Build call for listNetworkAreas * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -12934,7 +18299,7 @@ public okhttp3.Call getSnapshotAsync( * * * - * + * * * * @@ -12942,9 +18307,9 @@ public okhttp3.Call getSnapshotAsync( * *
Response Details
Status Code Description Response Headers
200 Show volume details. -
200 Get a list of all network areas. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getVolumeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, + public okhttp3.Call listNetworkAreasCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -12964,13 +18329,10 @@ public okhttp3.Call getVolumeCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes/{volumeId}" - .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "/v2beta1/organizations/{organizationId}/network-areas" .replace( - "{" + "volumeId" + "}", - localVarApiClient.escapeString(volumeId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -12978,6 +18340,11 @@ public okhttp3.Call getVolumeCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -13007,39 +18374,34 @@ public okhttp3.Call getVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getVolumeValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, + private okhttp3.Call listNetworkAreasValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { - throw new ApiException( - "Missing the required parameter 'projectId' when calling getVolume(Async)"); - } - - // verify the required parameter 'volumeId' is set - if (volumeId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'volumeId' when calling getVolume(Async)"); + "Missing the required parameter 'organizationId' when calling listNetworkAreas(Async)"); } - return getVolumeCall(projectId, volumeId, _callback); + return listNetworkAreasCall(organizationId, labelSelector, _callback); } /** - * Get details about a volume. Get details about a block device volume. + * List all network areas in an organization. Get a list of all visible network areas defined in + * an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @return Volume + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return NetworkAreaListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13047,26 +18409,29 @@ private okhttp3.Call getVolumeValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show volume details. -
200 Get a list of all network areas. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Volume getVolume( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID volumeId) + public NetworkAreaListResponse listNetworkAreas( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = getVolumeWithHttpInfo(projectId, volumeId); + ApiResponse localVarResp = + listNetworkAreasWithHttpInfo(organizationId, labelSelector); return localVarResp.getData(); } /** - * Get details about a volume. Get details about a block device volume. + * List all network areas in an organization. Get a list of all visible network areas defined in + * an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @return ApiResponse<Volume> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<NetworkAreaListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13074,19 +18439,22 @@ public Volume getVolume( * *
Response Details
Status Code Description Response Headers
200 Show volume details. -
200 Get a list of all network areas. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getVolumeWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID volumeId) + public ApiResponse listNetworkAreasWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nullable String labelSelector) throws ApiException { - okhttp3.Call localVarCall = getVolumeValidateBeforeCall(projectId, volumeId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listNetworkAreasValidateBeforeCall(organizationId, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a volume. (asynchronously) Get details about a block device volume. + * List all network areas in an organization. (asynchronously) Get a list of all visible network + * areas defined in an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -13095,7 +18463,7 @@ public ApiResponse getVolumeWithHttpInfo( * * * - * + * * * * @@ -13103,23 +18471,25 @@ public ApiResponse getVolumeWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Show volume details. -
200 Get a list of all network areas. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getVolumeAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - final ApiCallback _callback) + public okhttp3.Call listNetworkAreasAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = getVolumeValidateBeforeCall(projectId, volumeId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listNetworkAreasValidateBeforeCall(organizationId, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for getVolumePerformanceClass + * Build call for listNetworks * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumePerformanceClass The name of a STACKIT Volume performance class. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -13127,7 +18497,7 @@ public okhttp3.Call getVolumeAsync( * * * - * + * * * * @@ -13135,9 +18505,10 @@ public okhttp3.Call getVolumeAsync( * *
Response Details
Status Code Description Response Headers
200 Show volume performance class details. -
200 List all networks of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getVolumePerformanceClassCall( + public okhttp3.Call listNetworksCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String volumePerformanceClass, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -13157,13 +18528,13 @@ public okhttp3.Call getVolumePerformanceClassCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volume-performance-classes/{volumePerformanceClass}" + "/v2beta1/projects/{projectId}/regions/{region}/networks" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "volumePerformanceClass" + "}", - localVarApiClient.escapeString(volumePerformanceClass.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -13171,6 +18542,11 @@ public okhttp3.Call getVolumePerformanceClassCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -13200,40 +18576,41 @@ public okhttp3.Call getVolumePerformanceClassCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getVolumePerformanceClassValidateBeforeCall( + private okhttp3.Call listNetworksValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String volumePerformanceClass, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling getVolumePerformanceClass(Async)"); + "Missing the required parameter 'projectId' when calling listNetworks(Async)"); } - // verify the required parameter 'volumePerformanceClass' is set - if (volumePerformanceClass == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'volumePerformanceClass' when calling getVolumePerformanceClass(Async)"); + "Missing the required parameter 'region' when calling listNetworks(Async)"); } - return getVolumePerformanceClassCall(projectId, volumePerformanceClass, _callback); + return listNetworksCall(projectId, region, labelSelector, _callback); } /** - * Get details about a volume performance class. Get details about a specific volume performance - * class. + * List all networks inside a project. Get a list of all networks inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumePerformanceClass The name of a STACKIT Volume performance class. (required) - * @return VolumePerformanceClass + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return NetworkListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13241,29 +18618,30 @@ private okhttp3.Call getVolumePerformanceClassValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Show volume performance class details. -
200 List all networks of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public VolumePerformanceClass getVolumePerformanceClass( + public NetworkListResponse listNetworks( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String volumePerformanceClass) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - getVolumePerformanceClassWithHttpInfo(projectId, volumePerformanceClass); + ApiResponse localVarResp = + listNetworksWithHttpInfo(projectId, region, labelSelector); return localVarResp.getData(); } /** - * Get details about a volume performance class. Get details about a specific volume performance - * class. + * List all networks inside a project. Get a list of all networks inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumePerformanceClass The name of a STACKIT Volume performance class. (required) - * @return ApiResponse<VolumePerformanceClass> + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<NetworkListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13271,23 +18649,24 @@ public VolumePerformanceClass getVolumePerformanceClass( * *
Response Details
Status Code Description Response Headers
200 Show volume performance class details. -
200 List all networks of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse getVolumePerformanceClassWithHttpInfo( + public ApiResponse listNetworksWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String volumePerformanceClass) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { okhttp3.Call localVarCall = - getVolumePerformanceClassValidateBeforeCall( - projectId, volumePerformanceClass, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listNetworksValidateBeforeCall(projectId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get details about a volume performance class. (asynchronously) Get details about a specific - * volume performance class. + * List all networks inside a project. (asynchronously) Get a list of all networks inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumePerformanceClass The name of a STACKIT Volume performance class. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -13296,7 +18675,7 @@ public ApiResponse getVolumePerformanceClassWithHttpInfo * * * - * + * * * * @@ -13304,24 +18683,27 @@ public ApiResponse getVolumePerformanceClassWithHttpInfo * *
Response Details
Status Code Description Response Headers
200 Show volume performance class details. -
200 List all networks of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call getVolumePerformanceClassAsync( + public okhttp3.Call listNetworksAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull String volumePerformanceClass, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - getVolumePerformanceClassValidateBeforeCall( - projectId, volumePerformanceClass, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listNetworksValidateBeforeCall(projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listAffinityGroups + * Build call for listNics * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -13329,17 +18711,20 @@ public okhttp3.Call getVolumePerformanceClassAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 List affinity groups. -
200 List project network interfaces. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listAffinityGroupsCall( - @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) + public okhttp3.Call listNicsCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -13358,10 +18743,16 @@ public okhttp3.Call listAffinityGroupsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/affinity-groups" + "/v2beta1/projects/{projectId}/regions/{region}/networks/{networkId}/nics" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -13369,6 +18760,11 @@ public okhttp3.Call listAffinityGroupsCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -13398,85 +18794,111 @@ public okhttp3.Call listAffinityGroupsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listAffinityGroupsValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) + private okhttp3.Call listNicsValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listAffinityGroups(Async)"); + "Missing the required parameter 'projectId' when calling listNics(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listNics(Async)"); + } + + // verify the required parameter 'networkId' is set + if (networkId == null) { + throw new ApiException( + "Missing the required parameter 'networkId' when calling listNics(Async)"); } - return listAffinityGroupsCall(projectId, _callback); + return listNicsCall(projectId, region, networkId, labelSelector, _callback); } /** - * Get the affinity groups setup for a project. Get the affinity groups created in a project. - * Affinity groups are an indication of locality of a server relative to another group of - * servers. They can be either running on the same host (affinity) or on different ones - * (anti-affinity). + * List all network interfaces inside a network. Get a list of all network interfaces inside a + * network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @return AffinityGroupListResponse + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return NICListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 List affinity groups. -
200 List project network interfaces. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public AffinityGroupListResponse listAffinityGroups(@javax.annotation.Nonnull UUID projectId) + public NICListResponse listNics( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - listAffinityGroupsWithHttpInfo(projectId); + ApiResponse localVarResp = + listNicsWithHttpInfo(projectId, region, networkId, labelSelector); return localVarResp.getData(); } /** - * Get the affinity groups setup for a project. Get the affinity groups created in a project. - * Affinity groups are an indication of locality of a server relative to another group of - * servers. They can be either running on the same host (affinity) or on different ones - * (anti-affinity). + * List all network interfaces inside a network. Get a list of all network interfaces inside a + * network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @return ApiResponse<AffinityGroupListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<NICListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 List affinity groups. -
200 List project network interfaces. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listAffinityGroupsWithHttpInfo( - @javax.annotation.Nonnull UUID projectId) throws ApiException { - okhttp3.Call localVarCall = listAffinityGroupsValidateBeforeCall(projectId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + public ApiResponse listNicsWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nullable String labelSelector) + throws ApiException { + okhttp3.Call localVarCall = + listNicsValidateBeforeCall(projectId, region, networkId, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Get the affinity groups setup for a project. (asynchronously) Get the affinity groups created - * in a project. Affinity groups are an indication of locality of a server relative to another - * group of servers. They can be either running on the same host (affinity) or on different ones - * (anti-affinity). + * List all network interfaces inside a network. (asynchronously) Get a list of all network + * interfaces inside a network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -13485,31 +18907,35 @@ public ApiResponse listAffinityGroupsWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 List affinity groups. -
200 List project network interfaces. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listAffinityGroupsAsync( + public okhttp3.Call listNicsAsync( @javax.annotation.Nonnull UUID projectId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = listAffinityGroupsValidateBeforeCall(projectId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listNicsValidateBeforeCall(projectId, region, networkId, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listAttachedVolumes + * Build call for listProjectNICs * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -13517,7 +18943,7 @@ public okhttp3.Call listAffinityGroupsAsync( * * * - * + * * * * @@ -13525,9 +18951,10 @@ public okhttp3.Call listAffinityGroupsAsync( * *
Response Details
Status Code Description Response Headers
200 List volume attachments. -
200 List network interfaces of the project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listAttachedVolumesCall( + public okhttp3.Call listProjectNICsCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -13547,13 +18974,13 @@ public okhttp3.Call listAttachedVolumesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/volume-attachments" + "/v2beta1/projects/{projectId}/regions/{region}/nics" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -13561,6 +18988,11 @@ public okhttp3.Call listAttachedVolumesCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -13590,39 +19022,42 @@ public okhttp3.Call listAttachedVolumesCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listAttachedVolumesValidateBeforeCall( + private okhttp3.Call listProjectNICsValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listAttachedVolumes(Async)"); + "Missing the required parameter 'projectId' when calling listProjectNICs(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling listAttachedVolumes(Async)"); + "Missing the required parameter 'region' when calling listProjectNICs(Async)"); } - return listAttachedVolumesCall(projectId, serverId, _callback); + return listProjectNICsCall(projectId, region, labelSelector, _callback); } /** - * List all volume attachments of a server. Get a list of all volume attachments of a server. + * List all network interfaces inside a project. Get a list of all network interfaces inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return VolumeAttachmentListResponse + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return NICListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13630,27 +19065,31 @@ private okhttp3.Call listAttachedVolumesValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List volume attachments. -
200 List network interfaces of the project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public VolumeAttachmentListResponse listAttachedVolumes( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public NICListResponse listProjectNICs( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - listAttachedVolumesWithHttpInfo(projectId, serverId); + ApiResponse localVarResp = + listProjectNICsWithHttpInfo(projectId, region, labelSelector); return localVarResp.getData(); } /** - * List all volume attachments of a server. Get a list of all volume attachments of a server. + * List all network interfaces inside a project. Get a list of all network interfaces inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ApiResponse<VolumeAttachmentListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<NICListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13658,21 +19097,24 @@ public VolumeAttachmentListResponse listAttachedVolumes( * *
Response Details
Status Code Description Response Headers
200 List volume attachments. -
200 List network interfaces of the project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listAttachedVolumesWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse listProjectNICsWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { okhttp3.Call localVarCall = - listAttachedVolumesValidateBeforeCall(projectId, serverId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listProjectNICsValidateBeforeCall(projectId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all volume attachments of a server. (asynchronously) Get a list of all volume - * attachments of a server. + * List all network interfaces inside a project. (asynchronously) Get a list of all network + * interfaces inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -13681,7 +19123,7 @@ public ApiResponse listAttachedVolumesWithHttpInfo * * * - * + * * * * @@ -13689,21 +19131,22 @@ public ApiResponse listAttachedVolumesWithHttpInfo * *
Response Details
Status Code Description Response Headers
200 List volume attachments. -
200 List network interfaces of the project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listAttachedVolumesAsync( + public okhttp3.Call listProjectNICsAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listAttachedVolumesValidateBeforeCall(projectId, serverId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listProjectNICsValidateBeforeCall(projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listAvailabilityZones + * Build call for listPublicIPRanges * * @param _callback Callback for upload/download progress * @return Call to execute @@ -13712,7 +19155,7 @@ public okhttp3.Call listAttachedVolumesAsync( * * * - * + * * * * @@ -13720,7 +19163,7 @@ public okhttp3.Call listAttachedVolumesAsync( * *
Response Details
Status Code Description Response Headers
200 Get a list of availability zones. -
200 List public IP ranges. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listAvailabilityZonesCall(final ApiCallback _callback) throws ApiException { + public okhttp3.Call listPublicIPRangesCall(final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers String[] localBasePaths = new String[] {}; @@ -13737,7 +19180,7 @@ public okhttp3.Call listAvailabilityZonesCall(final ApiCallback _callback) throw Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/availability-zones"; + String localVarPath = "/v2beta1/networks/public-ip-ranges"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -13774,22 +19217,22 @@ public okhttp3.Call listAvailabilityZonesCall(final ApiCallback _callback) throw } @SuppressWarnings("rawtypes") - private okhttp3.Call listAvailabilityZonesValidateBeforeCall(final ApiCallback _callback) + private okhttp3.Call listPublicIPRangesValidateBeforeCall(final ApiCallback _callback) throws ApiException { - return listAvailabilityZonesCall(_callback); + return listPublicIPRangesCall(_callback); } /** - * List all availability zones. Get a list of all availability zones. + * List all public IP ranges. Get a list of all public IP ranges that STACKIT uses. * - * @return AvailabilityZoneListResponse + * @return PublicNetworkListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13797,23 +19240,22 @@ private okhttp3.Call listAvailabilityZonesValidateBeforeCall(final ApiCallback _ * *
Response Details
Status Code Description Response Headers
200 Get a list of availability zones. -
200 List public IP ranges. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public AvailabilityZoneListResponse listAvailabilityZones() throws ApiException { - ApiResponse localVarResp = - listAvailabilityZonesWithHttpInfo(); + public PublicNetworkListResponse listPublicIPRanges() throws ApiException { + ApiResponse localVarResp = listPublicIPRangesWithHttpInfo(); return localVarResp.getData(); } /** - * List all availability zones. Get a list of all availability zones. + * List all public IP ranges. Get a list of all public IP ranges that STACKIT uses. * - * @return ApiResponse<AvailabilityZoneListResponse> + * @return ApiResponse<PublicNetworkListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13821,15 +19263,16 @@ public AvailabilityZoneListResponse listAvailabilityZones() throws ApiException * *
Response Details
Status Code Description Response Headers
200 Get a list of availability zones. -
200 List public IP ranges. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listAvailabilityZonesWithHttpInfo() + public ApiResponse listPublicIPRangesWithHttpInfo() throws ApiException { - okhttp3.Call localVarCall = listAvailabilityZonesValidateBeforeCall(null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = listPublicIPRangesValidateBeforeCall(null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all availability zones. (asynchronously) Get a list of all availability zones. + * List all public IP ranges. (asynchronously) Get a list of all public IP ranges that STACKIT + * uses. * * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -13839,7 +19282,7 @@ public ApiResponse listAvailabilityZonesWithHttpIn * * * - * + * * * * @@ -13847,19 +19290,20 @@ public ApiResponse listAvailabilityZonesWithHttpIn * *
Response Details
Status Code Description Response Headers
200 Get a list of availability zones. -
200 List public IP ranges. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listAvailabilityZonesAsync( - final ApiCallback _callback) throws ApiException { + public okhttp3.Call listPublicIPRangesAsync( + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = listAvailabilityZonesValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = listPublicIPRangesValidateBeforeCall(_callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listBackups + * Build call for listPublicIPs * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute @@ -13868,7 +19312,7 @@ public okhttp3.Call listAvailabilityZonesAsync( * * * - * + * * * * @@ -13876,8 +19320,9 @@ public okhttp3.Call listAvailabilityZonesAsync( * *
Response Details
Status Code Description Response Headers
200 List project backups. -
200 List project public IPs. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listBackupsCall( + public okhttp3.Call listPublicIPsCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { @@ -13898,10 +19343,13 @@ public okhttp3.Call listBackupsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups" + "/v2beta1/projects/{projectId}/regions/{region}/public-ips" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -13943,33 +19391,41 @@ public okhttp3.Call listBackupsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listBackupsValidateBeforeCall( + private okhttp3.Call listPublicIPsValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listBackups(Async)"); + "Missing the required parameter 'projectId' when calling listPublicIPs(Async)"); } - return listBackupsCall(projectId, labelSelector, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listPublicIPs(Async)"); + } + + return listPublicIPsCall(projectId, region, labelSelector, _callback); } /** - * List all backups inside a project. Get a list of all backups inside a project. + * List all public IPs inside a project. Get a list of all public IPs inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) - * @return BackupListResponse + * @return PublicIpListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -13977,28 +19433,30 @@ private okhttp3.Call listBackupsValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List project backups. -
200 List project public IPs. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public BackupListResponse listBackups( + public PublicIpListResponse listPublicIPs( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - listBackupsWithHttpInfo(projectId, labelSelector); + ApiResponse localVarResp = + listPublicIPsWithHttpInfo(projectId, region, labelSelector); return localVarResp.getData(); } /** - * List all backups inside a project. Get a list of all backups inside a project. + * List all public IPs inside a project. Get a list of all public IPs inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<BackupListResponse> + * @return ApiResponse<PublicIpListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14006,20 +19464,23 @@ public BackupListResponse listBackups( * *
Response Details
Status Code Description Response Headers
200 List project backups. -
200 List project public IPs. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listBackupsWithHttpInfo( + public ApiResponse listPublicIPsWithHttpInfo( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector) throws ApiException { - okhttp3.Call localVarCall = listBackupsValidateBeforeCall(projectId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listPublicIPsValidateBeforeCall(projectId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all backups inside a project. (asynchronously) Get a list of all backups inside a + * List all public IPs inside a project. (asynchronously) Get a list of all public IPs inside a * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -14029,7 +19490,7 @@ public ApiResponse listBackupsWithHttpInfo( * * * - * + * * * * @@ -14037,25 +19498,25 @@ public ApiResponse listBackupsWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List project backups. -
200 List project public IPs. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listBackupsAsync( + public okhttp3.Call listPublicIPsAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listBackupsValidateBeforeCall(projectId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listPublicIPsValidateBeforeCall(projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listImages + * Build call for listQuotas * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param all List all Images. (optional, default to false) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -14063,7 +19524,7 @@ public okhttp3.Call listBackupsAsync( * * * - * + * * * * @@ -14071,10 +19532,9 @@ public okhttp3.Call listBackupsAsync( * *
Response Details
Status Code Description Response Headers
200 List project images. -
200 List quotas. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listImagesCall( + public okhttp3.Call listQuotasCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean all, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -14094,10 +19554,13 @@ public okhttp3.Call listImagesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images" + "/v2beta1/projects/{projectId}/regions/{region}/quotas" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -14105,15 +19568,6 @@ public okhttp3.Call listImagesCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (all != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("all", all)); - } - - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -14143,35 +19597,39 @@ public okhttp3.Call listImagesCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listImagesValidateBeforeCall( + private okhttp3.Call listQuotasValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean all, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listImages(Async)"); + "Missing the required parameter 'projectId' when calling listQuotas(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listQuotas(Async)"); } - return listImagesCall(projectId, all, labelSelector, _callback); + return listQuotasCall(projectId, region, _callback); } /** - * List all Images inside a project. Get a list of all images inside a project. + * List project quotas. List quota limits and usage for project resources. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param all List all Images. (optional, default to false) - * @param labelSelector Filter resources by labels. (optional) - * @return ImageListResponse + * @param region The STACKIT Region of the resources. (required) + * @return QuotaListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14179,30 +19637,26 @@ private okhttp3.Call listImagesValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List project images. -
200 List quotas. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ImageListResponse listImages( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean all, - @javax.annotation.Nullable String labelSelector) + public QuotaListResponse listQuotas( + @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String region) throws ApiException { - ApiResponse localVarResp = - listImagesWithHttpInfo(projectId, all, labelSelector); + ApiResponse localVarResp = listQuotasWithHttpInfo(projectId, region); return localVarResp.getData(); } /** - * List all Images inside a project. Get a list of all images inside a project. + * List project quotas. List quota limits and usage for project resources. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param all List all Images. (optional, default to false) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<ImageListResponse> + * @param region The STACKIT Region of the resources. (required) + * @return ApiResponse<QuotaListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14210,23 +19664,19 @@ public ImageListResponse listImages( * *
Response Details
Status Code Description Response Headers
200 List project images. -
200 List quotas. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listImagesWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean all, - @javax.annotation.Nullable String labelSelector) + public ApiResponse listQuotasWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String region) throws ApiException { - okhttp3.Call localVarCall = - listImagesValidateBeforeCall(projectId, all, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = listQuotasValidateBeforeCall(projectId, region, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all Images inside a project. (asynchronously) Get a list of all images inside a project. + * List project quotas. (asynchronously) List quota limits and usage for project resources. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param all List all Images. (optional, default to false) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -14235,7 +19685,7 @@ public ApiResponse listImagesWithHttpInfo( * * * - * + * * * * @@ -14243,24 +19693,23 @@ public ApiResponse listImagesWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List project images. -
200 List quotas. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listImagesAsync( + public okhttp3.Call listQuotasAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean all, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = - listImagesValidateBeforeCall(projectId, all, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = listQuotasValidateBeforeCall(projectId, region, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listKeyPairs + * Build call for listRoutesOfManagementNetwork * - * @param labelSelector Filter resources by labels. (optional) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -14268,7 +19717,7 @@ public okhttp3.Call listImagesAsync( * * * - * + * * * * @@ -14276,8 +19725,10 @@ public okhttp3.Call listImagesAsync( * *
Response Details
Status Code Description Response Headers
200 List SSH keypairs. -
200 List management network routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listKeyPairsCall( - @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) + public okhttp3.Call listRoutesOfManagementNetworkCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -14295,7 +19746,14 @@ public okhttp3.Call listKeyPairsCall( Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/keypairs"; + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/management-network/routes" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -14303,11 +19761,6 @@ public okhttp3.Call listKeyPairsCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -14337,25 +19790,40 @@ public okhttp3.Call listKeyPairsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listKeyPairsValidateBeforeCall( - @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) + private okhttp3.Call listRoutesOfManagementNetworkValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { - return listKeyPairsCall(labelSelector, _callback); + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling listRoutesOfManagementNetwork(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listRoutesOfManagementNetwork(Async)"); + } + + return listRoutesOfManagementNetworkCall(projectId, region, _callback); } /** - * List all SSH keypairs for the requesting user. Get a list of all SSH keypairs assigned to the - * requesting user. + * List all routes for a management network. Get a list of all routes attached to a managed + * metwork. * - * @param labelSelector Filter resources by labels. (optional) - * @return KeyPairListResponse + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @return ManagementRouteListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14363,25 +19831,28 @@ private okhttp3.Call listKeyPairsValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List SSH keypairs. -
200 List management network routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public KeyPairListResponse listKeyPairs(@javax.annotation.Nullable String labelSelector) + public ManagementRouteListResponse listRoutesOfManagementNetwork( + @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String region) throws ApiException { - ApiResponse localVarResp = listKeyPairsWithHttpInfo(labelSelector); + ApiResponse localVarResp = + listRoutesOfManagementNetworkWithHttpInfo(projectId, region); return localVarResp.getData(); } /** - * List all SSH keypairs for the requesting user. Get a list of all SSH keypairs assigned to the - * requesting user. + * List all routes for a management network. Get a list of all routes attached to a managed + * metwork. * - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<KeyPairListResponse> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @return ApiResponse<ManagementRouteListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14389,18 +19860,21 @@ public KeyPairListResponse listKeyPairs(@javax.annotation.Nullable String labelS * *
Response Details
Status Code Description Response Headers
200 List SSH keypairs. -
200 List management network routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listKeyPairsWithHttpInfo( - @javax.annotation.Nullable String labelSelector) throws ApiException { - okhttp3.Call localVarCall = listKeyPairsValidateBeforeCall(labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + public ApiResponse listRoutesOfManagementNetworkWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull String region) + throws ApiException { + okhttp3.Call localVarCall = + listRoutesOfManagementNetworkValidateBeforeCall(projectId, region, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all SSH keypairs for the requesting user. (asynchronously) Get a list of all SSH - * keypairs assigned to the requesting user. + * List all routes for a management network. (asynchronously) Get a list of all routes attached + * to a managed metwork. * - * @param labelSelector Filter resources by labels. (optional) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -14409,7 +19883,7 @@ public ApiResponse listKeyPairsWithHttpInfo( * * * - * + * * * * @@ -14417,23 +19891,27 @@ public ApiResponse listKeyPairsWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List SSH keypairs. -
200 List management network routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listKeyPairsAsync( - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + public okhttp3.Call listRoutesOfManagementNetworkAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { - - okhttp3.Call localVarCall = listKeyPairsValidateBeforeCall(labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + + okhttp3.Call localVarCall = + listRoutesOfManagementNetworkValidateBeforeCall(projectId, region, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listMachineTypes + * Build call for listRoutesOfRoutingTable * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param filter Filter resources by fields. A subset of expr-lang is supported. See - * https://expr-lang.org/docs/language-definition for usage details. (optional) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -14441,7 +19919,7 @@ public okhttp3.Call listKeyPairsAsync( * * * - * + * * * * @@ -14449,9 +19927,12 @@ public okhttp3.Call listKeyPairsAsync( * *
Response Details
Status Code Description Response Headers
200 List of machine types. -
200 List all routing table routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listMachineTypesCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String filter, + public okhttp3.Call listRoutesOfRoutingTableCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -14471,10 +19952,19 @@ public okhttp3.Call listMachineTypesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/machine-types" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables/{routingTableId}/routes" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -14482,8 +19972,9 @@ public okhttp3.Call listMachineTypesCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (filter != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("filter", filter)); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); } final String[] localVarAccepts = {"application/json"}; @@ -14515,35 +20006,58 @@ public okhttp3.Call listMachineTypesCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listMachineTypesValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String filter, + private okhttp3.Call listRoutesOfRoutingTableValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listMachineTypes(Async)"); + "Missing the required parameter 'organizationId' when calling listRoutesOfRoutingTable(Async)"); + } + + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling listRoutesOfRoutingTable(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listRoutesOfRoutingTable(Async)"); + } + + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { + throw new ApiException( + "Missing the required parameter 'routingTableId' when calling listRoutesOfRoutingTable(Async)"); } - return listMachineTypesCall(projectId, filter, _callback); + return listRoutesOfRoutingTableCall( + organizationId, areaId, region, routingTableId, labelSelector, _callback); } /** - * List all machine types available for a project. Get a list of all machine type available in a - * project. + * List all routes in a routing table. Get a list of all routes in a routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param filter Filter resources by fields. A subset of expr-lang is supported. See - * https://expr-lang.org/docs/language-definition for usage details. (optional) - * @return MachineTypeListResponse + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return RouteListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14551,29 +20065,35 @@ private okhttp3.Call listMachineTypesValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List of machine types. -
200 List all routing table routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public MachineTypeListResponse listMachineTypes( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nullable String filter) + public RouteListResponse listRoutesOfRoutingTable( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - listMachineTypesWithHttpInfo(projectId, filter); + ApiResponse localVarResp = + listRoutesOfRoutingTableWithHttpInfo( + organizationId, areaId, region, routingTableId, labelSelector); return localVarResp.getData(); } /** - * List all machine types available for a project. Get a list of all machine type available in a - * project. + * List all routes in a routing table. Get a list of all routes in a routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param filter Filter resources by fields. A subset of expr-lang is supported. See - * https://expr-lang.org/docs/language-definition for usage details. (optional) - * @return ApiResponse<MachineTypeListResponse> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<RouteListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14581,21 +20101,29 @@ public MachineTypeListResponse listMachineTypes( * *
Response Details
Status Code Description Response Headers
200 List of machine types. -
200 List all routing table routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listMachineTypesWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nullable String filter) + public ApiResponse listRoutesOfRoutingTableWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nullable String labelSelector) throws ApiException { - okhttp3.Call localVarCall = listMachineTypesValidateBeforeCall(projectId, filter, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listRoutesOfRoutingTableValidateBeforeCall( + organizationId, areaId, region, routingTableId, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all machine types available for a project. (asynchronously) Get a list of all machine - * type available in a project. + * List all routes in a routing table. (asynchronously) Get a list of all routes in a routing + * table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param filter Filter resources by fields. A subset of expr-lang is supported. See - * https://expr-lang.org/docs/language-definition for usage details. (optional) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -14604,7 +20132,7 @@ public ApiResponse listMachineTypesWithHttpInfo( * * * - * + * * * * @@ -14612,24 +20140,30 @@ public ApiResponse listMachineTypesWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List of machine types. -
200 List all routing table routes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listMachineTypesAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String filter, - final ApiCallback _callback) + public okhttp3.Call listRoutesOfRoutingTableAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listMachineTypesValidateBeforeCall(projectId, filter, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listRoutesOfRoutingTableValidateBeforeCall( + organizationId, areaId, region, routingTableId, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listNetworkAreaProjects + * Build call for listRoutingTablesOfArea * * @param organizationId The identifier (ID) of a STACKIT Organization. (required) * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -14637,7 +20171,7 @@ public okhttp3.Call listMachineTypesAsync( * * * - * + * * * * @@ -14645,9 +20179,11 @@ public okhttp3.Call listMachineTypesAsync( * *
Response Details
Status Code Description Response Headers
200 List projects for a network area. -
200 List all routing tables. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworkAreaProjectsCall( + public okhttp3.Call listRoutingTablesOfAreaCall( @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -14667,13 +20203,16 @@ public okhttp3.Call listNetworkAreaProjectsCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/projects" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables" .replace( "{" + "organizationId" + "}", localVarApiClient.escapeString(organizationId.toString())) .replace( "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())); + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -14681,6 +20220,11 @@ public okhttp3.Call listNetworkAreaProjectsCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -14710,39 +20254,51 @@ public okhttp3.Call listNetworkAreaProjectsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listNetworkAreaProjectsValidateBeforeCall( + private okhttp3.Call listRoutingTablesOfAreaValidateBeforeCall( @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'organizationId' is set if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling listNetworkAreaProjects(Async)"); + "Missing the required parameter 'organizationId' when calling listRoutingTablesOfArea(Async)"); } // verify the required parameter 'areaId' is set if (areaId == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling listNetworkAreaProjects(Async)"); + "Missing the required parameter 'areaId' when calling listRoutingTablesOfArea(Async)"); } - return listNetworkAreaProjectsCall(organizationId, areaId, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listRoutingTablesOfArea(Async)"); + } + + return listRoutingTablesOfAreaCall( + organizationId, areaId, region, labelSelector, _callback); } /** - * List all projects using a network area. Get a list of all projects using a network area. + * List all routing tables in a network area. Get a list of all routing tables in a network + * area. * * @param organizationId The identifier (ID) of a STACKIT Organization. (required) * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @return ProjectListResponse + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return RoutingTableListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14750,27 +20306,33 @@ private okhttp3.Call listNetworkAreaProjectsValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List projects for a network area. -
200 List all routing tables. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ProjectListResponse listNetworkAreaProjects( - @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + public RoutingTableListResponse listRoutingTablesOfArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - listNetworkAreaProjectsWithHttpInfo(organizationId, areaId); + ApiResponse localVarResp = + listRoutingTablesOfAreaWithHttpInfo(organizationId, areaId, region, labelSelector); return localVarResp.getData(); } /** - * List all projects using a network area. Get a list of all projects using a network area. + * List all routing tables in a network area. Get a list of all routing tables in a network + * area. * * @param organizationId The identifier (ID) of a STACKIT Organization. (required) * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @return ApiResponse<ProjectListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<RoutingTableListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14778,21 +20340,27 @@ public ProjectListResponse listNetworkAreaProjects( * *
Response Details
Status Code Description Response Headers
200 List projects for a network area. -
200 List all routing tables. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listNetworkAreaProjectsWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + public ApiResponse listRoutingTablesOfAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { okhttp3.Call localVarCall = - listNetworkAreaProjectsValidateBeforeCall(organizationId, areaId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listRoutingTablesOfAreaValidateBeforeCall( + organizationId, areaId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all projects using a network area. (asynchronously) Get a list of all projects using a - * network area. + * List all routing tables in a network area. (asynchronously) Get a list of all routing tables + * in a network area. * * @param organizationId The identifier (ID) of a STACKIT Organization. (required) * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -14801,7 +20369,7 @@ public ApiResponse listNetworkAreaProjectsWithHttpInfo( * * * - * + * * * * @@ -14809,24 +20377,28 @@ public ApiResponse listNetworkAreaProjectsWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List projects for a network area. -
200 List all routing tables. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworkAreaProjectsAsync( + public okhttp3.Call listRoutingTablesOfAreaAsync( @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listNetworkAreaProjectsValidateBeforeCall(organizationId, areaId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listRoutingTablesOfAreaValidateBeforeCall( + organizationId, areaId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listNetworkAreaRanges + * Build call for listSecurityGroupRules * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -14834,7 +20406,7 @@ public okhttp3.Call listNetworkAreaProjectsAsync( * * * - * + * * * * @@ -14842,9 +20414,10 @@ public okhttp3.Call listNetworkAreaProjectsAsync( * *
Response Details
Status Code Description Response Headers
200 List all network ranges. -
200 List all rules of a security group. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworkAreaRangesCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + public okhttp3.Call listSecurityGroupRulesCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -14864,13 +20437,16 @@ public okhttp3.Call listNetworkAreaRangesCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/network-ranges" + "/v2beta1/projects/{projectId}/regions/{region}/security-groups/{securityGroupId}/rules" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -14907,40 +20483,47 @@ public okhttp3.Call listNetworkAreaRangesCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listNetworkAreaRangesValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + private okhttp3.Call listSecurityGroupRulesValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling listNetworkAreaRanges(Async)"); + "Missing the required parameter 'projectId' when calling listSecurityGroupRules(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling listNetworkAreaRanges(Async)"); + "Missing the required parameter 'region' when calling listSecurityGroupRules(Async)"); + } + + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupId' when calling listSecurityGroupRules(Async)"); } - return listNetworkAreaRangesCall(organizationId, areaId, _callback); + return listSecurityGroupRulesCall(projectId, region, securityGroupId, _callback); } /** - * List all network ranges in a network area. Get a list of all network ranges in a network - * area. + * List all rules for a security group. Get a list of all rules inside a security group. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @return NetworkRangeListResponse + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @return SecurityGroupRuleListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14948,28 +20531,30 @@ private okhttp3.Call listNetworkAreaRangesValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List all network ranges. -
200 List all rules of a security group. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NetworkRangeListResponse listNetworkAreaRanges( - @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + public SecurityGroupRuleListResponse listSecurityGroupRules( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { - ApiResponse localVarResp = - listNetworkAreaRangesWithHttpInfo(organizationId, areaId); + ApiResponse localVarResp = + listSecurityGroupRulesWithHttpInfo(projectId, region, securityGroupId); return localVarResp.getData(); } /** - * List all network ranges in a network area. Get a list of all network ranges in a network - * area. + * List all rules for a security group. Get a list of all rules inside a security group. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @return ApiResponse<NetworkRangeListResponse> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @return ApiResponse<SecurityGroupRuleListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -14977,21 +20562,24 @@ public NetworkRangeListResponse listNetworkAreaRanges( * *
Response Details
Status Code Description Response Headers
200 List all network ranges. -
200 List all rules of a security group. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listNetworkAreaRangesWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) + public ApiResponse listSecurityGroupRulesWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { okhttp3.Call localVarCall = - listNetworkAreaRangesValidateBeforeCall(organizationId, areaId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listSecurityGroupRulesValidateBeforeCall(projectId, region, securityGroupId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all network ranges in a network area. (asynchronously) Get a list of all network ranges - * in a network area. + * List all rules for a security group. (asynchronously) Get a list of all rules inside a + * security group. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -15000,7 +20588,7 @@ public ApiResponse listNetworkAreaRangesWithHttpInfo( * * * - * + * * * * @@ -15008,24 +20596,26 @@ public ApiResponse listNetworkAreaRangesWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List all network ranges. -
200 List all rules of a security group. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworkAreaRangesAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - final ApiCallback _callback) + public okhttp3.Call listSecurityGroupRulesAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listNetworkAreaRangesValidateBeforeCall(organizationId, areaId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listSecurityGroupRulesValidateBeforeCall( + projectId, region, securityGroupId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listNetworkAreaRoutes + * Build call for listSecurityGroups * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute @@ -15034,7 +20624,7 @@ public okhttp3.Call listNetworkAreaRangesAsync( * * * - * + * * * * @@ -15042,9 +20632,9 @@ public okhttp3.Call listNetworkAreaRangesAsync( * *
Response Details
Status Code Description Response Headers
200 List network routes. -
200 List all security groups of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworkAreaRoutesCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + public okhttp3.Call listSecurityGroupsCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { @@ -15065,13 +20655,13 @@ public okhttp3.Call listNetworkAreaRoutesCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/routes" + "/v2beta1/projects/{projectId}/regions/{region}/security-groups" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -15113,42 +20703,42 @@ public okhttp3.Call listNetworkAreaRoutesCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listNetworkAreaRoutesValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + private okhttp3.Call listSecurityGroupsValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling listNetworkAreaRoutes(Async)"); + "Missing the required parameter 'projectId' when calling listSecurityGroups(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling listNetworkAreaRoutes(Async)"); + "Missing the required parameter 'region' when calling listSecurityGroups(Async)"); } - return listNetworkAreaRoutesCall(organizationId, areaId, labelSelector, _callback); + return listSecurityGroupsCall(projectId, region, labelSelector, _callback); } /** - * List all network routes in a network area. Get a list of all network routes defined in a - * network area. + * List all security groups inside a project. Get a list of all security groups inside a + * project. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) - * @return RouteListResponse + * @return SecurityGroupListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15156,31 +20746,31 @@ private okhttp3.Call listNetworkAreaRoutesValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List network routes. -
200 List all security groups of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public RouteListResponse listNetworkAreaRoutes( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + public SecurityGroupListResponse listSecurityGroups( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - listNetworkAreaRoutesWithHttpInfo(organizationId, areaId, labelSelector); + ApiResponse localVarResp = + listSecurityGroupsWithHttpInfo(projectId, region, labelSelector); return localVarResp.getData(); } /** - * List all network routes in a network area. Get a list of all network routes defined in a - * network area. + * List all security groups inside a project. Get a list of all security groups inside a + * project. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<RouteListResponse> + * @return ApiResponse<SecurityGroupListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15188,24 +20778,23 @@ public RouteListResponse listNetworkAreaRoutes( * *
Response Details
Status Code Description Response Headers
200 List network routes. -
200 List all security groups of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listNetworkAreaRoutesWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + public ApiResponse listSecurityGroupsWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector) throws ApiException { okhttp3.Call localVarCall = - listNetworkAreaRoutesValidateBeforeCall( - organizationId, areaId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listSecurityGroupsValidateBeforeCall(projectId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all network routes in a network area. (asynchronously) Get a list of all network routes - * defined in a network area. + * List all security groups inside a project. (asynchronously) Get a list of all security groups + * inside a project. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -15215,7 +20804,7 @@ public ApiResponse listNetworkAreaRoutesWithHttpInfo( * * * - * + * * * * @@ -15223,26 +20812,26 @@ public ApiResponse listNetworkAreaRoutesWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List network routes. -
200 List all security groups of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworkAreaRoutesAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, + public okhttp3.Call listSecurityGroupsAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listNetworkAreaRoutesValidateBeforeCall( - organizationId, areaId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listSecurityGroupsValidateBeforeCall(projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listNetworkAreas + * Build call for listServerNICs * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -15250,7 +20839,7 @@ public okhttp3.Call listNetworkAreaRoutesAsync( * * * - * + * * * * @@ -15258,9 +20847,10 @@ public okhttp3.Call listNetworkAreaRoutesAsync( * *
Response Details
Status Code Description Response Headers
200 Get a list of all network areas. -
200 List network interfaces. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworkAreasCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nullable String labelSelector, + public okhttp3.Call listServerNICsCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -15280,10 +20870,16 @@ public okhttp3.Call listNetworkAreasCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/nics" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())); + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -15291,11 +20887,6 @@ public okhttp3.Call listNetworkAreasCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -15325,34 +20916,47 @@ public okhttp3.Call listNetworkAreasCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listNetworkAreasValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nullable String labelSelector, + private okhttp3.Call listServerNICsValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling listNetworkAreas(Async)"); + "Missing the required parameter 'projectId' when calling listServerNICs(Async)"); } - return listNetworkAreasCall(organizationId, labelSelector, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listServerNICs(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling listServerNICs(Async)"); + } + + return listServerNICsCall(projectId, region, serverId, _callback); } /** - * List all network areas in an organization. Get a list of all visible network areas defined in - * an organization. + * Get all network interfaces. Get all network interfaces attached to the server. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return NetworkAreaListResponse + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return NICListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15360,29 +20964,30 @@ private okhttp3.Call listNetworkAreasValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Get a list of all network areas. -
200 List network interfaces. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NetworkAreaListResponse listNetworkAreas( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nullable String labelSelector) + public NICListResponse listServerNICs( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - ApiResponse localVarResp = - listNetworkAreasWithHttpInfo(organizationId, labelSelector); + ApiResponse localVarResp = + listServerNICsWithHttpInfo(projectId, region, serverId); return localVarResp.getData(); } /** - * List all network areas in an organization. Get a list of all visible network areas defined in - * an organization. + * Get all network interfaces. Get all network interfaces attached to the server. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<NetworkAreaListResponse> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return ApiResponse<NICListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15390,22 +20995,24 @@ public NetworkAreaListResponse listNetworkAreas( * *
Response Details
Status Code Description Response Headers
200 Get a list of all network areas. -
200 List network interfaces. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listNetworkAreasWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nullable String labelSelector) + public ApiResponse listServerNICsWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { okhttp3.Call localVarCall = - listNetworkAreasValidateBeforeCall(organizationId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listServerNICsValidateBeforeCall(projectId, region, serverId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all network areas in an organization. (asynchronously) Get a list of all visible network - * areas defined in an organization. + * Get all network interfaces. (asynchronously) Get all network interfaces attached to the + * server. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -15414,7 +21021,7 @@ public ApiResponse listNetworkAreasWithHttpInfo( * * * - * + * * * * @@ -15422,24 +21029,26 @@ public ApiResponse listNetworkAreasWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Get a list of all network areas. -
200 List network interfaces. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworkAreasAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + public okhttp3.Call listServerNICsAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listNetworkAreasValidateBeforeCall(organizationId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listServerNICsValidateBeforeCall(projectId, region, serverId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listNetworks + * Build call for listServerServiceAccounts * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -15447,7 +21056,7 @@ public okhttp3.Call listNetworkAreasAsync( * * * - * + * * * * @@ -15455,9 +21064,10 @@ public okhttp3.Call listNetworkAreasAsync( * *
Response Details
Status Code Description Response Headers
200 List all networks of a project. -
200 List service accounts. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworksCall( + public okhttp3.Call listServerServiceAccountsCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -15477,10 +21087,16 @@ public okhttp3.Call listNetworksCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/service-accounts" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -15488,11 +21104,6 @@ public okhttp3.Call listNetworksCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -15522,33 +21133,47 @@ public okhttp3.Call listNetworksCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listNetworksValidateBeforeCall( + private okhttp3.Call listServerServiceAccountsValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listNetworks(Async)"); + "Missing the required parameter 'projectId' when calling listServerServiceAccounts(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listServerServiceAccounts(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling listServerServiceAccounts(Async)"); } - return listNetworksCall(projectId, labelSelector, _callback); + return listServerServiceAccountsCall(projectId, region, serverId, _callback); } /** - * List all networks inside a project. Get a list of all networks inside a project. + * List all service accounts of the Server. Get the list of the service accounts of the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return NetworkListResponse + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return ServiceAccountMailListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15556,28 +21181,30 @@ private okhttp3.Call listNetworksValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List all networks of a project. -
200 List service accounts. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NetworkListResponse listNetworks( + public ServiceAccountMailListResponse listServerServiceAccounts( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - ApiResponse localVarResp = - listNetworksWithHttpInfo(projectId, labelSelector); + ApiResponse localVarResp = + listServerServiceAccountsWithHttpInfo(projectId, region, serverId); return localVarResp.getData(); } /** - * List all networks inside a project. Get a list of all networks inside a project. + * List all service accounts of the Server. Get the list of the service accounts of the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<NetworkListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @return ApiResponse<ServiceAccountMailListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15585,21 +21212,24 @@ public NetworkListResponse listNetworks( * *
Response Details
Status Code Description Response Headers
200 List all networks of a project. -
200 List service accounts. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listNetworksWithHttpInfo( + public ApiResponse listServerServiceAccountsWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - okhttp3.Call localVarCall = listNetworksValidateBeforeCall(projectId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listServerServiceAccountsValidateBeforeCall(projectId, region, serverId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all networks inside a project. (asynchronously) Get a list of all networks inside a - * project. + * List all service accounts of the Server. (asynchronously) Get the list of the service + * accounts of the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -15608,7 +21238,7 @@ public ApiResponse listNetworksWithHttpInfo( * * * - * + * * * * @@ -15616,24 +21246,26 @@ public ApiResponse listNetworksWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List all networks of a project. -
200 List service accounts. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNetworksAsync( + public okhttp3.Call listServerServiceAccountsAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listNetworksValidateBeforeCall(projectId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listServerServiceAccountsValidateBeforeCall(projectId, region, serverId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listNics + * Build call for listServers * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param details Show detailed information about server. (optional, default to false) * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute @@ -15642,7 +21274,7 @@ public okhttp3.Call listNetworksAsync( * * * - * + * * * * @@ -15650,9 +21282,10 @@ public okhttp3.Call listNetworksAsync( * *
Response Details
Status Code Description Response Headers
200 List network interfaces of the network. -
200 List all servers of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNicsCall( + public okhttp3.Call listServersCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean details, @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { @@ -15673,13 +21306,13 @@ public okhttp3.Call listNicsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}/nics" + "/v2beta1/projects/{projectId}/regions/{region}/servers" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -15687,6 +21320,10 @@ public okhttp3.Call listNicsCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (details != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("details", details)); + } + if (labelSelector != null) { localVarQueryParams.addAll( localVarApiClient.parameterToPair("label_selector", labelSelector)); @@ -15721,42 +21358,43 @@ public okhttp3.Call listNicsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listNicsValidateBeforeCall( + private okhttp3.Call listServersValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean details, @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listNics(Async)"); + "Missing the required parameter 'projectId' when calling listServers(Async)"); } - // verify the required parameter 'networkId' is set - if (networkId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'networkId' when calling listNics(Async)"); + "Missing the required parameter 'region' when calling listServers(Async)"); } - return listNicsCall(projectId, networkId, labelSelector, _callback); + return listServersCall(projectId, region, details, labelSelector, _callback); } /** - * List all network interfaces inside a network. Get a list of all network interfaces inside a - * network. + * List all servers inside a project. Get a list of all servers inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param details Show detailed information about server. (optional, default to false) * @param labelSelector Filter resources by labels. (optional) - * @return NICListResponse + * @return ServerListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15764,31 +21402,32 @@ private okhttp3.Call listNicsValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List network interfaces of the network. -
200 List all servers of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NICListResponse listNics( + public ServerListResponse listServers( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean details, @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - listNicsWithHttpInfo(projectId, networkId, labelSelector); + ApiResponse localVarResp = + listServersWithHttpInfo(projectId, region, details, labelSelector); return localVarResp.getData(); } /** - * List all network interfaces inside a network. Get a list of all network interfaces inside a - * network. + * List all servers inside a project. Get a list of all servers inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param details Show detailed information about server. (optional, default to false) * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<NICListResponse> + * @return ApiResponse<ServerListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15796,23 +21435,25 @@ public NICListResponse listNics( * *
Response Details
Status Code Description Response Headers
200 List network interfaces of the network. -
200 List all servers of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listNicsWithHttpInfo( + public ApiResponse listServersWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean details, @javax.annotation.Nullable String labelSelector) throws ApiException { okhttp3.Call localVarCall = - listNicsValidateBeforeCall(projectId, networkId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listServersValidateBeforeCall(projectId, region, details, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all network interfaces inside a network. (asynchronously) Get a list of all network - * interfaces inside a network. + * List all servers inside a project. (asynchronously) Get a list of all servers inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param details Show detailed information about server. (optional, default to false) * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -15822,7 +21463,7 @@ public ApiResponse listNicsWithHttpInfo( * * * - * + * * * * @@ -15830,24 +21471,26 @@ public ApiResponse listNicsWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List network interfaces of the network. -
200 List all servers of a project. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listNicsAsync( + public okhttp3.Call listServersAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable Boolean details, @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listNicsValidateBeforeCall(projectId, networkId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listServersValidateBeforeCall(projectId, region, details, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listProjectNICs + * Build call for listVolumePerformanceClasses * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute @@ -15856,7 +21499,7 @@ public okhttp3.Call listNicsAsync( * * * - * + * * * * @@ -15864,8 +21507,9 @@ public okhttp3.Call listNicsAsync( * *
Response Details
Status Code Description Response Headers
200 List network interfaces of the project. -
200 List volume performance classes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listProjectNICsCall( + public okhttp3.Call listVolumePerformanceClassesCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { @@ -15886,10 +21530,13 @@ public okhttp3.Call listProjectNICsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/nics" + "/v2beta1/projects/{projectId}/regions/{region}/volume-performance-classes" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -15931,34 +21578,42 @@ public okhttp3.Call listProjectNICsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listProjectNICsValidateBeforeCall( + private okhttp3.Call listVolumePerformanceClassesValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listProjectNICs(Async)"); + "Missing the required parameter 'projectId' when calling listVolumePerformanceClasses(Async)"); } - return listProjectNICsCall(projectId, labelSelector, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listVolumePerformanceClasses(Async)"); + } + + return listVolumePerformanceClassesCall(projectId, region, labelSelector, _callback); } /** - * List all network interfaces inside a project. Get a list of all network interfaces inside a - * project. + * List all volume performance classes available for a project. Get a list of all volume + * performance classes available inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) - * @return NICListResponse + * @return VolumePerformanceClassListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15966,29 +21621,31 @@ private okhttp3.Call listProjectNICsValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List network interfaces of the project. -
200 List volume performance classes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NICListResponse listProjectNICs( + public VolumePerformanceClassListResponse listVolumePerformanceClasses( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - listProjectNICsWithHttpInfo(projectId, labelSelector); + ApiResponse localVarResp = + listVolumePerformanceClassesWithHttpInfo(projectId, region, labelSelector); return localVarResp.getData(); } /** - * List all network interfaces inside a project. Get a list of all network interfaces inside a - * project. + * List all volume performance classes available for a project. Get a list of all volume + * performance classes available inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<NICListResponse> + * @return ApiResponse<VolumePerformanceClassListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -15996,21 +21653,24 @@ public NICListResponse listProjectNICs( * *
Response Details
Status Code Description Response Headers
200 List network interfaces of the project. -
200 List volume performance classes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listProjectNICsWithHttpInfo( + public ApiResponse listVolumePerformanceClassesWithHttpInfo( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector) throws ApiException { okhttp3.Call localVarCall = - listProjectNICsValidateBeforeCall(projectId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + listVolumePerformanceClassesValidateBeforeCall( + projectId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all network interfaces inside a project. (asynchronously) Get a list of all network - * interfaces inside a project. + * List all volume performance classes available for a project. (asynchronously) Get a list of + * all volume performance classes available inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call @@ -16020,7 +21680,7 @@ public ApiResponse listProjectNICsWithHttpInfo( * * * - * + * * * * @@ -16028,22 +21688,27 @@ public ApiResponse listProjectNICsWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List network interfaces of the project. -
200 List volume performance classes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listProjectNICsAsync( + public okhttp3.Call listVolumePerformanceClassesAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listProjectNICsValidateBeforeCall(projectId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + listVolumePerformanceClassesValidateBeforeCall( + projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listPublicIPRanges + * Build call for listVolumes * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -16051,7 +21716,7 @@ public okhttp3.Call listProjectNICsAsync( * * * - * + * * * * @@ -16059,7 +21724,12 @@ public okhttp3.Call listProjectNICsAsync( * *
Response Details
Status Code Description Response Headers
200 List public IP ranges. -
200 List project volumes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listPublicIPRangesCall(final ApiCallback _callback) throws ApiException { + public okhttp3.Call listVolumesCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) + throws ApiException { String basePath = null; // Operation Servers String[] localBasePaths = new String[] {}; @@ -16076,7 +21746,14 @@ public okhttp3.Call listPublicIPRangesCall(final ApiCallback _callback) throws A Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/networks/public-ip-ranges"; + String localVarPath = + "/v2beta1/projects/{projectId}/regions/{region}/volumes" + .replace( + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -16084,6 +21761,11 @@ public okhttp3.Call listPublicIPRangesCall(final ApiCallback _callback) throws A Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -16113,22 +21795,41 @@ public okhttp3.Call listPublicIPRangesCall(final ApiCallback _callback) throws A } @SuppressWarnings("rawtypes") - private okhttp3.Call listPublicIPRangesValidateBeforeCall(final ApiCallback _callback) + private okhttp3.Call listVolumesValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { - return listPublicIPRangesCall(_callback); + // verify the required parameter 'projectId' is set + if (projectId == null) { + throw new ApiException( + "Missing the required parameter 'projectId' when calling listVolumes(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listVolumes(Async)"); + } + + return listVolumesCall(projectId, region, labelSelector, _callback); } /** - * List all public IP ranges. Get a list of all public IP ranges that STACKIT uses. + * List all volumes inside a project. Get a list of all volumes inside a project. * - * @return PublicNetworkListResponse + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return VolumeListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -16136,22 +21837,30 @@ private okhttp3.Call listPublicIPRangesValidateBeforeCall(final ApiCallback _cal * *
Response Details
Status Code Description Response Headers
200 List public IP ranges. -
200 List project volumes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public PublicNetworkListResponse listPublicIPRanges() throws ApiException { - ApiResponse localVarResp = listPublicIPRangesWithHttpInfo(); + public VolumeListResponse listVolumes( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) + throws ApiException { + ApiResponse localVarResp = + listVolumesWithHttpInfo(projectId, region, labelSelector); return localVarResp.getData(); } /** - * List all public IP ranges. Get a list of all public IP ranges that STACKIT uses. + * List all volumes inside a project. Get a list of all volumes inside a project. * - * @return ApiResponse<PublicNetworkListResponse> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<VolumeListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -16159,17 +21868,24 @@ public PublicNetworkListResponse listPublicIPRanges() throws ApiException { * *
Response Details
Status Code Description Response Headers
200 List public IP ranges. -
200 List project volumes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listPublicIPRangesWithHttpInfo() + public ApiResponse listVolumesWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - okhttp3.Call localVarCall = listPublicIPRangesValidateBeforeCall(null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listVolumesValidateBeforeCall(projectId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all public IP ranges. (asynchronously) Get a list of all public IP ranges that STACKIT - * uses. + * List all volumes inside a project. (asynchronously) Get a list of all volumes inside a + * project. * + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -16178,7 +21894,7 @@ public ApiResponse listPublicIPRangesWithHttpInfo() * * * - * + * * * * @@ -16186,20 +21902,27 @@ public ApiResponse listPublicIPRangesWithHttpInfo() * *
Response Details
Status Code Description Response Headers
200 List public IP ranges. -
200 List project volumes. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listPublicIPRangesAsync( - final ApiCallback _callback) throws ApiException { + public okhttp3.Call listVolumesAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) + throws ApiException { - okhttp3.Call localVarCall = listPublicIPRangesValidateBeforeCall(_callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + listVolumesValidateBeforeCall(projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listPublicIPs + * Build call for partialUpdateNetwork * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param partialUpdateNetworkPayload Request an update of a network. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -16207,7 +21930,7 @@ public okhttp3.Call listPublicIPRangesAsync( * * * - * + * * * * @@ -16215,9 +21938,11 @@ public okhttp3.Call listPublicIPRangesAsync( * *
Response Details
Status Code Description Response Headers
200 List project public IPs. -
202 An update was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listPublicIPsCall( + public okhttp3.Call partialUpdateNetworkCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -16233,14 +21958,20 @@ public okhttp3.Call listPublicIPsCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = partialUpdateNetworkPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/public-ips" + "/v2beta1/projects/{projectId}/regions/{region}/networks/{networkId}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -16248,18 +21979,13 @@ public okhttp3.Call listPublicIPsCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -16270,7 +21996,7 @@ public okhttp3.Call listPublicIPsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -16282,33 +22008,55 @@ public okhttp3.Call listPublicIPsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listPublicIPsValidateBeforeCall( + private okhttp3.Call partialUpdateNetworkValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listPublicIPs(Async)"); + "Missing the required parameter 'projectId' when calling partialUpdateNetwork(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling partialUpdateNetwork(Async)"); + } + + // verify the required parameter 'networkId' is set + if (networkId == null) { + throw new ApiException( + "Missing the required parameter 'networkId' when calling partialUpdateNetwork(Async)"); + } + + // verify the required parameter 'partialUpdateNetworkPayload' is set + if (partialUpdateNetworkPayload == null) { + throw new ApiException( + "Missing the required parameter 'partialUpdateNetworkPayload' when calling partialUpdateNetwork(Async)"); } - return listPublicIPsCall(projectId, labelSelector, _callback); + return partialUpdateNetworkCall( + projectId, region, networkId, partialUpdateNetworkPayload, _callback); } /** - * List all public IPs inside a project. Get a list of all public IPs inside a project. + * Update network settings. Update the settings of a network inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return PublicIpListResponse + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param partialUpdateNetworkPayload Request an update of a network. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -16316,28 +22064,30 @@ private okhttp3.Call listPublicIPsValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List project public IPs. -
202 An update was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public PublicIpListResponse listPublicIPs( + public void partialUpdateNetwork( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload) throws ApiException { - ApiResponse localVarResp = - listPublicIPsWithHttpInfo(projectId, labelSelector); - return localVarResp.getData(); + partialUpdateNetworkWithHttpInfo(projectId, region, networkId, partialUpdateNetworkPayload); } /** - * List all public IPs inside a project. Get a list of all public IPs inside a project. + * Update network settings. Update the settings of a network inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<PublicIpListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param partialUpdateNetworkPayload Request an update of a network. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -16345,21 +22095,25 @@ public PublicIpListResponse listPublicIPs( * *
Response Details
Status Code Description Response Headers
200 List project public IPs. -
202 An update was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listPublicIPsWithHttpInfo( + public ApiResponse partialUpdateNetworkWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload) throws ApiException { - okhttp3.Call localVarCall = listPublicIPsValidateBeforeCall(projectId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + okhttp3.Call localVarCall = + partialUpdateNetworkValidateBeforeCall( + projectId, region, networkId, partialUpdateNetworkPayload, null); + return localVarApiClient.execute(localVarCall); } /** - * List all public IPs inside a project. (asynchronously) Get a list of all public IPs inside a - * project. + * Update network settings. (asynchronously) Update the settings of a network inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param partialUpdateNetworkPayload Request an update of a network. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -16368,7 +22122,7 @@ public ApiResponse listPublicIPsWithHttpInfo( * * * - * + * * * * @@ -16376,23 +22130,27 @@ public ApiResponse listPublicIPsWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List project public IPs. -
202 An update was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listPublicIPsAsync( + public okhttp3.Call partialUpdateNetworkAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listPublicIPsValidateBeforeCall(projectId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + partialUpdateNetworkValidateBeforeCall( + projectId, region, networkId, partialUpdateNetworkPayload, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for listQuotas + * Build call for partialUpdateNetworkArea * - * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param partialUpdateNetworkAreaPayload Request to update an Area. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -16400,7 +22158,7 @@ public okhttp3.Call listPublicIPsAsync( * * * - * + * * * * @@ -16408,8 +22166,12 @@ public okhttp3.Call listPublicIPsAsync( * *
Response Details
Status Code Description Response Headers
200 List quotas. -
200 Area has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listQuotasCall( - @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) + public okhttp3.Call partialUpdateNetworkAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull + PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload, + final ApiCallback _callback) throws ApiException { String basePath = null; // Operation Servers @@ -16424,14 +22186,17 @@ public okhttp3.Call listQuotasCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = partialUpdateNetworkAreaPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/quotas" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) + .replace( + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -16445,7 +22210,7 @@ public okhttp3.Call listQuotasCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -16456,7 +22221,7 @@ public okhttp3.Call listQuotasCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -16468,30 +22233,49 @@ public okhttp3.Call listQuotasCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listQuotasValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, final ApiCallback _callback) + private okhttp3.Call partialUpdateNetworkAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull + PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload, + final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listQuotas(Async)"); + "Missing the required parameter 'organizationId' when calling partialUpdateNetworkArea(Async)"); + } + + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling partialUpdateNetworkArea(Async)"); + } + + // verify the required parameter 'partialUpdateNetworkAreaPayload' is set + if (partialUpdateNetworkAreaPayload == null) { + throw new ApiException( + "Missing the required parameter 'partialUpdateNetworkAreaPayload' when calling partialUpdateNetworkArea(Async)"); } - return listQuotasCall(projectId, _callback); + return partialUpdateNetworkAreaCall( + organizationId, areaId, partialUpdateNetworkAreaPayload, _callback); } /** - * List project quotas. List quota limits and usage for project resources. + * Update network area settings. Update the settings of a network area in an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @return QuotaListResponse + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param partialUpdateNetworkAreaPayload Request to update an Area. (required) + * @return NetworkArea * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -16499,24 +22283,32 @@ private okhttp3.Call listQuotasValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List quotas. -
200 Area has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public QuotaListResponse listQuotas(@javax.annotation.Nonnull UUID projectId) + public NetworkArea partialUpdateNetworkArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull + PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload) throws ApiException { - ApiResponse localVarResp = listQuotasWithHttpInfo(projectId); + ApiResponse localVarResp = + partialUpdateNetworkAreaWithHttpInfo( + organizationId, areaId, partialUpdateNetworkAreaPayload); return localVarResp.getData(); } /** - * List project quotas. List quota limits and usage for project resources. + * Update network area settings. Update the settings of a network area in an organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @return ApiResponse<QuotaListResponse> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param partialUpdateNetworkAreaPayload Request to update an Area. (required) + * @return ApiResponse<NetworkArea> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -16524,17 +22316,26 @@ public QuotaListResponse listQuotas(@javax.annotation.Nonnull UUID projectId) * *
Response Details
Status Code Description Response Headers
200 List quotas. -
200 Area has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listQuotasWithHttpInfo( - @javax.annotation.Nonnull UUID projectId) throws ApiException { - okhttp3.Call localVarCall = listQuotasValidateBeforeCall(projectId, null); - Type localVarReturnType = new TypeToken() {}.getType(); + public ApiResponse partialUpdateNetworkAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull + PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload) + throws ApiException { + okhttp3.Call localVarCall = + partialUpdateNetworkAreaValidateBeforeCall( + organizationId, areaId, partialUpdateNetworkAreaPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List project quotas. (asynchronously) List quota limits and usage for project resources. + * Update network area settings. (asynchronously) Update the settings of a network area in an + * organization. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param partialUpdateNetworkAreaPayload Request to update an Area. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -16543,7 +22344,7 @@ public ApiResponse listQuotasWithHttpInfo( * * * - * + * * * * @@ -16551,22 +22352,29 @@ public ApiResponse listQuotasWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List quotas. -
200 Area has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listQuotasAsync( - @javax.annotation.Nonnull UUID projectId, - final ApiCallback _callback) + public okhttp3.Call partialUpdateNetworkAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull + PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = listQuotasValidateBeforeCall(projectId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + partialUpdateNetworkAreaValidateBeforeCall( + organizationId, areaId, partialUpdateNetworkAreaPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listSecurityGroupRules + * Build call for rebootServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param action Defines if it is a soft or a hard reboot. (optional, default to soft) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -16574,17 +22382,20 @@ public okhttp3.Call listQuotasAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List all rules of a security group. -
202 Server reboot request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listSecurityGroupRulesCall( + public okhttp3.Call rebootServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable String action, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -16604,13 +22415,16 @@ public okhttp3.Call listSecurityGroupRulesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}/rules" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/reboot" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -16618,6 +22432,10 @@ public okhttp3.Call listSecurityGroupRulesCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (action != null) { + localVarQueryParams.addAll(localVarApiClient.parameterToPair("action", action)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -16635,7 +22453,7 @@ public okhttp3.Call listSecurityGroupRulesCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -16647,91 +22465,112 @@ public okhttp3.Call listSecurityGroupRulesCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listSecurityGroupRulesValidateBeforeCall( + private okhttp3.Call rebootServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable String action, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listSecurityGroupRules(Async)"); + "Missing the required parameter 'projectId' when calling rebootServer(Async)"); } - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling listSecurityGroupRules(Async)"); + "Missing the required parameter 'region' when calling rebootServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling rebootServer(Async)"); } - return listSecurityGroupRulesCall(projectId, securityGroupId, _callback); + return rebootServerCall(projectId, region, serverId, action, _callback); } /** - * List all rules for a security group. Get a list of all rules inside a security group. + * Reboot the server. Reboot the server. A soft reboot will attempt to gracefully shut down the + * server by passing the command to the operating system. A hard reboot will power cycle the + * server without waiting for the operating system to shutdown properly. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @return SecurityGroupRuleListResponse + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param action Defines if it is a soft or a hard reboot. (optional, default to soft) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List all rules of a security group. -
202 Server reboot request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public SecurityGroupRuleListResponse listSecurityGroupRules( + public void rebootServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable String action) throws ApiException { - ApiResponse localVarResp = - listSecurityGroupRulesWithHttpInfo(projectId, securityGroupId); - return localVarResp.getData(); + rebootServerWithHttpInfo(projectId, region, serverId, action); } /** - * List all rules for a security group. Get a list of all rules inside a security group. + * Reboot the server. Reboot the server. A soft reboot will attempt to gracefully shut down the + * server by passing the command to the operating system. A hard reboot will power cycle the + * server without waiting for the operating system to shutdown properly. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @return ApiResponse<SecurityGroupRuleListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param action Defines if it is a soft or a hard reboot. (optional, default to soft) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List all rules of a security group. -
202 Server reboot request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listSecurityGroupRulesWithHttpInfo( + public ApiResponse rebootServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable String action) throws ApiException { okhttp3.Call localVarCall = - listSecurityGroupRulesValidateBeforeCall(projectId, securityGroupId, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + rebootServerValidateBeforeCall(projectId, region, serverId, action, null); + return localVarApiClient.execute(localVarCall); } /** - * List all rules for a security group. (asynchronously) Get a list of all rules inside a - * security group. + * Reboot the server. (asynchronously) Reboot the server. A soft reboot will attempt to + * gracefully shut down the server by passing the command to the operating system. A hard reboot + * will power cycle the server without waiting for the operating system to shutdown properly. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param action Defines if it is a soft or a hard reboot. (optional, default to soft) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -16740,32 +22579,36 @@ public ApiResponse listSecurityGroupRulesWithHttp * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List all rules of a security group. -
202 Server reboot request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listSecurityGroupRulesAsync( + public okhttp3.Call rebootServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nullable String action, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listSecurityGroupRulesValidateBeforeCall(projectId, securityGroupId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + rebootServerValidateBeforeCall(projectId, region, serverId, action, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for listSecurityGroups + * Build call for removeNetworkFromServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -16773,7 +22616,7 @@ public okhttp3.Call listSecurityGroupRulesAsync( * * * - * + * * * * @@ -16781,9 +22624,11 @@ public okhttp3.Call listSecurityGroupRulesAsync( * *
Response Details
Status Code Description Response Headers
200 List all security groups of a project. -
204 Detach and delete network interface was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listSecurityGroupsCall( + public okhttp3.Call removeNetworkFromServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID networkId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -16803,10 +22648,19 @@ public okhttp3.Call listSecurityGroupsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/networks/{networkId}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -16814,11 +22668,6 @@ public okhttp3.Call listSecurityGroupsCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -16836,7 +22685,7 @@ public okhttp3.Call listSecurityGroupsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -16848,34 +22697,55 @@ public okhttp3.Call listSecurityGroupsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listSecurityGroupsValidateBeforeCall( + private okhttp3.Call removeNetworkFromServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID networkId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listSecurityGroups(Async)"); + "Missing the required parameter 'projectId' when calling removeNetworkFromServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling removeNetworkFromServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling removeNetworkFromServer(Async)"); + } + + // verify the required parameter 'networkId' is set + if (networkId == null) { + throw new ApiException( + "Missing the required parameter 'networkId' when calling removeNetworkFromServer(Async)"); } - return listSecurityGroupsCall(projectId, labelSelector, _callback); + return removeNetworkFromServerCall(projectId, region, serverId, networkId, _callback); } /** - * List all security groups inside a project. Get a list of all security groups inside a - * project. + * Detach and delete all network interfaces associated with the specified network. Detach and + * delete all network interfaces associated with the specified network from the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return SecurityGroupListResponse + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -16883,29 +22753,31 @@ private okhttp3.Call listSecurityGroupsValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List all security groups of a project. -
204 Detach and delete network interface was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public SecurityGroupListResponse listSecurityGroups( + public void removeNetworkFromServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID networkId) throws ApiException { - ApiResponse localVarResp = - listSecurityGroupsWithHttpInfo(projectId, labelSelector); - return localVarResp.getData(); + removeNetworkFromServerWithHttpInfo(projectId, region, serverId, networkId); } /** - * List all security groups inside a project. Get a list of all security groups inside a - * project. + * Detach and delete all network interfaces associated with the specified network. Detach and + * delete all network interfaces associated with the specified network from the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<SecurityGroupListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -16913,22 +22785,27 @@ public SecurityGroupListResponse listSecurityGroups( * *
Response Details
Status Code Description Response Headers
200 List all security groups of a project. -
204 Detach and delete network interface was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listSecurityGroupsWithHttpInfo( + public ApiResponse removeNetworkFromServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID networkId) throws ApiException { okhttp3.Call localVarCall = - listSecurityGroupsValidateBeforeCall(projectId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + removeNetworkFromServerValidateBeforeCall( + projectId, region, serverId, networkId, null); + return localVarApiClient.execute(localVarCall); } /** - * List all security groups inside a project. (asynchronously) Get a list of all security groups - * inside a project. + * Detach and delete all network interfaces associated with the specified network. + * (asynchronously) Detach and delete all network interfaces associated with the specified + * network from the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -16937,7 +22814,7 @@ public ApiResponse listSecurityGroupsWithHttpInfo( * * * - * + * * * * @@ -16945,24 +22822,28 @@ public ApiResponse listSecurityGroupsWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List all security groups of a project. -
204 Detach and delete network interface was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listSecurityGroupsAsync( + public okhttp3.Call removeNetworkFromServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID networkId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listSecurityGroupsValidateBeforeCall(projectId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + removeNetworkFromServerValidateBeforeCall( + projectId, region, serverId, networkId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for listServerNics + * Build call for removeNicFromServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -16970,7 +22851,7 @@ public okhttp3.Call listSecurityGroupsAsync( * * * - * + * * * * @@ -16978,9 +22859,11 @@ public okhttp3.Call listSecurityGroupsAsync( * *
Response Details
Status Code Description Response Headers
200 List network interfaces. -
204 Network interface detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listServerNicsCall( + public okhttp3.Call removeNicFromServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -17000,13 +22883,19 @@ public okhttp3.Call listServerNicsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/nics" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/nics/{nicId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "nicId" + "}", + localVarApiClient.escapeString(nicId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -17031,7 +22920,7 @@ public okhttp3.Call listServerNicsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17043,39 +22932,54 @@ public okhttp3.Call listServerNicsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listServerNicsValidateBeforeCall( + private okhttp3.Call removeNicFromServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listServerNics(Async)"); + "Missing the required parameter 'projectId' when calling removeNicFromServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling removeNicFromServer(Async)"); } // verify the required parameter 'serverId' is set if (serverId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling listServerNics(Async)"); + "Missing the required parameter 'serverId' when calling removeNicFromServer(Async)"); + } + + // verify the required parameter 'nicId' is set + if (nicId == null) { + throw new ApiException( + "Missing the required parameter 'nicId' when calling removeNicFromServer(Async)"); } - return listServerNicsCall(projectId, serverId, _callback); + return removeNicFromServerCall(projectId, region, serverId, nicId, _callback); } /** - * Get all network interfaces. Get all network interfaces attached to the server. + * Detach a network interface. Detach a network interface from a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return NICListResponse + * @param nicId The identifier (ID) of a network interface. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -17083,26 +22987,30 @@ private okhttp3.Call listServerNicsValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 List network interfaces. -
204 Network interface detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NICListResponse listServerNics( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public void removeNicFromServer( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID nicId) throws ApiException { - ApiResponse localVarResp = listServerNicsWithHttpInfo(projectId, serverId); - return localVarResp.getData(); + removeNicFromServerWithHttpInfo(projectId, region, serverId, nicId); } /** - * Get all network interfaces. Get all network interfaces attached to the server. + * Detach a network interface. Detach a network interface from a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ApiResponse<NICListResponse> + * @param nicId The identifier (ID) of a network interface. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -17110,20 +23018,24 @@ public NICListResponse listServerNics( * *
Response Details
Status Code Description Response Headers
200 List network interfaces. -
204 Network interface detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listServerNicsWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse removeNicFromServerWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID nicId) throws ApiException { - okhttp3.Call localVarCall = listServerNicsValidateBeforeCall(projectId, serverId, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + okhttp3.Call localVarCall = + removeNicFromServerValidateBeforeCall(projectId, region, serverId, nicId, null); + return localVarApiClient.execute(localVarCall); } /** - * Get all network interfaces. (asynchronously) Get all network interfaces attached to the - * server. + * Detach a network interface. (asynchronously) Detach a network interface from a server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param nicId The identifier (ID) of a network interface. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -17132,7 +23044,7 @@ public ApiResponse listServerNicsWithHttpInfo( * * * - * + * * * * @@ -17140,24 +23052,28 @@ public ApiResponse listServerNicsWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 List network interfaces. -
204 Network interface detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listServerNicsAsync( + public okhttp3.Call removeNicFromServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) + @javax.annotation.Nonnull UUID nicId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listServerNicsValidateBeforeCall(projectId, serverId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + removeNicFromServerValidateBeforeCall( + projectId, region, serverId, nicId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for listServerServiceAccounts + * Build call for removePublicIpFromServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -17165,17 +23081,20 @@ public okhttp3.Call listServerNicsAsync( * * * - * + * * * * - * + * + * * *
Response Details
Status Code Description Response Headers
200 List service accounts. -
204 Detach Public IP from server was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
404 The server or public IP was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listServerServiceAccountsCall( + public okhttp3.Call removePublicIpFromServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -17195,13 +23114,19 @@ public okhttp3.Call listServerServiceAccountsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/service-accounts" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/public-ips/{publicIpId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "publicIpId" + "}", + localVarApiClient.escapeString(publicIpId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -17226,7 +23151,7 @@ public okhttp3.Call listServerServiceAccountsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17238,89 +23163,114 @@ public okhttp3.Call listServerServiceAccountsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listServerServiceAccountsValidateBeforeCall( + private okhttp3.Call removePublicIpFromServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listServerServiceAccounts(Async)"); + "Missing the required parameter 'projectId' when calling removePublicIpFromServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling removePublicIpFromServer(Async)"); } // verify the required parameter 'serverId' is set if (serverId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling listServerServiceAccounts(Async)"); + "Missing the required parameter 'serverId' when calling removePublicIpFromServer(Async)"); + } + + // verify the required parameter 'publicIpId' is set + if (publicIpId == null) { + throw new ApiException( + "Missing the required parameter 'publicIpId' when calling removePublicIpFromServer(Async)"); } - return listServerServiceAccountsCall(projectId, serverId, _callback); + return removePublicIpFromServerCall(projectId, region, serverId, publicIpId, _callback); } /** - * List all service accounts of the Server. Get the list of the service accounts of the server. + * Dissociate a public IP from a server. Dissociate a public IP on an existing server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ServiceAccountMailListResponse + * @param publicIpId The identifier (ID) of a Public IP. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * - * + * + * * *
Response Details
Status Code Description Response Headers
200 List service accounts. -
204 Detach Public IP from server was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
404 The server or public IP was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ServiceAccountMailListResponse listServerServiceAccounts( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public void removePublicIpFromServer( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID publicIpId) throws ApiException { - ApiResponse localVarResp = - listServerServiceAccountsWithHttpInfo(projectId, serverId); - return localVarResp.getData(); + removePublicIpFromServerWithHttpInfo(projectId, region, serverId, publicIpId); } /** - * List all service accounts of the Server. Get the list of the service accounts of the server. + * Dissociate a public IP from a server. Dissociate a public IP on an existing server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ApiResponse<ServiceAccountMailListResponse> + * @param publicIpId The identifier (ID) of a Public IP. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * - * + * + * * *
Response Details
Status Code Description Response Headers
200 List service accounts. -
204 Detach Public IP from server was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
404 The server or public IP was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listServerServiceAccountsWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse removePublicIpFromServerWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID publicIpId) throws ApiException { okhttp3.Call localVarCall = - listServerServiceAccountsValidateBeforeCall(projectId, serverId, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + removePublicIpFromServerValidateBeforeCall( + projectId, region, serverId, publicIpId, null); + return localVarApiClient.execute(localVarCall); } /** - * List all service accounts of the Server. (asynchronously) Get the list of the service - * accounts of the server. + * Dissociate a public IP from a server. (asynchronously) Dissociate a public IP on an existing + * server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -17329,33 +23279,37 @@ public ApiResponse listServerServiceAccountsWith * * * - * + * * * * - * + * + * * *
Response Details
Status Code Description Response Headers
200 List service accounts. -
204 Detach Public IP from server was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
404 The server or public IP was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listServerServiceAccountsAsync( + public okhttp3.Call removePublicIpFromServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) + @javax.annotation.Nonnull UUID publicIpId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listServerServiceAccountsValidateBeforeCall(projectId, serverId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + removePublicIpFromServerValidateBeforeCall( + projectId, region, serverId, publicIpId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for listServers + * Build call for removeSecurityGroupFromServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param details Show detailed information about server. (optional, default to false) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -17363,18 +23317,20 @@ public okhttp3.Call listServerServiceAccountsAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List all servers of a project. -
204 Security group detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listServersCall( + public okhttp3.Call removeSecurityGroupFromServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean details, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -17394,10 +23350,19 @@ public okhttp3.Call listServersCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/security-groups/{securityGroupId}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -17405,15 +23370,6 @@ public okhttp3.Call listServersCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (details != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("details", details)); - } - - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -17431,7 +23387,7 @@ public okhttp3.Call listServersCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17443,91 +23399,115 @@ public okhttp3.Call listServersCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listServersValidateBeforeCall( + private okhttp3.Call removeSecurityGroupFromServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean details, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listServers(Async)"); + "Missing the required parameter 'projectId' when calling removeSecurityGroupFromServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling removeSecurityGroupFromServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling removeSecurityGroupFromServer(Async)"); + } + + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { + throw new ApiException( + "Missing the required parameter 'securityGroupId' when calling removeSecurityGroupFromServer(Async)"); } - return listServersCall(projectId, details, labelSelector, _callback); + return removeSecurityGroupFromServerCall( + projectId, region, serverId, securityGroupId, _callback); } /** - * List all servers inside a project. Get a list of all servers inside a project. + * Remove a server from a security group. Remove a server from a attached security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param details Show detailed information about server. (optional, default to false) - * @param labelSelector Filter resources by labels. (optional) - * @return ServerListResponse + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List all servers of a project. -
204 Security group detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ServerListResponse listServers( + public void removeSecurityGroupFromServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean details, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { - ApiResponse localVarResp = - listServersWithHttpInfo(projectId, details, labelSelector); - return localVarResp.getData(); + removeSecurityGroupFromServerWithHttpInfo(projectId, region, serverId, securityGroupId); } /** - * List all servers inside a project. Get a list of all servers inside a project. + * Remove a server from a security group. Remove a server from a attached security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param details Show detailed information about server. (optional, default to false) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<ServerListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List all servers of a project. -
204 Security group detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listServersWithHttpInfo( + public ApiResponse removeSecurityGroupFromServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean details, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID securityGroupId) throws ApiException { okhttp3.Call localVarCall = - listServersValidateBeforeCall(projectId, details, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + removeSecurityGroupFromServerValidateBeforeCall( + projectId, region, serverId, securityGroupId, null); + return localVarApiClient.execute(localVarCall); } /** - * List all servers inside a project. (asynchronously) Get a list of all servers inside a - * project. + * Remove a server from a security group. (asynchronously) Remove a server from a attached + * security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param details Show detailed information about server. (optional, default to false) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -17536,33 +23516,37 @@ public ApiResponse listServersWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List all servers of a project. -
204 Security group detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listServersAsync( + public okhttp3.Call removeSecurityGroupFromServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable Boolean details, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID securityGroupId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listServersValidateBeforeCall(projectId, details, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + removeSecurityGroupFromServerValidateBeforeCall( + projectId, region, serverId, securityGroupId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for listSnapshots + * Build call for removeServiceAccountFromServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param serviceAccountMail The e-mail address of a service account. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -17570,17 +23554,20 @@ public okhttp3.Call listServersAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List project snapshots. -
200 Service account detached from the server. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listSnapshotsCall( + public okhttp3.Call removeServiceAccountFromServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -17600,10 +23587,19 @@ public okhttp3.Call listSnapshotsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/service-accounts/{serviceAccountMail}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "serviceAccountMail" + "}", + localVarApiClient.escapeString(serviceAccountMail.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -17611,11 +23607,6 @@ public okhttp3.Call listSnapshotsCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -17633,7 +23624,7 @@ public okhttp3.Call listSnapshotsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17645,84 +23636,120 @@ public okhttp3.Call listSnapshotsCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listSnapshotsValidateBeforeCall( + private okhttp3.Call removeServiceAccountFromServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listSnapshots(Async)"); + "Missing the required parameter 'projectId' when calling removeServiceAccountFromServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling removeServiceAccountFromServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling removeServiceAccountFromServer(Async)"); + } + + // verify the required parameter 'serviceAccountMail' is set + if (serviceAccountMail == null) { + throw new ApiException( + "Missing the required parameter 'serviceAccountMail' when calling removeServiceAccountFromServer(Async)"); } - return listSnapshotsCall(projectId, labelSelector, _callback); + return removeServiceAccountFromServerCall( + projectId, region, serverId, serviceAccountMail, _callback); } /** - * List all snapshots inside a project. Get a list of all snapshots inside a project. + * Detach a service account from a server. Detach an additional service account from the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return SnapshotListResponse + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param serviceAccountMail The e-mail address of a service account. (required) + * @return ServiceAccountMailListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List project snapshots. -
200 Service account detached from the server. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public SnapshotListResponse listSnapshots( + public ServiceAccountMailListResponse removeServiceAccountFromServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail) throws ApiException { - ApiResponse localVarResp = - listSnapshotsWithHttpInfo(projectId, labelSelector); + ApiResponse localVarResp = + removeServiceAccountFromServerWithHttpInfo( + projectId, region, serverId, serviceAccountMail); return localVarResp.getData(); } /** - * List all snapshots inside a project. Get a list of all snapshots inside a project. + * Detach a service account from a server. Detach an additional service account from the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<SnapshotListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param serviceAccountMail The e-mail address of a service account. (required) + * @return ApiResponse<ServiceAccountMailListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List project snapshots. -
200 Service account detached from the server. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listSnapshotsWithHttpInfo( + public ApiResponse removeServiceAccountFromServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail) throws ApiException { - okhttp3.Call localVarCall = listSnapshotsValidateBeforeCall(projectId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); + okhttp3.Call localVarCall = + removeServiceAccountFromServerValidateBeforeCall( + projectId, region, serverId, serviceAccountMail, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * List all snapshots inside a project. (asynchronously) Get a list of all snapshots inside a - * project. + * Detach a service account from a server. (asynchronously) Detach an additional service account + * from the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param serviceAccountMail The e-mail address of a service account. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -17731,32 +23758,38 @@ public ApiResponse listSnapshotsWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List project snapshots. -
200 Service account detached from the server. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listSnapshotsAsync( + public okhttp3.Call removeServiceAccountFromServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String serviceAccountMail, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listSnapshotsValidateBeforeCall(projectId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + removeServiceAccountFromServerValidateBeforeCall( + projectId, region, serverId, serviceAccountMail, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for listVolumePerformanceClasses + * Build call for removeVolumeFromServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -17764,17 +23797,20 @@ public okhttp3.Call listSnapshotsAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List volume performance classes. -
204 Volume detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listVolumePerformanceClassesCall( + public okhttp3.Call removeVolumeFromServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -17794,10 +23830,19 @@ public okhttp3.Call listVolumePerformanceClassesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volume-performance-classes" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/volume-attachments/{volumeId}" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())) + .replace( + "{" + "volumeId" + "}", + localVarApiClient.escapeString(volumeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -17805,11 +23850,6 @@ public okhttp3.Call listVolumePerformanceClassesCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -17827,7 +23867,7 @@ public okhttp3.Call listVolumePerformanceClassesCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17839,87 +23879,114 @@ public okhttp3.Call listVolumePerformanceClassesCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listVolumePerformanceClassesValidateBeforeCall( + private okhttp3.Call removeVolumeFromServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listVolumePerformanceClasses(Async)"); + "Missing the required parameter 'projectId' when calling removeVolumeFromServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling removeVolumeFromServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling removeVolumeFromServer(Async)"); } - return listVolumePerformanceClassesCall(projectId, labelSelector, _callback); + // verify the required parameter 'volumeId' is set + if (volumeId == null) { + throw new ApiException( + "Missing the required parameter 'volumeId' when calling removeVolumeFromServer(Async)"); + } + + return removeVolumeFromServerCall(projectId, region, serverId, volumeId, _callback); } /** - * List all volume performance classes available for a project. Get a list of all volume - * performance classes available inside a project. + * Detach a volume from a server. Detach an existing volume from an existing server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return VolumePerformanceClassListResponse + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List volume performance classes. -
204 Volume detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public VolumePerformanceClassListResponse listVolumePerformanceClasses( + public void removeVolumeFromServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId) throws ApiException { - ApiResponse localVarResp = - listVolumePerformanceClassesWithHttpInfo(projectId, labelSelector); - return localVarResp.getData(); + removeVolumeFromServerWithHttpInfo(projectId, region, serverId, volumeId); } /** - * List all volume performance classes available for a project. Get a list of all volume - * performance classes available inside a project. + * Detach a volume from a server. Detach an existing volume from an existing server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<VolumePerformanceClassListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List volume performance classes. -
204 Volume detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listVolumePerformanceClassesWithHttpInfo( + public ApiResponse removeVolumeFromServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId) throws ApiException { okhttp3.Call localVarCall = - listVolumePerformanceClassesValidateBeforeCall(projectId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + removeVolumeFromServerValidateBeforeCall( + projectId, region, serverId, volumeId, null); + return localVarApiClient.execute(localVarCall); } /** - * List all volume performance classes available for a project. (asynchronously) Get a list of - * all volume performance classes available inside a project. + * Detach a volume from a server. (asynchronously) Detach an existing volume from an existing + * server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -17928,32 +23995,37 @@ public ApiResponse listVolumePerformanceClas * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List volume performance classes. -
204 Volume detachment request was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listVolumePerformanceClassesAsync( + public okhttp3.Call removeVolumeFromServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UUID volumeId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listVolumePerformanceClassesValidateBeforeCall(projectId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + removeVolumeFromServerValidateBeforeCall( + projectId, region, serverId, volumeId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for listVolumes + * Build call for rescueServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param rescueServerPayload Request a server rescue. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -17961,17 +24033,20 @@ public okhttp3.Call listVolumePerformanceClassesAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List project volumes. -
202 Server rescue request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listVolumesCall( + public okhttp3.Call rescueServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull RescueServerPayload rescueServerPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -17987,14 +24062,20 @@ public okhttp3.Call listVolumesCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = rescueServerPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/rescue" .replace( "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -18002,18 +24083,13 @@ public okhttp3.Call listVolumesCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (labelSelector != null) { - localVarQueryParams.addAll( - localVarApiClient.parameterToPair("label_selector", labelSelector)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -18024,7 +24100,7 @@ public okhttp3.Call listVolumesCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -18036,84 +24112,119 @@ public okhttp3.Call listVolumesCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call listVolumesValidateBeforeCall( + private okhttp3.Call rescueServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull RescueServerPayload rescueServerPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling listVolumes(Async)"); + "Missing the required parameter 'projectId' when calling rescueServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling rescueServer(Async)"); + } + + // verify the required parameter 'serverId' is set + if (serverId == null) { + throw new ApiException( + "Missing the required parameter 'serverId' when calling rescueServer(Async)"); + } + + // verify the required parameter 'rescueServerPayload' is set + if (rescueServerPayload == null) { + throw new ApiException( + "Missing the required parameter 'rescueServerPayload' when calling rescueServer(Async)"); } - return listVolumesCall(projectId, labelSelector, _callback); + return rescueServerCall(projectId, region, serverId, rescueServerPayload, _callback); } /** - * List all volumes inside a project. Get a list of all volumes inside a project. + * Rescue an existing server. Rescue an existing server. It is shutdown and the initial image is + * attached as the boot volume, while the boot volume is attached as secondary volume and the + * server is booted. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return VolumeListResponse + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param rescueServerPayload Request a server rescue. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List project volumes. -
202 Server rescue request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public VolumeListResponse listVolumes( + public void rescueServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull RescueServerPayload rescueServerPayload) throws ApiException { - ApiResponse localVarResp = - listVolumesWithHttpInfo(projectId, labelSelector); - return localVarResp.getData(); + rescueServerWithHttpInfo(projectId, region, serverId, rescueServerPayload); } /** - * List all volumes inside a project. Get a list of all volumes inside a project. + * Rescue an existing server. Rescue an existing server. It is shutdown and the initial image is + * attached as the boot volume, while the boot volume is attached as secondary volume and the + * server is booted. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) - * @return ApiResponse<VolumeListResponse> + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param rescueServerPayload Request a server rescue. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List project volumes. -
202 Server rescue request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse listVolumesWithHttpInfo( + public ApiResponse rescueServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull RescueServerPayload rescueServerPayload) throws ApiException { - okhttp3.Call localVarCall = listVolumesValidateBeforeCall(projectId, labelSelector, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + okhttp3.Call localVarCall = + rescueServerValidateBeforeCall( + projectId, region, serverId, rescueServerPayload, null); + return localVarApiClient.execute(localVarCall); } /** - * List all volumes inside a project. (asynchronously) Get a list of all volumes inside a - * project. + * Rescue an existing server. (asynchronously) Rescue an existing server. It is shutdown and the + * initial image is attached as the boot volume, while the boot volume is attached as secondary + * volume and the server is booted. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param labelSelector Filter resources by labels. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param rescueServerPayload Request a server rescue. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -18122,33 +24233,37 @@ public ApiResponse listVolumesWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 List project volumes. -
202 Server rescue request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call listVolumesAsync( + public okhttp3.Call rescueServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nullable String labelSelector, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull RescueServerPayload rescueServerPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - listVolumesValidateBeforeCall(projectId, labelSelector, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + rescueServerValidateBeforeCall( + projectId, region, serverId, rescueServerPayload, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for partialUpdateNetwork + * Build call for resizeServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param partialUpdateNetworkPayload Request an update of a network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param resizeServerPayload Request a resize of a server. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18156,18 +24271,20 @@ public okhttp3.Call listVolumesAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
202 An update was accepted. -
202 Server resize request is accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call partialUpdateNetworkCall( + public okhttp3.Call resizeServerCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -18183,17 +24300,20 @@ public okhttp3.Call partialUpdateNetworkCall( basePath = null; } - Object localVarPostBody = partialUpdateNetworkPayload; + Object localVarPostBody = resizeServerPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/resize" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -18218,7 +24338,7 @@ public okhttp3.Call partialUpdateNetworkCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -18230,68 +24350,78 @@ public okhttp3.Call partialUpdateNetworkCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call partialUpdateNetworkValidateBeforeCall( + private okhttp3.Call resizeServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling partialUpdateNetwork(Async)"); + "Missing the required parameter 'projectId' when calling resizeServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling resizeServer(Async)"); } - // verify the required parameter 'networkId' is set - if (networkId == null) { + // verify the required parameter 'serverId' is set + if (serverId == null) { throw new ApiException( - "Missing the required parameter 'networkId' when calling partialUpdateNetwork(Async)"); + "Missing the required parameter 'serverId' when calling resizeServer(Async)"); } - // verify the required parameter 'partialUpdateNetworkPayload' is set - if (partialUpdateNetworkPayload == null) { + // verify the required parameter 'resizeServerPayload' is set + if (resizeServerPayload == null) { throw new ApiException( - "Missing the required parameter 'partialUpdateNetworkPayload' when calling partialUpdateNetwork(Async)"); + "Missing the required parameter 'resizeServerPayload' when calling resizeServer(Async)"); } - return partialUpdateNetworkCall( - projectId, networkId, partialUpdateNetworkPayload, _callback); + return resizeServerCall(projectId, region, serverId, resizeServerPayload, _callback); } /** - * Update network settings. Update the settings of a network inside a project. + * Resize a server. Resize the server to the given machine type. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param partialUpdateNetworkPayload Request an update of a network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param resizeServerPayload Request a resize of a server. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
202 An update was accepted. -
202 Server resize request is accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void partialUpdateNetwork( + public void resizeServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload) throws ApiException { - partialUpdateNetworkWithHttpInfo(projectId, networkId, partialUpdateNetworkPayload); + resizeServerWithHttpInfo(projectId, region, serverId, resizeServerPayload); } /** - * Update network settings. Update the settings of a network inside a project. + * Resize a server. Resize the server to the given machine type. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param partialUpdateNetworkPayload Request an update of a network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param resizeServerPayload Request a resize of a server. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -18299,31 +24429,34 @@ public void partialUpdateNetwork( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
202 An update was accepted. -
202 Server resize request is accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse partialUpdateNetworkWithHttpInfo( + public ApiResponse resizeServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload) throws ApiException { okhttp3.Call localVarCall = - partialUpdateNetworkValidateBeforeCall( - projectId, networkId, partialUpdateNetworkPayload, null); + resizeServerValidateBeforeCall( + projectId, region, serverId, resizeServerPayload, null); return localVarApiClient.execute(localVarCall); } /** - * Update network settings. (asynchronously) Update the settings of a network inside a project. + * Resize a server. (asynchronously) Resize the server to the given machine type. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param partialUpdateNetworkPayload Request an update of a network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param resizeServerPayload Request a resize of a server. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -18332,34 +24465,37 @@ public ApiResponse partialUpdateNetworkWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
202 An update was accepted. -
202 Server resize request is accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call partialUpdateNetworkAsync( + public okhttp3.Call resizeServerAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - partialUpdateNetworkValidateBeforeCall( - projectId, networkId, partialUpdateNetworkPayload, _callback); + resizeServerValidateBeforeCall( + projectId, region, serverId, resizeServerPayload, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for partialUpdateNetworkArea + * Build call for resizeVolume * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param partialUpdateNetworkAreaPayload Request to update an area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param resizeVolumePayload Request a volume resize. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18367,19 +24503,20 @@ public okhttp3.Call partialUpdateNetworkAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Area has been updated. -
202 Volume resize request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call partialUpdateNetworkAreaCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull - PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload, + public okhttp3.Call resizeVolumeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -18395,17 +24532,20 @@ public okhttp3.Call partialUpdateNetworkAreaCall( basePath = null; } - Object localVarPostBody = partialUpdateNetworkAreaPayload; + Object localVarPostBody = resizeVolumePayload; // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}" + "/v2beta1/projects/{projectId}/regions/{region}/volumes/{volumeId}/resize" .replace( - "{" + "organizationId" + "}", - localVarApiClient.escapeString(organizationId.toString())) + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "volumeId" + "}", + localVarApiClient.escapeString(volumeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -18430,7 +24570,7 @@ public okhttp3.Call partialUpdateNetworkAreaCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -18442,109 +24582,110 @@ public okhttp3.Call partialUpdateNetworkAreaCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call partialUpdateNetworkAreaValidateBeforeCall( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull - PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload, + private okhttp3.Call resizeVolumeValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'organizationId' is set - if (organizationId == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling partialUpdateNetworkArea(Async)"); + "Missing the required parameter 'projectId' when calling resizeVolume(Async)"); } - // verify the required parameter 'areaId' is set - if (areaId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling partialUpdateNetworkArea(Async)"); + "Missing the required parameter 'region' when calling resizeVolume(Async)"); } - // verify the required parameter 'partialUpdateNetworkAreaPayload' is set - if (partialUpdateNetworkAreaPayload == null) { + // verify the required parameter 'volumeId' is set + if (volumeId == null) { throw new ApiException( - "Missing the required parameter 'partialUpdateNetworkAreaPayload' when calling partialUpdateNetworkArea(Async)"); + "Missing the required parameter 'volumeId' when calling resizeVolume(Async)"); } - return partialUpdateNetworkAreaCall( - organizationId, areaId, partialUpdateNetworkAreaPayload, _callback); + return resizeVolumeCall(projectId, region, volumeId, resizeVolumePayload, _callback); } /** - * Update network area settings. Update the settings of a network area in an organization. + * Update the size of a volume. Update the size of a block device volume. The new volume size + * must be larger than the current size. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param partialUpdateNetworkAreaPayload Request to update an area. (required) - * @return NetworkArea + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param resizeVolumePayload Request a volume resize. (optional) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Area has been updated. -
202 Volume resize request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NetworkArea partialUpdateNetworkArea( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull - PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload) + public void resizeVolume( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload) throws ApiException { - ApiResponse localVarResp = - partialUpdateNetworkAreaWithHttpInfo( - organizationId, areaId, partialUpdateNetworkAreaPayload); - return localVarResp.getData(); + resizeVolumeWithHttpInfo(projectId, region, volumeId, resizeVolumePayload); } /** - * Update network area settings. Update the settings of a network area in an organization. + * Update the size of a volume. Update the size of a block device volume. The new volume size + * must be larger than the current size. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param partialUpdateNetworkAreaPayload Request to update an area. (required) - * @return ApiResponse<NetworkArea> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param resizeVolumePayload Request a volume resize. (optional) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Area has been updated. -
202 Volume resize request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse partialUpdateNetworkAreaWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull - PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload) + public ApiResponse resizeVolumeWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload) throws ApiException { okhttp3.Call localVarCall = - partialUpdateNetworkAreaValidateBeforeCall( - organizationId, areaId, partialUpdateNetworkAreaPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + resizeVolumeValidateBeforeCall( + projectId, region, volumeId, resizeVolumePayload, null); + return localVarApiClient.execute(localVarCall); } /** - * Update network area settings. (asynchronously) Update the settings of a network area in an - * organization. + * Update the size of a volume. (asynchronously) Update the size of a block device volume. The + * new volume size must be larger than the current size. * - * @param organizationId The identifier (ID) of a STACKIT Organization. (required) - * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param partialUpdateNetworkAreaPayload Request to update an area. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param resizeVolumePayload Request a volume resize. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -18553,36 +24694,36 @@ public ApiResponse partialUpdateNetworkAreaWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Area has been updated. -
202 Volume resize request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call partialUpdateNetworkAreaAsync( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull - PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload, - final ApiCallback _callback) + public okhttp3.Call resizeVolumeAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - partialUpdateNetworkAreaValidateBeforeCall( - organizationId, areaId, partialUpdateNetworkAreaPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + resizeVolumeValidateBeforeCall( + projectId, region, volumeId, resizeVolumePayload, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for rebootServer + * Build call for restoreBackup * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param action Defines if it is a soft or a hard reboot. (optional, default to soft) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18590,19 +24731,18 @@ public okhttp3.Call partialUpdateNetworkAreaAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server reboot request accepted. -
202 Backup restore request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call rebootServerCall( + public okhttp3.Call restoreBackupCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable String action, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -18622,13 +24762,16 @@ public okhttp3.Call rebootServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/reboot" + "/v2beta1/projects/{projectId}/regions/{region}/backups/{backupId}/restore" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "backupId" + "}", + localVarApiClient.escapeString(backupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -18636,10 +24779,6 @@ public okhttp3.Call rebootServerCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); - if (action != null) { - localVarQueryParams.addAll(localVarApiClient.parameterToPair("action", action)); - } - final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { @@ -18669,66 +24808,71 @@ public okhttp3.Call rebootServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call rebootServerValidateBeforeCall( + private okhttp3.Call restoreBackupValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable String action, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling rebootServer(Async)"); + "Missing the required parameter 'projectId' when calling restoreBackup(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling rebootServer(Async)"); + "Missing the required parameter 'region' when calling restoreBackup(Async)"); + } + + // verify the required parameter 'backupId' is set + if (backupId == null) { + throw new ApiException( + "Missing the required parameter 'backupId' when calling restoreBackup(Async)"); } - return rebootServerCall(projectId, serverId, action, _callback); + return restoreBackupCall(projectId, region, backupId, _callback); } /** - * Reboot the server. Reboot the server. A soft reboot will attempt to gracefully shut down the - * server by passing the command to the operating system. A hard reboot will power cycle the - * server without waiting for the operating system to shutdown properly. + * Restore Backup to the referenced source Volume. Restores a Backup to the existing Volume it + * references to. The use of this endpoint is disruptive as the volume needs to be detached. If + * a new volume is to be created use the volumes endpoint with the option to create from backup. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param action Defines if it is a soft or a hard reboot. (optional, default to soft) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server reboot request accepted. -
202 Backup restore request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void rebootServer( + public void restoreBackup( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable String action) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId) throws ApiException { - rebootServerWithHttpInfo(projectId, serverId, action); + restoreBackupWithHttpInfo(projectId, region, backupId); } /** - * Reboot the server. Reboot the server. A soft reboot will attempt to gracefully shut down the - * server by passing the command to the operating system. A hard reboot will power cycle the - * server without waiting for the operating system to shutdown properly. + * Restore Backup to the referenced source Volume. Restores a Backup to the existing Volume it + * references to. The use of this endpoint is disruptive as the volume needs to be detached. If + * a new volume is to be created use the volumes endpoint with the option to create from backup. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param action Defines if it is a soft or a hard reboot. (optional, default to soft) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -18736,33 +24880,33 @@ public void rebootServer( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server reboot request accepted. -
202 Backup restore request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse rebootServerWithHttpInfo( + public ApiResponse restoreBackupWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable String action) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId) throws ApiException { okhttp3.Call localVarCall = - rebootServerValidateBeforeCall(projectId, serverId, action, null); + restoreBackupValidateBeforeCall(projectId, region, backupId, null); return localVarApiClient.execute(localVarCall); } /** - * Reboot the server. (asynchronously) Reboot the server. A soft reboot will attempt to - * gracefully shut down the server by passing the command to the operating system. A hard reboot - * will power cycle the server without waiting for the operating system to shutdown properly. + * Restore Backup to the referenced source Volume. (asynchronously) Restores a Backup to the + * existing Volume it references to. The use of this endpoint is disruptive as the volume needs + * to be detached. If a new volume is to be created use the volumes endpoint with the option to + * create from backup. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param action Defines if it is a soft or a hard reboot. (optional, default to soft) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -18771,34 +24915,34 @@ public ApiResponse rebootServerWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server reboot request accepted. -
202 Backup restore request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call rebootServerAsync( + public okhttp3.Call restoreBackupAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nullable String action, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - rebootServerValidateBeforeCall(projectId, serverId, action, _callback); + restoreBackupValidateBeforeCall(projectId, region, backupId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for removeNetworkFromServer + * Build call for setImageShare * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param setImageSharePayload Settings for an Image Share. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -18806,7 +24950,7 @@ public okhttp3.Call rebootServerAsync( * * * - * + * * * * @@ -18814,10 +24958,11 @@ public okhttp3.Call rebootServerAsync( * *
Response Details
Status Code Description Response Headers
204 Detach and delete network interface was accepted. -
200 Setting Image share successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeNetworkFromServerCall( + public okhttp3.Call setImageShareCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -18833,20 +24978,20 @@ public okhttp3.Call removeNetworkFromServerCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = setImageSharePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/networks/{networkId}" + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}/share" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())); + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -18860,7 +25005,7 @@ public okhttp3.Call removeNetworkFromServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -18871,7 +25016,7 @@ public okhttp3.Call removeNetworkFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -18883,47 +25028,55 @@ public okhttp3.Call removeNetworkFromServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call removeNetworkFromServerValidateBeforeCall( + private okhttp3.Call setImageShareValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling removeNetworkFromServer(Async)"); + "Missing the required parameter 'projectId' when calling setImageShare(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling removeNetworkFromServer(Async)"); + "Missing the required parameter 'region' when calling setImageShare(Async)"); } - // verify the required parameter 'networkId' is set - if (networkId == null) { + // verify the required parameter 'imageId' is set + if (imageId == null) { throw new ApiException( - "Missing the required parameter 'networkId' when calling removeNetworkFromServer(Async)"); + "Missing the required parameter 'imageId' when calling setImageShare(Async)"); + } + + // verify the required parameter 'setImageSharePayload' is set + if (setImageSharePayload == null) { + throw new ApiException( + "Missing the required parameter 'setImageSharePayload' when calling setImageShare(Async)"); } - return removeNetworkFromServerCall(projectId, serverId, networkId, _callback); + return setImageShareCall(projectId, region, imageId, setImageSharePayload, _callback); } /** - * Detach and delete all network interfaces associated with the specified network. Detach and - * delete all network interfaces associated with the specified network from the server. + * Set image share. Set share of an Image. New Options will replace existing settings. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param setImageSharePayload Settings for an Image Share. (required) + * @return ImageShare * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -18931,29 +25084,32 @@ private okhttp3.Call removeNetworkFromServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Detach and delete network interface was accepted. -
200 Setting Image share successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void removeNetworkFromServer( + public ImageShare setImageShare( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID networkId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload) throws ApiException { - removeNetworkFromServerWithHttpInfo(projectId, serverId, networkId); + ApiResponse localVarResp = + setImageShareWithHttpInfo(projectId, region, imageId, setImageSharePayload); + return localVarResp.getData(); } /** - * Detach and delete all network interfaces associated with the specified network. Detach and - * delete all network interfaces associated with the specified network from the server. + * Set image share. Set share of an Image. New Options will replace existing settings. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param setImageSharePayload Settings for an Image Share. (required) + * @return ApiResponse<ImageShare> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -18961,24 +25117,27 @@ public void removeNetworkFromServer( * *
Response Details
Status Code Description Response Headers
204 Detach and delete network interface was accepted. -
200 Setting Image share successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse removeNetworkFromServerWithHttpInfo( + public ApiResponse setImageShareWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID networkId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload) throws ApiException { okhttp3.Call localVarCall = - removeNetworkFromServerValidateBeforeCall(projectId, serverId, networkId, null); - return localVarApiClient.execute(localVarCall); + setImageShareValidateBeforeCall( + projectId, region, imageId, setImageSharePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Detach and delete all network interfaces associated with the specified network. - * (asynchronously) Detach and delete all network interfaces associated with the specified - * network from the server. + * Set image share. (asynchronously) Set share of an Image. New Options will replace existing + * settings. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param setImageSharePayload Settings for an Image Share. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -18987,7 +25146,7 @@ public ApiResponse removeNetworkFromServerWithHttpInfo( * * * - * + * * * * @@ -18995,26 +25154,28 @@ public ApiResponse removeNetworkFromServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Detach and delete network interface was accepted. -
200 Setting Image share successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeNetworkFromServerAsync( + public okhttp3.Call setImageShareAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID networkId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - removeNetworkFromServerValidateBeforeCall( - projectId, serverId, networkId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + setImageShareValidateBeforeCall( + projectId, region, imageId, setImageSharePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for removeNicFromServer + * Build call for startServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param nicId The identifier (ID) of a network interface. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19022,18 +25183,19 @@ public okhttp3.Call removeNetworkFromServerAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
204 Network interface detachment request was accepted. -
202 Server start request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeNicFromServerCall( + public okhttp3.Call startServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -19053,16 +25215,16 @@ public okhttp3.Call removeNicFromServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/nics/{nicId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/start" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "nicId" + "}", - localVarApiClient.escapeString(nicId.toString())); + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -19087,7 +25249,7 @@ public okhttp3.Call removeNicFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19099,67 +25261,68 @@ public okhttp3.Call removeNicFromServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call removeNicFromServerValidateBeforeCall( + private okhttp3.Call startServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling removeNicFromServer(Async)"); + "Missing the required parameter 'projectId' when calling startServer(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling removeNicFromServer(Async)"); + "Missing the required parameter 'region' when calling startServer(Async)"); } - // verify the required parameter 'nicId' is set - if (nicId == null) { + // verify the required parameter 'serverId' is set + if (serverId == null) { throw new ApiException( - "Missing the required parameter 'nicId' when calling removeNicFromServer(Async)"); + "Missing the required parameter 'serverId' when calling startServer(Async)"); } - return removeNicFromServerCall(projectId, serverId, nicId, _callback); + return startServerCall(projectId, region, serverId, _callback); } /** - * Detach a network interface. Detach a network interface from a server. + * Boot up a server. Start an existing server or allocates the server if deallocated. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param nicId The identifier (ID) of a network interface. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
204 Network interface detachment request was accepted. -
202 Server start request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void removeNicFromServer( + public void startServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID nicId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - removeNicFromServerWithHttpInfo(projectId, serverId, nicId); + startServerWithHttpInfo(projectId, region, serverId); } /** - * Detach a network interface. Detach a network interface from a server. + * Boot up a server. Start an existing server or allocates the server if deallocated. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param nicId The identifier (ID) of a network interface. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -19167,30 +25330,32 @@ public void removeNicFromServer( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
204 Network interface detachment request was accepted. -
202 Server start request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse removeNicFromServerWithHttpInfo( + public ApiResponse startServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID nicId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { okhttp3.Call localVarCall = - removeNicFromServerValidateBeforeCall(projectId, serverId, nicId, null); + startServerValidateBeforeCall(projectId, region, serverId, null); return localVarApiClient.execute(localVarCall); } /** - * Detach a network interface. (asynchronously) Detach a network interface from a server. + * Boot up a server. (asynchronously) Start an existing server or allocates the server if + * deallocated. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param nicId The identifier (ID) of a network interface. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -19199,33 +25364,34 @@ public ApiResponse removeNicFromServerWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
204 Network interface detachment request was accepted. -
202 Server start request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeNicFromServerAsync( + public okhttp3.Call startServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID nicId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - removeNicFromServerValidateBeforeCall(projectId, serverId, nicId, _callback); + startServerValidateBeforeCall(projectId, region, serverId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for removePublicIpFromServer + * Build call for stopServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19233,19 +25399,19 @@ public okhttp3.Call removeNicFromServerAsync( * * * - * + * * * * - * + * * * *
Response Details
Status Code Description Response Headers
204 Detach Public IP from server was accepted. -
202 Server stop request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The server or public IP was not found. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removePublicIpFromServerCall( + public okhttp3.Call stopServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -19265,16 +25431,16 @@ public okhttp3.Call removePublicIpFromServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/public-ips/{publicIpId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/stop" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "publicIpId" + "}", - localVarApiClient.escapeString(publicIpId.toString())); + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -19299,7 +25465,7 @@ public okhttp3.Call removePublicIpFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19311,68 +25477,72 @@ public okhttp3.Call removePublicIpFromServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call removePublicIpFromServerValidateBeforeCall( + private okhttp3.Call stopServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling removePublicIpFromServer(Async)"); + "Missing the required parameter 'projectId' when calling stopServer(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling removePublicIpFromServer(Async)"); + "Missing the required parameter 'region' when calling stopServer(Async)"); } - // verify the required parameter 'publicIpId' is set - if (publicIpId == null) { + // verify the required parameter 'serverId' is set + if (serverId == null) { throw new ApiException( - "Missing the required parameter 'publicIpId' when calling removePublicIpFromServer(Async)"); + "Missing the required parameter 'serverId' when calling stopServer(Async)"); } - return removePublicIpFromServerCall(projectId, serverId, publicIpId, _callback); + return stopServerCall(projectId, region, serverId, _callback); } /** - * Dissociate a public IP from a server. Dissociate a public IP on an existing server. + * Stop an existing server. Stops an existing server. The server will remain on the Hypervisor + * and will be charged full price for all resources attached to it. The attached resources will + * remain reserved. Useful particularly for vGPU servers. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * - * + * * * *
Response Details
Status Code Description Response Headers
204 Detach Public IP from server was accepted. -
202 Server stop request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The server or public IP was not found. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void removePublicIpFromServer( + public void stopServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID publicIpId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - removePublicIpFromServerWithHttpInfo(projectId, serverId, publicIpId); + stopServerWithHttpInfo(projectId, region, serverId); } /** - * Dissociate a public IP from a server. Dissociate a public IP on an existing server. + * Stop an existing server. Stops an existing server. The server will remain on the Hypervisor + * and will be charged full price for all resources attached to it. The attached resources will + * remain reserved. Useful particularly for vGPU servers. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -19380,32 +25550,32 @@ public void removePublicIpFromServer( * * * - * + * * * * - * + * * * *
Response Details
Status Code Description Response Headers
204 Detach Public IP from server was accepted. -
202 Server stop request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The server or public IP was not found. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse removePublicIpFromServerWithHttpInfo( + public ApiResponse stopServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID publicIpId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - okhttp3.Call localVarCall = - removePublicIpFromServerValidateBeforeCall(projectId, serverId, publicIpId, null); + okhttp3.Call localVarCall = stopServerValidateBeforeCall(projectId, region, serverId, null); return localVarApiClient.execute(localVarCall); } /** - * Dissociate a public IP from a server. (asynchronously) Dissociate a public IP on an existing - * server. + * Stop an existing server. (asynchronously) Stops an existing server. The server will remain on + * the Hypervisor and will be charged full price for all resources attached to it. The attached + * resources will remain reserved. Useful particularly for vGPU servers. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -19414,35 +25584,34 @@ public ApiResponse removePublicIpFromServerWithHttpInfo( * * * - * + * * * * - * + * * * *
Response Details
Status Code Description Response Headers
204 Detach Public IP from server was accepted. -
202 Server stop request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The server or public IP was not found. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removePublicIpFromServerAsync( + public okhttp3.Call stopServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID publicIpId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - removePublicIpFromServerValidateBeforeCall( - projectId, serverId, publicIpId, _callback); + stopServerValidateBeforeCall(projectId, region, serverId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for removeSecurityGroupFromServer + * Build call for unrescueServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19450,7 +25619,7 @@ public okhttp3.Call removePublicIpFromServerAsync( * * * - * + * * * * @@ -19459,10 +25628,10 @@ public okhttp3.Call removePublicIpFromServerAsync( * *
Response Details
Status Code Description Response Headers
204 Security group detachment request was accepted. -
202 Server unrescue request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeSecurityGroupFromServerCall( + public okhttp3.Call unrescueServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -19482,16 +25651,16 @@ public okhttp3.Call removeSecurityGroupFromServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/security-groups/{securityGroupId}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/unrescue" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())); + "{" + "serverId" + "}", + localVarApiClient.escapeString(serverId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -19516,7 +25685,7 @@ public okhttp3.Call removeSecurityGroupFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19528,46 +25697,47 @@ public okhttp3.Call removeSecurityGroupFromServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call removeSecurityGroupFromServerValidateBeforeCall( + private okhttp3.Call unrescueServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling removeSecurityGroupFromServer(Async)"); + "Missing the required parameter 'projectId' when calling unrescueServer(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling removeSecurityGroupFromServer(Async)"); + "Missing the required parameter 'region' when calling unrescueServer(Async)"); } - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { + // verify the required parameter 'serverId' is set + if (serverId == null) { throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling removeSecurityGroupFromServer(Async)"); + "Missing the required parameter 'serverId' when calling unrescueServer(Async)"); } - return removeSecurityGroupFromServerCall(projectId, serverId, securityGroupId, _callback); + return unrescueServerCall(projectId, region, serverId, _callback); } /** - * Remove a server from a security group. Remove a server from a attached security group. + * Unrescue an existing server. Unrescue an existing server. The original boot volume is + * attached as boot volume of the server and the server is booted up. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -19576,20 +25746,21 @@ private okhttp3.Call removeSecurityGroupFromServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
204 Security group detachment request was accepted. -
202 Server unrescue request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void removeSecurityGroupFromServer( + public void unrescueServer( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { - removeSecurityGroupFromServerWithHttpInfo(projectId, serverId, securityGroupId); + unrescueServerWithHttpInfo(projectId, region, serverId); } /** - * Remove a server from a security group. Remove a server from a attached security group. + * Unrescue an existing server. Unrescue an existing server. The original boot volume is + * attached as boot volume of the server and the server is booted up. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body @@ -19597,7 +25768,7 @@ public void removeSecurityGroupFromServer( * * * - * + * * * * @@ -19606,24 +25777,23 @@ public void removeSecurityGroupFromServer( * *
Response Details
Status Code Description Response Headers
204 Security group detachment request was accepted. -
202 Server unrescue request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse removeSecurityGroupFromServerWithHttpInfo( + public ApiResponse unrescueServerWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId) throws ApiException { okhttp3.Call localVarCall = - removeSecurityGroupFromServerValidateBeforeCall( - projectId, serverId, securityGroupId, null); + unrescueServerValidateBeforeCall(projectId, region, serverId, null); return localVarApiClient.execute(localVarCall); } /** - * Remove a server from a security group. (asynchronously) Remove a server from a attached - * security group. + * Unrescue an existing server. (asynchronously) Unrescue an existing server. The original boot + * volume is attached as boot volume of the server and the server is booted up. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -19632,7 +25802,7 @@ public ApiResponse removeSecurityGroupFromServerWithHttpInfo( * * * - * + * * * * @@ -19641,26 +25811,27 @@ public ApiResponse removeSecurityGroupFromServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
204 Security group detachment request was accepted. -
202 Server unrescue request accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeSecurityGroupFromServerAsync( + public okhttp3.Call unrescueServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID securityGroupId, final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - removeSecurityGroupFromServerValidateBeforeCall( - projectId, serverId, securityGroupId, _callback); + unrescueServerValidateBeforeCall(projectId, region, serverId, _callback); localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for removeServiceAccountFromServer + * Build call for updateAttachedVolume * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param serviceAccountMail The e-mail address of a service account. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param updateAttachedVolumePayload Request a volume attachment update. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19668,19 +25839,20 @@ public okhttp3.Call removeSecurityGroupFromServerAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Service account detached from the server. -
200 Response to update call. Provide the updated volume attachment object. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeServiceAccountFromServerCall( + public okhttp3.Call updateAttachedVolumeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -19696,20 +25868,23 @@ public okhttp3.Call removeServiceAccountFromServerCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = updateAttachedVolumePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/service-accounts/{serviceAccountMail}" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}/volume-attachments/{volumeId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", localVarApiClient.escapeString(serverId.toString())) .replace( - "{" + "serviceAccountMail" + "}", - localVarApiClient.escapeString(serviceAccountMail.toString())); + "{" + "volumeId" + "}", + localVarApiClient.escapeString(volumeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -19723,7 +25898,7 @@ public okhttp3.Call removeServiceAccountFromServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -19734,7 +25909,7 @@ public okhttp3.Call removeServiceAccountFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19746,107 +25921,130 @@ public okhttp3.Call removeServiceAccountFromServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call removeServiceAccountFromServerValidateBeforeCall( + private okhttp3.Call updateAttachedVolumeValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail, + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling removeServiceAccountFromServer(Async)"); + "Missing the required parameter 'projectId' when calling updateAttachedVolume(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling updateAttachedVolume(Async)"); } // verify the required parameter 'serverId' is set if (serverId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling removeServiceAccountFromServer(Async)"); + "Missing the required parameter 'serverId' when calling updateAttachedVolume(Async)"); } - // verify the required parameter 'serviceAccountMail' is set - if (serviceAccountMail == null) { + // verify the required parameter 'volumeId' is set + if (volumeId == null) { throw new ApiException( - "Missing the required parameter 'serviceAccountMail' when calling removeServiceAccountFromServer(Async)"); + "Missing the required parameter 'volumeId' when calling updateAttachedVolume(Async)"); } - return removeServiceAccountFromServerCall( - projectId, serverId, serviceAccountMail, _callback); + // verify the required parameter 'updateAttachedVolumePayload' is set + if (updateAttachedVolumePayload == null) { + throw new ApiException( + "Missing the required parameter 'updateAttachedVolumePayload' when calling updateAttachedVolume(Async)"); + } + + return updateAttachedVolumeCall( + projectId, region, serverId, volumeId, updateAttachedVolumePayload, _callback); } /** - * Detach a service account from a server. Detach an additional service account from the server. + * Update Volume Attachment Parameters. Update the properties of an existing Volume Attachment. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param serviceAccountMail The e-mail address of a service account. (required) - * @return ServiceAccountMailListResponse + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param updateAttachedVolumePayload Request a volume attachment update. (required) + * @return VolumeAttachment * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Service account detached from the server. -
200 Response to update call. Provide the updated volume attachment object. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ServiceAccountMailListResponse removeServiceAccountFromServer( + public VolumeAttachment updateAttachedVolume( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail) + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload) throws ApiException { - ApiResponse localVarResp = - removeServiceAccountFromServerWithHttpInfo(projectId, serverId, serviceAccountMail); + ApiResponse localVarResp = + updateAttachedVolumeWithHttpInfo( + projectId, region, serverId, volumeId, updateAttachedVolumePayload); return localVarResp.getData(); } /** - * Detach a service account from a server. Detach an additional service account from the server. + * Update Volume Attachment Parameters. Update the properties of an existing Volume Attachment. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param serviceAccountMail The e-mail address of a service account. (required) - * @return ApiResponse<ServiceAccountMailListResponse> + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param updateAttachedVolumePayload Request a volume attachment update. (required) + * @return ApiResponse<VolumeAttachment> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Service account detached from the server. -
200 Response to update call. Provide the updated volume attachment object. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse removeServiceAccountFromServerWithHttpInfo( + public ApiResponse updateAttachedVolumeWithHttpInfo( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail) + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload) throws ApiException { okhttp3.Call localVarCall = - removeServiceAccountFromServerValidateBeforeCall( - projectId, serverId, serviceAccountMail, null); - Type localVarReturnType = new TypeToken() {}.getType(); + updateAttachedVolumeValidateBeforeCall( + projectId, region, serverId, volumeId, updateAttachedVolumePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Detach a service account from a server. (asynchronously) Detach an additional service account - * from the server. + * Update Volume Attachment Parameters. (asynchronously) Update the properties of an existing + * Volume Attachment. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param serviceAccountMail The e-mail address of a service account. (required) + * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param updateAttachedVolumePayload Request a volume attachment update. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -19855,36 +26053,43 @@ public ApiResponse removeServiceAccountFromServe * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Service account detached from the server. -
200 Response to update call. Provide the updated volume attachment object. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeServiceAccountFromServerAsync( + public okhttp3.Call updateAttachedVolumeAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull String serviceAccountMail, - final ApiCallback _callback) + @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - removeServiceAccountFromServerValidateBeforeCall( - projectId, serverId, serviceAccountMail, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + updateAttachedVolumeValidateBeforeCall( + projectId, + region, + serverId, + volumeId, + updateAttachedVolumePayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for removeVolumeFromServer + * Build call for updateImage * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param updateImagePayload Request an update of an Image. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -19892,19 +26097,19 @@ public okhttp3.Call removeServiceAccountFromServerAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Volume detachment request was accepted. -
200 Response to update call. Provide the updated image object. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeVolumeFromServerCall( + public okhttp3.Call updateImageCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImagePayload updateImagePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -19920,20 +26125,20 @@ public okhttp3.Call removeVolumeFromServerCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = updateImagePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/volume-attachments/{volumeId}" + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( - "{" + "volumeId" + "}", - localVarApiClient.escapeString(volumeId.toString())); + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -19947,7 +26152,7 @@ public okhttp3.Call removeVolumeFromServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -19958,7 +26163,7 @@ public okhttp3.Call removeVolumeFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19970,101 +26175,115 @@ public okhttp3.Call removeVolumeFromServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call removeVolumeFromServerValidateBeforeCall( + private okhttp3.Call updateImageValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImagePayload updateImagePayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling removeVolumeFromServer(Async)"); + "Missing the required parameter 'projectId' when calling updateImage(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling removeVolumeFromServer(Async)"); + "Missing the required parameter 'region' when calling updateImage(Async)"); } - // verify the required parameter 'volumeId' is set - if (volumeId == null) { + // verify the required parameter 'imageId' is set + if (imageId == null) { throw new ApiException( - "Missing the required parameter 'volumeId' when calling removeVolumeFromServer(Async)"); + "Missing the required parameter 'imageId' when calling updateImage(Async)"); + } + + // verify the required parameter 'updateImagePayload' is set + if (updateImagePayload == null) { + throw new ApiException( + "Missing the required parameter 'updateImagePayload' when calling updateImage(Async)"); } - return removeVolumeFromServerCall(projectId, serverId, volumeId, _callback); + return updateImageCall(projectId, region, imageId, updateImagePayload, _callback); } /** - * Detach a volume from a server. Detach an existing volume from an existing server. + * Update Image Parameters. Update the properties of an existing Image inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param updateImagePayload Request an update of an Image. (required) + * @return Image * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Volume detachment request was accepted. -
200 Response to update call. Provide the updated image object. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void removeVolumeFromServer( + public Image updateImage( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImagePayload updateImagePayload) throws ApiException { - removeVolumeFromServerWithHttpInfo(projectId, serverId, volumeId); + ApiResponse localVarResp = + updateImageWithHttpInfo(projectId, region, imageId, updateImagePayload); + return localVarResp.getData(); } /** - * Detach a volume from a server. Detach an existing volume from an existing server. + * Update Image Parameters. Update the properties of an existing Image inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param updateImagePayload Request an update of an Image. (required) + * @return ApiResponse<Image> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Volume detachment request was accepted. -
200 Response to update call. Provide the updated image object. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse removeVolumeFromServerWithHttpInfo( + public ApiResponse updateImageWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImagePayload updateImagePayload) throws ApiException { okhttp3.Call localVarCall = - removeVolumeFromServerValidateBeforeCall(projectId, serverId, volumeId, null); - return localVarApiClient.execute(localVarCall); + updateImageValidateBeforeCall(projectId, region, imageId, updateImagePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Detach a volume from a server. (asynchronously) Detach an existing volume from an existing - * server. + * Update Image Parameters. (asynchronously) Update the properties of an existing Image inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param updateImagePayload Request an update of an Image. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -20073,34 +26292,37 @@ public ApiResponse removeVolumeFromServerWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
204 Volume detachment request was accepted. -
200 Response to update call. Provide the updated image object. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call removeVolumeFromServerAsync( + public okhttp3.Call updateImageAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UUID volumeId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImagePayload updateImagePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - removeVolumeFromServerValidateBeforeCall(projectId, serverId, volumeId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + updateImageValidateBeforeCall( + projectId, region, imageId, updateImagePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for rescueServer + * Build call for updateImageShare * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param rescueServerPayload Request a server rescue. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param updateImageSharePayload Update an Image Share. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -20108,19 +26330,19 @@ public okhttp3.Call removeVolumeFromServerAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server rescue request accepted. -
200 Updating Image share successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call rescueServerCall( + public okhttp3.Call updateImageShareCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull RescueServerPayload rescueServerPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -20136,17 +26358,20 @@ public okhttp3.Call rescueServerCall( basePath = null; } - Object localVarPostBody = rescueServerPayload; + Object localVarPostBody = updateImageSharePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/rescue" + "/v2beta1/projects/{projectId}/regions/{region}/images/{imageId}/share" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "imageId" + "}", + localVarApiClient.escapeString(imageId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -20171,7 +26396,7 @@ public okhttp3.Call rescueServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20183,106 +26408,116 @@ public okhttp3.Call rescueServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call rescueServerValidateBeforeCall( + private okhttp3.Call updateImageShareValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull RescueServerPayload rescueServerPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling rescueServer(Async)"); + "Missing the required parameter 'projectId' when calling updateImageShare(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling rescueServer(Async)"); + "Missing the required parameter 'region' when calling updateImageShare(Async)"); } - // verify the required parameter 'rescueServerPayload' is set - if (rescueServerPayload == null) { + // verify the required parameter 'imageId' is set + if (imageId == null) { throw new ApiException( - "Missing the required parameter 'rescueServerPayload' when calling rescueServer(Async)"); + "Missing the required parameter 'imageId' when calling updateImageShare(Async)"); + } + + // verify the required parameter 'updateImageSharePayload' is set + if (updateImageSharePayload == null) { + throw new ApiException( + "Missing the required parameter 'updateImageSharePayload' when calling updateImageShare(Async)"); } - return rescueServerCall(projectId, serverId, rescueServerPayload, _callback); + return updateImageShareCall(projectId, region, imageId, updateImageSharePayload, _callback); } /** - * Rescue an existing server. Rescue an existing server. It is shutdown and the initial image is - * attached as the boot volume, while the boot volume is attached as secondary volume and the - * server is booted. + * Update image share. Update share of an Image. Projects will be appended to existing list. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param rescueServerPayload Request a server rescue. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param updateImageSharePayload Update an Image Share. (required) + * @return ImageShare * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server rescue request accepted. -
200 Updating Image share successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void rescueServer( + public ImageShare updateImageShare( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull RescueServerPayload rescueServerPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload) throws ApiException { - rescueServerWithHttpInfo(projectId, serverId, rescueServerPayload); + ApiResponse localVarResp = + updateImageShareWithHttpInfo(projectId, region, imageId, updateImageSharePayload); + return localVarResp.getData(); } /** - * Rescue an existing server. Rescue an existing server. It is shutdown and the initial image is - * attached as the boot volume, while the boot volume is attached as secondary volume and the - * server is booted. + * Update image share. Update share of an Image. Projects will be appended to existing list. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param rescueServerPayload Request a server rescue. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param updateImageSharePayload Update an Image Share. (required) + * @return ApiResponse<ImageShare> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server rescue request accepted. -
200 Updating Image share successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse rescueServerWithHttpInfo( + public ApiResponse updateImageShareWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull RescueServerPayload rescueServerPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload) throws ApiException { okhttp3.Call localVarCall = - rescueServerValidateBeforeCall(projectId, serverId, rescueServerPayload, null); - return localVarApiClient.execute(localVarCall); + updateImageShareValidateBeforeCall( + projectId, region, imageId, updateImageSharePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Rescue an existing server. (asynchronously) Rescue an existing server. It is shutdown and the - * initial image is attached as the boot volume, while the boot volume is attached as secondary - * volume and the server is booted. + * Update image share. (asynchronously) Update share of an Image. Projects will be appended to + * existing list. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param rescueServerPayload Request a server rescue. (required) + * @param region The STACKIT Region of the resources. (required) + * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param updateImageSharePayload Update an Image Share. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -20291,34 +26526,35 @@ public ApiResponse rescueServerWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server rescue request accepted. -
200 Updating Image share successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call rescueServerAsync( + public okhttp3.Call updateImageShareAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull RescueServerPayload rescueServerPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - rescueServerValidateBeforeCall(projectId, serverId, rescueServerPayload, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + updateImageShareValidateBeforeCall( + projectId, region, imageId, updateImageSharePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for resizeServer + * Build call for updateKeyPair * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param resizeServerPayload Request a resize of a server. (required) + * @param keypairName The name of an SSH keypair. (required) + * @param updateKeyPairPayload Request an update of an SSH keypair. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -20326,19 +26562,17 @@ public okhttp3.Call rescueServerAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server resize request is accepted. -
200 SSH keypair has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call resizeServerCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload, + public okhttp3.Call updateKeyPairCall( + @javax.annotation.Nonnull String keypairName, + @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -20354,17 +26588,14 @@ public okhttp3.Call resizeServerCall( basePath = null; } - Object localVarPostBody = resizeServerPayload; + Object localVarPostBody = updateKeyPairPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/resize" - .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "/v2beta1/keypairs/{keypairName}" .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "keypairName" + "}", + localVarApiClient.escapeString(keypairName.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -20389,7 +26620,7 @@ public okhttp3.Call resizeServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20401,100 +26632,90 @@ public okhttp3.Call resizeServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call resizeServerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload, + private okhttp3.Call updateKeyPairValidateBeforeCall( + @javax.annotation.Nonnull String keypairName, + @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { - throw new ApiException( - "Missing the required parameter 'projectId' when calling resizeServer(Async)"); - } - - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'keypairName' is set + if (keypairName == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling resizeServer(Async)"); + "Missing the required parameter 'keypairName' when calling updateKeyPair(Async)"); } - // verify the required parameter 'resizeServerPayload' is set - if (resizeServerPayload == null) { + // verify the required parameter 'updateKeyPairPayload' is set + if (updateKeyPairPayload == null) { throw new ApiException( - "Missing the required parameter 'resizeServerPayload' when calling resizeServer(Async)"); + "Missing the required parameter 'updateKeyPairPayload' when calling updateKeyPair(Async)"); } - return resizeServerCall(projectId, serverId, resizeServerPayload, _callback); + return updateKeyPairCall(keypairName, updateKeyPairPayload, _callback); } /** - * Resize a server. Resize the server to the given machine type. + * Update information of an SSH keypair. Update labels of the SSH keypair. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param resizeServerPayload Request a resize of a server. (required) + * @param keypairName The name of an SSH keypair. (required) + * @param updateKeyPairPayload Request an update of an SSH keypair. (required) + * @return Keypair * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server resize request is accepted. -
200 SSH keypair has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void resizeServer( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload) + public Keypair updateKeyPair( + @javax.annotation.Nonnull String keypairName, + @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload) throws ApiException { - resizeServerWithHttpInfo(projectId, serverId, resizeServerPayload); + ApiResponse localVarResp = + updateKeyPairWithHttpInfo(keypairName, updateKeyPairPayload); + return localVarResp.getData(); } /** - * Resize a server. Resize the server to the given machine type. + * Update information of an SSH keypair. Update labels of the SSH keypair. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param resizeServerPayload Request a resize of a server. (required) - * @return ApiResponse<Void> + * @param keypairName The name of an SSH keypair. (required) + * @param updateKeyPairPayload Request an update of an SSH keypair. (required) + * @return ApiResponse<Keypair> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server resize request is accepted. -
200 SSH keypair has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse resizeServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload) + public ApiResponse updateKeyPairWithHttpInfo( + @javax.annotation.Nonnull String keypairName, + @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload) throws ApiException { okhttp3.Call localVarCall = - resizeServerValidateBeforeCall(projectId, serverId, resizeServerPayload, null); - return localVarApiClient.execute(localVarCall); + updateKeyPairValidateBeforeCall(keypairName, updateKeyPairPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Resize a server. (asynchronously) Resize the server to the given machine type. + * Update information of an SSH keypair. (asynchronously) Update labels of the SSH keypair. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param resizeServerPayload Request a resize of a server. (required) + * @param keypairName The name of an SSH keypair. (required) + * @param updateKeyPairPayload Request an update of an SSH keypair. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -20503,34 +26724,35 @@ public ApiResponse resizeServerWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server resize request is accepted. -
200 SSH keypair has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call resizeServerAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload, - final ApiCallback _callback) + public okhttp3.Call updateKeyPairAsync( + @javax.annotation.Nonnull String keypairName, + @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - resizeServerValidateBeforeCall(projectId, serverId, resizeServerPayload, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + updateKeyPairValidateBeforeCall(keypairName, updateKeyPairPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for resizeVolume + * Build call for updateManagementNetworkRoute * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param resizeVolumePayload Request a volume resize. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param updateManagementNetworkRoutePayload Request an update of a management network route. + * (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -20538,19 +26760,20 @@ public okhttp3.Call resizeServerAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Volume resize request accepted. -
200 Update request for management network route successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call resizeVolumeCall( + public okhttp3.Call updateManagementNetworkRouteCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateManagementNetworkRoutePayload updateManagementNetworkRoutePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -20566,17 +26789,20 @@ public okhttp3.Call resizeVolumeCall( basePath = null; } - Object localVarPostBody = resizeVolumePayload; + Object localVarPostBody = updateManagementNetworkRoutePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes/{volumeId}/resize" + "/v2beta1/projects/{projectId}/regions/{region}/management-network/routes/{routeId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "volumeId" + "}", - localVarApiClient.escapeString(volumeId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -20601,7 +26827,7 @@ public okhttp3.Call resizeVolumeCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20613,97 +26839,124 @@ public okhttp3.Call resizeVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call resizeVolumeValidateBeforeCall( + private okhttp3.Call updateManagementNetworkRouteValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateManagementNetworkRoutePayload updateManagementNetworkRoutePayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling resizeVolume(Async)"); + "Missing the required parameter 'projectId' when calling updateManagementNetworkRoute(Async)"); } - // verify the required parameter 'volumeId' is set - if (volumeId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'volumeId' when calling resizeVolume(Async)"); + "Missing the required parameter 'region' when calling updateManagementNetworkRoute(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { + throw new ApiException( + "Missing the required parameter 'routeId' when calling updateManagementNetworkRoute(Async)"); + } + + // verify the required parameter 'updateManagementNetworkRoutePayload' is set + if (updateManagementNetworkRoutePayload == null) { + throw new ApiException( + "Missing the required parameter 'updateManagementNetworkRoutePayload' when calling updateManagementNetworkRoute(Async)"); } - return resizeVolumeCall(projectId, volumeId, resizeVolumePayload, _callback); + return updateManagementNetworkRouteCall( + projectId, region, routeId, updateManagementNetworkRoutePayload, _callback); } /** - * Update the size of a volume. Update the size of a block device volume. The new volume size - * must be larger than the current size. + * Update a management network route labels. Update the labels of a management network route. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param resizeVolumePayload Request a volume resize. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param updateManagementNetworkRoutePayload Request an update of a management network route. + * (required) + * @return ManagementRoute * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Volume resize request accepted. -
200 Update request for management network route successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void resizeVolume( + public ManagementRoute updateManagementNetworkRoute( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateManagementNetworkRoutePayload updateManagementNetworkRoutePayload) throws ApiException { - resizeVolumeWithHttpInfo(projectId, volumeId, resizeVolumePayload); + ApiResponse localVarResp = + updateManagementNetworkRouteWithHttpInfo( + projectId, region, routeId, updateManagementNetworkRoutePayload); + return localVarResp.getData(); } /** - * Update the size of a volume. Update the size of a block device volume. The new volume size - * must be larger than the current size. + * Update a management network route labels. Update the labels of a management network route. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param resizeVolumePayload Request a volume resize. (optional) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param updateManagementNetworkRoutePayload Request an update of a management network route. + * (required) + * @return ApiResponse<ManagementRoute> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Volume resize request accepted. -
200 Update request for management network route successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse resizeVolumeWithHttpInfo( + public ApiResponse updateManagementNetworkRouteWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateManagementNetworkRoutePayload updateManagementNetworkRoutePayload) throws ApiException { okhttp3.Call localVarCall = - resizeVolumeValidateBeforeCall(projectId, volumeId, resizeVolumePayload, null); - return localVarApiClient.execute(localVarCall); + updateManagementNetworkRouteValidateBeforeCall( + projectId, region, routeId, updateManagementNetworkRoutePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update the size of a volume. (asynchronously) Update the size of a block device volume. The - * new volume size must be larger than the current size. + * Update a management network route labels. (asynchronously) Update the labels of a management + * network route. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param resizeVolumePayload Request a volume resize. (optional) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param updateManagementNetworkRoutePayload Request an update of a management network route. + * (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -20712,33 +26965,39 @@ public ApiResponse resizeVolumeWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Volume resize request accepted. -
200 Update request for management network route successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call resizeVolumeAsync( + public okhttp3.Call updateManagementNetworkRouteAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nullable ResizeVolumePayload resizeVolumePayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateManagementNetworkRoutePayload updateManagementNetworkRoutePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - resizeVolumeValidateBeforeCall(projectId, volumeId, resizeVolumePayload, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + updateManagementNetworkRouteValidateBeforeCall( + projectId, region, routeId, updateManagementNetworkRoutePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for restoreBackup + * Build call for updateNic * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @param updateNicPayload Request an update of a network interface. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -20746,17 +27005,21 @@ public okhttp3.Call resizeVolumeAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
202 Backup restore request has been accepted. -
200 Network interface has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call restoreBackupCall( + public okhttp3.Call updateNicCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull UpdateNicPayload updateNicPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -20772,17 +27035,23 @@ public okhttp3.Call restoreBackupCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = updateNicPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups/{backupId}/restore" + "/v2beta1/projects/{projectId}/regions/{region}/networks/{networkId}/nics/{nicId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "backupId" + "}", - localVarApiClient.escapeString(backupId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "networkId" + "}", + localVarApiClient.escapeString(networkId.toString())) + .replace( + "{" + "nicId" + "}", + localVarApiClient.escapeString(nicId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -20796,7 +27065,7 @@ public okhttp3.Call restoreBackupCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -20807,7 +27076,7 @@ public okhttp3.Call restoreBackupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20819,90 +27088,132 @@ public okhttp3.Call restoreBackupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call restoreBackupValidateBeforeCall( + private okhttp3.Call updateNicValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull UpdateNicPayload updateNicPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling restoreBackup(Async)"); + "Missing the required parameter 'projectId' when calling updateNic(Async)"); } - // verify the required parameter 'backupId' is set - if (backupId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'backupId' when calling restoreBackup(Async)"); + "Missing the required parameter 'region' when calling updateNic(Async)"); + } + + // verify the required parameter 'networkId' is set + if (networkId == null) { + throw new ApiException( + "Missing the required parameter 'networkId' when calling updateNic(Async)"); + } + + // verify the required parameter 'nicId' is set + if (nicId == null) { + throw new ApiException( + "Missing the required parameter 'nicId' when calling updateNic(Async)"); + } + + // verify the required parameter 'updateNicPayload' is set + if (updateNicPayload == null) { + throw new ApiException( + "Missing the required parameter 'updateNicPayload' when calling updateNic(Async)"); } - return restoreBackupCall(projectId, backupId, _callback); + return updateNicCall(projectId, region, networkId, nicId, updateNicPayload, _callback); } /** - * Restore Backup to the referenced source Volume. Restores a Backup to the existing Volume it - * references to. The use of this endpoint is disruptive as the volume needs to be detached. If - * a new volume is to be created use the volumes endpoint with the option to create from backup. + * Update a network interface. Update the properties of an existing network interface inside a + * network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @param updateNicPayload Request an update of a network interface. (required) + * @return NIC * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
202 Backup restore request has been accepted. -
200 Network interface has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void restoreBackup( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID backupId) + public NIC updateNic( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull UpdateNicPayload updateNicPayload) throws ApiException { - restoreBackupWithHttpInfo(projectId, backupId); + ApiResponse localVarResp = + updateNicWithHttpInfo(projectId, region, networkId, nicId, updateNicPayload); + return localVarResp.getData(); } /** - * Restore Backup to the referenced source Volume. Restores a Backup to the existing Volume it - * references to. The use of this endpoint is disruptive as the volume needs to be detached. If - * a new volume is to be created use the volumes endpoint with the option to create from backup. + * Update a network interface. Update the properties of an existing network interface inside a + * network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @return ApiResponse<Void> + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @param updateNicPayload Request an update of a network interface. (required) + * @return ApiResponse<NIC> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
202 Backup restore request has been accepted. -
200 Network interface has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse restoreBackupWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID backupId) + public ApiResponse updateNicWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull UpdateNicPayload updateNicPayload) throws ApiException { - okhttp3.Call localVarCall = restoreBackupValidateBeforeCall(projectId, backupId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + updateNicValidateBeforeCall( + projectId, region, networkId, nicId, updateNicPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Restore Backup to the referenced source Volume. (asynchronously) Restores a Backup to the - * existing Volume it references to. The use of this endpoint is disruptive as the volume needs - * to be detached. If a new volume is to be created use the volumes endpoint with the option to - * create from backup. + * Update a network interface. (asynchronously) Update the properties of an existing network + * interface inside a network. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param region The STACKIT Region of the resources. (required) + * @param networkId The identifier (ID) of a STACKIT Network. (required) + * @param nicId The identifier (ID) of a network interface. (required) + * @param updateNicPayload Request an update of a network interface. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -20911,31 +27222,39 @@ public ApiResponse restoreBackupWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
202 Backup restore request has been accepted. -
200 Network interface has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call restoreBackupAsync( + public okhttp3.Call updateNicAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID networkId, + @javax.annotation.Nonnull UUID nicId, + @javax.annotation.Nonnull UpdateNicPayload updateNicPayload, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = restoreBackupValidateBeforeCall(projectId, backupId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + okhttp3.Call localVarCall = + updateNicValidateBeforeCall( + projectId, region, networkId, nicId, updateNicPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for setImageShare + * Build call for updatePublicIP * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param setImageSharePayload Settings for an Image Share. (required) + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param updatePublicIPPayload Request an update of a public IP. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -20943,7 +27262,7 @@ public okhttp3.Call restoreBackupAsync( * * * - * + * * * * @@ -20951,10 +27270,11 @@ public okhttp3.Call restoreBackupAsync( * *
Response Details
Status Code Description Response Headers
200 Setting Image share successful. -
200 Public IP has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call setImageShareCall( + public okhttp3.Call updatePublicIPCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -20970,17 +27290,20 @@ public okhttp3.Call setImageShareCall( basePath = null; } - Object localVarPostBody = setImageSharePayload; + Object localVarPostBody = updatePublicIPPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share" + "/v2beta1/projects/{projectId}/regions/{region}/public-ips/{publicIpId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "publicIpId" + "}", + localVarApiClient.escapeString(publicIpId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -21005,7 +27328,7 @@ public okhttp3.Call setImageShareCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PUT", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -21017,47 +27340,55 @@ public okhttp3.Call setImageShareCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call setImageShareValidateBeforeCall( + private okhttp3.Call updatePublicIPValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling setImageShare(Async)"); + "Missing the required parameter 'projectId' when calling updatePublicIP(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling setImageShare(Async)"); + "Missing the required parameter 'region' when calling updatePublicIP(Async)"); } - // verify the required parameter 'setImageSharePayload' is set - if (setImageSharePayload == null) { + // verify the required parameter 'publicIpId' is set + if (publicIpId == null) { throw new ApiException( - "Missing the required parameter 'setImageSharePayload' when calling setImageShare(Async)"); + "Missing the required parameter 'publicIpId' when calling updatePublicIP(Async)"); + } + + // verify the required parameter 'updatePublicIPPayload' is set + if (updatePublicIPPayload == null) { + throw new ApiException( + "Missing the required parameter 'updatePublicIPPayload' when calling updatePublicIP(Async)"); } - return setImageShareCall(projectId, imageId, setImageSharePayload, _callback); + return updatePublicIPCall(projectId, region, publicIpId, updatePublicIPPayload, _callback); } /** - * Set image share. Set share of an Image. New Options will replace existing settings. + * Update a public IP. Update the properties of an existing public IP inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param setImageSharePayload Settings for an Image Share. (required) - * @return ImageShare + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param updatePublicIPPayload Request an update of a public IP. (required) + * @return PublicIp * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -21065,30 +27396,32 @@ private okhttp3.Call setImageShareValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Setting Image share successful. -
200 Public IP has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ImageShare setImageShare( + public PublicIp updatePublicIP( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload) throws ApiException { - ApiResponse localVarResp = - setImageShareWithHttpInfo(projectId, imageId, setImageSharePayload); + ApiResponse localVarResp = + updatePublicIPWithHttpInfo(projectId, region, publicIpId, updatePublicIPPayload); return localVarResp.getData(); } /** - * Set image share. Set share of an Image. New Options will replace existing settings. + * Update a public IP. Update the properties of an existing public IP inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param setImageSharePayload Settings for an Image Share. (required) - * @return ApiResponse<ImageShare> + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param updatePublicIPPayload Request an update of a public IP. (required) + * @return ApiResponse<PublicIp> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -21096,24 +27429,27 @@ public ImageShare setImageShare( * *
Response Details
Status Code Description Response Headers
200 Setting Image share successful. -
200 Public IP has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse setImageShareWithHttpInfo( + public ApiResponse updatePublicIPWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload) throws ApiException { okhttp3.Call localVarCall = - setImageShareValidateBeforeCall(projectId, imageId, setImageSharePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + updatePublicIPValidateBeforeCall( + projectId, region, publicIpId, updatePublicIPPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Set image share. (asynchronously) Set share of an Image. New Options will replace existing - * settings. + * Update a public IP. (asynchronously) Update the properties of an existing public IP inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param setImageSharePayload Settings for an Image Share. (required) + * @param region The STACKIT Region of the resources. (required) + * @param publicIpId The identifier (ID) of a Public IP. (required) + * @param updatePublicIPPayload Request an update of a public IP. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -21122,7 +27458,7 @@ public ApiResponse setImageShareWithHttpInfo( * * * - * + * * * * @@ -21130,26 +27466,32 @@ public ApiResponse setImageShareWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Setting Image share successful. -
200 Public IP has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call setImageShareAsync( + public okhttp3.Call updatePublicIPAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull SetImageSharePayload setImageSharePayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID publicIpId, + @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - setImageShareValidateBeforeCall( - projectId, imageId, setImageSharePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + updatePublicIPValidateBeforeCall( + projectId, region, publicIpId, updatePublicIPPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for startServer + * Build call for updateRouteOfRoutingTable * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param updateRouteOfRoutingTablePayload Request an update of a route in a routing table. + * (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -21157,18 +27499,22 @@ public okhttp3.Call setImageShareAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server start request accepted. -
200 Update request for route successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call startServerCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + public okhttp3.Call updateRouteOfRoutingTableCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateRouteOfRoutingTablePayload updateRouteOfRoutingTablePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -21184,17 +27530,26 @@ public okhttp3.Call startServerCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = updateRouteOfRoutingTablePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/start" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables/{routingTableId}/routes/{routeId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -21208,7 +27563,7 @@ public okhttp3.Call startServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -21219,7 +27574,7 @@ public okhttp3.Call startServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -21231,86 +27586,165 @@ public okhttp3.Call startServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call startServerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + private okhttp3.Call updateRouteOfRoutingTableValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateRouteOfRoutingTablePayload updateRouteOfRoutingTablePayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling startServer(Async)"); + "Missing the required parameter 'organizationId' when calling updateRouteOfRoutingTable(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling startServer(Async)"); + "Missing the required parameter 'areaId' when calling updateRouteOfRoutingTable(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling updateRouteOfRoutingTable(Async)"); + } + + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { + throw new ApiException( + "Missing the required parameter 'routingTableId' when calling updateRouteOfRoutingTable(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { + throw new ApiException( + "Missing the required parameter 'routeId' when calling updateRouteOfRoutingTable(Async)"); } - return startServerCall(projectId, serverId, _callback); + // verify the required parameter 'updateRouteOfRoutingTablePayload' is set + if (updateRouteOfRoutingTablePayload == null) { + throw new ApiException( + "Missing the required parameter 'updateRouteOfRoutingTablePayload' when calling updateRouteOfRoutingTable(Async)"); + } + + return updateRouteOfRoutingTableCall( + organizationId, + areaId, + region, + routingTableId, + routeId, + updateRouteOfRoutingTablePayload, + _callback); } /** - * Boot up a server. Start an existing server or allocates the server if deallocated. + * Update a route of a routing table. Update a route defined in a routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param updateRouteOfRoutingTablePayload Request an update of a route in a routing table. + * (required) + * @return Route * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server start request accepted. -
200 Update request for route successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void startServer( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public Route updateRouteOfRoutingTable( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateRouteOfRoutingTablePayload updateRouteOfRoutingTablePayload) throws ApiException { - startServerWithHttpInfo(projectId, serverId); + ApiResponse localVarResp = + updateRouteOfRoutingTableWithHttpInfo( + organizationId, + areaId, + region, + routingTableId, + routeId, + updateRouteOfRoutingTablePayload); + return localVarResp.getData(); } /** - * Boot up a server. Start an existing server or allocates the server if deallocated. + * Update a route of a routing table. Update a route defined in a routing table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ApiResponse<Void> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param updateRouteOfRoutingTablePayload Request an update of a route in a routing table. + * (required) + * @return ApiResponse<Route> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server start request accepted. -
200 Update request for route successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse startServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse updateRouteOfRoutingTableWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateRouteOfRoutingTablePayload updateRouteOfRoutingTablePayload) throws ApiException { - okhttp3.Call localVarCall = startServerValidateBeforeCall(projectId, serverId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + updateRouteOfRoutingTableValidateBeforeCall( + organizationId, + areaId, + region, + routingTableId, + routeId, + updateRouteOfRoutingTablePayload, + null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Boot up a server. (asynchronously) Start an existing server or allocates the server if - * deallocated. + * Update a route of a routing table. (asynchronously) Update a route defined in a routing + * table. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param updateRouteOfRoutingTablePayload Request an update of a route in a routing table. + * (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -21319,31 +27753,47 @@ public ApiResponse startServerWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server start request accepted. -
200 Update request for route successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call startServerAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) + public okhttp3.Call updateRouteOfRoutingTableAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + UpdateRouteOfRoutingTablePayload updateRouteOfRoutingTablePayload, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = startServerValidateBeforeCall(projectId, serverId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + okhttp3.Call localVarCall = + updateRouteOfRoutingTableValidateBeforeCall( + organizationId, + areaId, + region, + routingTableId, + routeId, + updateRouteOfRoutingTablePayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for stopServer + * Build call for updateRoutingTableOfArea * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param updateRoutingTableOfAreaPayload Request an update of a routing table. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -21351,18 +27801,21 @@ public okhttp3.Call startServerAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server stop request accepted. -
200 Update request for routing table successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call stopServerCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + public okhttp3.Call updateRoutingTableOfAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull + UpdateRoutingTableOfAreaPayload updateRoutingTableOfAreaPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -21378,17 +27831,23 @@ public okhttp3.Call stopServerCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = updateRoutingTableOfAreaPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/stop" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routing-tables/{routingTableId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -21402,7 +27861,7 @@ public okhttp3.Call stopServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -21413,7 +27872,7 @@ public okhttp3.Call stopServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -21424,92 +27883,147 @@ public okhttp3.Call stopServerCall( _callback); } - @SuppressWarnings("rawtypes") - private okhttp3.Call stopServerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) - throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + @SuppressWarnings("rawtypes") + private okhttp3.Call updateRoutingTableOfAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull + UpdateRoutingTableOfAreaPayload updateRoutingTableOfAreaPayload, + final ApiCallback _callback) + throws ApiException { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { + throw new ApiException( + "Missing the required parameter 'organizationId' when calling updateRoutingTableOfArea(Async)"); + } + + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling updateRoutingTableOfArea(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling stopServer(Async)"); + "Missing the required parameter 'region' when calling updateRoutingTableOfArea(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling stopServer(Async)"); + "Missing the required parameter 'routingTableId' when calling updateRoutingTableOfArea(Async)"); } - return stopServerCall(projectId, serverId, _callback); + // verify the required parameter 'updateRoutingTableOfAreaPayload' is set + if (updateRoutingTableOfAreaPayload == null) { + throw new ApiException( + "Missing the required parameter 'updateRoutingTableOfAreaPayload' when calling updateRoutingTableOfArea(Async)"); + } + + return updateRoutingTableOfAreaCall( + organizationId, + areaId, + region, + routingTableId, + updateRoutingTableOfAreaPayload, + _callback); } /** - * Stop an existing server. Stops an existing server. The server will remain on the Hypervisor - * and will be charged full price for all resources attached to it. The attached resources will - * remain reserved. Useful particularly for vGPU servers. + * Update a routing table. Update a routing table defined in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param updateRoutingTableOfAreaPayload Request an update of a routing table. (required) + * @return RoutingTable * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server stop request accepted. -
200 Update request for routing table successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void stopServer( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) - throws ApiException { - stopServerWithHttpInfo(projectId, serverId); + public RoutingTable updateRoutingTableOfArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull + UpdateRoutingTableOfAreaPayload updateRoutingTableOfAreaPayload) + throws ApiException { + ApiResponse localVarResp = + updateRoutingTableOfAreaWithHttpInfo( + organizationId, + areaId, + region, + routingTableId, + updateRoutingTableOfAreaPayload); + return localVarResp.getData(); } /** - * Stop an existing server. Stops an existing server. The server will remain on the Hypervisor - * and will be charged full price for all resources attached to it. The attached resources will - * remain reserved. Useful particularly for vGPU servers. + * Update a routing table. Update a routing table defined in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ApiResponse<Void> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param updateRoutingTableOfAreaPayload Request an update of a routing table. (required) + * @return ApiResponse<RoutingTable> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server stop request accepted. -
200 Update request for routing table successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse stopServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse updateRoutingTableOfAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull + UpdateRoutingTableOfAreaPayload updateRoutingTableOfAreaPayload) throws ApiException { - okhttp3.Call localVarCall = stopServerValidateBeforeCall(projectId, serverId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + updateRoutingTableOfAreaValidateBeforeCall( + organizationId, + areaId, + region, + routingTableId, + updateRoutingTableOfAreaPayload, + null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Stop an existing server. (asynchronously) Stops an existing server. The server will remain on - * the Hypervisor and will be charged full price for all resources attached to it. The attached - * resources will remain reserved. Useful particularly for vGPU servers. + * Update a routing table. (asynchronously) Update a routing table defined in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routingTableId The identifier (ID) of a STACKIT Routing Table. (required) + * @param updateRoutingTableOfAreaPayload Request an update of a routing table. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -21518,31 +28032,44 @@ public ApiResponse stopServerWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server stop request accepted. -
200 Update request for routing table successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call stopServerAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) + public okhttp3.Call updateRoutingTableOfAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routingTableId, + @javax.annotation.Nonnull + UpdateRoutingTableOfAreaPayload updateRoutingTableOfAreaPayload, + final ApiCallback _callback) throws ApiException { - okhttp3.Call localVarCall = stopServerValidateBeforeCall(projectId, serverId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + okhttp3.Call localVarCall = + updateRoutingTableOfAreaValidateBeforeCall( + organizationId, + areaId, + region, + routingTableId, + updateRoutingTableOfAreaPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for unrescueServer + * Build call for updateServer * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param updateServerPayload Request an update of a server. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -21550,18 +28077,19 @@ public okhttp3.Call stopServerAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server unrescue request accepted. -
200 Server has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call unrescueServerCall( + public okhttp3.Call updateServerCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UpdateServerPayload updateServerPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -21577,14 +28105,17 @@ public okhttp3.Call unrescueServerCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = updateServerPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/unrescue" + "/v2beta1/projects/{projectId}/regions/{region}/servers/{serverId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", localVarApiClient.escapeString(serverId.toString())); @@ -21601,7 +28132,7 @@ public okhttp3.Call unrescueServerCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {}; + final String[] localVarContentTypes = {"application/json"}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -21612,7 +28143,7 @@ public okhttp3.Call unrescueServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -21624,88 +28155,115 @@ public okhttp3.Call unrescueServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call unrescueServerValidateBeforeCall( + private okhttp3.Call updateServerValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UpdateServerPayload updateServerPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling unrescueServer(Async)"); + "Missing the required parameter 'projectId' when calling updateServer(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling updateServer(Async)"); } // verify the required parameter 'serverId' is set if (serverId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling unrescueServer(Async)"); + "Missing the required parameter 'serverId' when calling updateServer(Async)"); + } + + // verify the required parameter 'updateServerPayload' is set + if (updateServerPayload == null) { + throw new ApiException( + "Missing the required parameter 'updateServerPayload' when calling updateServer(Async)"); } - return unrescueServerCall(projectId, serverId, _callback); + return updateServerCall(projectId, region, serverId, updateServerPayload, _callback); } /** - * Unrescue an existing server. Unrescue an existing server. The original boot volume is - * attached as boot volume of the server and the server is booted up. + * Update information of a server. Update name or labels of the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param updateServerPayload Request an update of a server. (required) + * @return Server * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server unrescue request accepted. -
200 Server has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public void unrescueServer( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public Server updateServer( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UpdateServerPayload updateServerPayload) throws ApiException { - unrescueServerWithHttpInfo(projectId, serverId); + ApiResponse localVarResp = + updateServerWithHttpInfo(projectId, region, serverId, updateServerPayload); + return localVarResp.getData(); } /** - * Unrescue an existing server. Unrescue an existing server. The original boot volume is - * attached as boot volume of the server and the server is booted up. + * Update information of a server. Update name or labels of the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @return ApiResponse<Void> + * @param updateServerPayload Request an update of a server. (required) + * @return ApiResponse<Server> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server unrescue request accepted. -
200 Server has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse unrescueServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID serverId) + public ApiResponse updateServerWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull UpdateServerPayload updateServerPayload) throws ApiException { - okhttp3.Call localVarCall = unrescueServerValidateBeforeCall(projectId, serverId, null); - return localVarApiClient.execute(localVarCall); + okhttp3.Call localVarCall = + updateServerValidateBeforeCall( + projectId, region, serverId, updateServerPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); + return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Unrescue an existing server. (asynchronously) Unrescue an existing server. The original boot - * volume is attached as boot volume of the server and the server is booted up. + * Update information of a server. (asynchronously) Update name or labels of the server. * * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param updateServerPayload Request an update of a server. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -21714,34 +28272,37 @@ public ApiResponse unrescueServerWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
202 Server unrescue request accepted. -
200 Server has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call unrescueServerAsync( + public okhttp3.Call updateServerAsync( @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID serverId, - final ApiCallback _callback) + @javax.annotation.Nonnull UpdateServerPayload updateServerPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - unrescueServerValidateBeforeCall(projectId, serverId, _callback); - localVarApiClient.executeAsync(localVarCall, _callback); + updateServerValidateBeforeCall( + projectId, region, serverId, updateServerPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); + localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateAttachedVolume + * Build call for updateVolume * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param updateAttachedVolumePayload Request a volume attachment update. (required) + * @param updateVolumePayload Request an update of a volume. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -21749,7 +28310,7 @@ public okhttp3.Call unrescueServerAsync( * * * - * + * * * * @@ -21757,11 +28318,11 @@ public okhttp3.Call unrescueServerAsync( * *
Response Details
Status Code Description Response Headers
200 Response to update call. Provide the updated volume attachment object. -
200 Volume has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateAttachedVolumeCall( + public okhttp3.Call updateVolumeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload, + @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -21777,17 +28338,17 @@ public okhttp3.Call updateAttachedVolumeCall( basePath = null; } - Object localVarPostBody = updateAttachedVolumePayload; + Object localVarPostBody = updateVolumePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/volume-attachments/{volumeId}" + "/v2beta1/projects/{projectId}/regions/{region}/volumes/{volumeId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())) + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "volumeId" + "}", localVarApiClient.escapeString(volumeId.toString())); @@ -21827,56 +28388,55 @@ public okhttp3.Call updateAttachedVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateAttachedVolumeValidateBeforeCall( + private okhttp3.Call updateVolumeValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload, + @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateAttachedVolume(Async)"); + "Missing the required parameter 'projectId' when calling updateVolume(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling updateAttachedVolume(Async)"); + "Missing the required parameter 'region' when calling updateVolume(Async)"); } // verify the required parameter 'volumeId' is set if (volumeId == null) { throw new ApiException( - "Missing the required parameter 'volumeId' when calling updateAttachedVolume(Async)"); + "Missing the required parameter 'volumeId' when calling updateVolume(Async)"); } - // verify the required parameter 'updateAttachedVolumePayload' is set - if (updateAttachedVolumePayload == null) { + // verify the required parameter 'updateVolumePayload' is set + if (updateVolumePayload == null) { throw new ApiException( - "Missing the required parameter 'updateAttachedVolumePayload' when calling updateAttachedVolume(Async)"); + "Missing the required parameter 'updateVolumePayload' when calling updateVolume(Async)"); } - return updateAttachedVolumeCall( - projectId, serverId, volumeId, updateAttachedVolumePayload, _callback); + return updateVolumeCall(projectId, region, volumeId, updateVolumePayload, _callback); } /** - * Update Volume Attachment Parameters. Update the properties of an existing Volume Attachment. + * Update information of a volume. Update name, description or labels of the volume. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param updateAttachedVolumePayload Request a volume attachment update. (required) - * @return VolumeAttachment + * @param updateVolumePayload Request an update of a volume. (required) + * @return Volume * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -21884,33 +28444,32 @@ private okhttp3.Call updateAttachedVolumeValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Response to update call. Provide the updated volume attachment object. -
200 Volume has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public VolumeAttachment updateAttachedVolume( + public Volume updateVolume( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload) + @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload) throws ApiException { - ApiResponse localVarResp = - updateAttachedVolumeWithHttpInfo( - projectId, serverId, volumeId, updateAttachedVolumePayload); + ApiResponse localVarResp = + updateVolumeWithHttpInfo(projectId, region, volumeId, updateVolumePayload); return localVarResp.getData(); } /** - * Update Volume Attachment Parameters. Update the properties of an existing Volume Attachment. + * Update information of a volume. Update name, description or labels of the volume. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param updateAttachedVolumePayload Request a volume attachment update. (required) - * @return ApiResponse<VolumeAttachment> + * @param updateVolumePayload Request an update of a volume. (required) + * @return ApiResponse<Volume> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -21918,27 +28477,27 @@ public VolumeAttachment updateAttachedVolume( * *
Response Details
Status Code Description Response Headers
200 Response to update call. Provide the updated volume attachment object. -
200 Volume has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateAttachedVolumeWithHttpInfo( + public ApiResponse updateVolumeWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload) + @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload) throws ApiException { okhttp3.Call localVarCall = - updateAttachedVolumeValidateBeforeCall( - projectId, serverId, volumeId, updateAttachedVolumePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + updateVolumeValidateBeforeCall( + projectId, region, volumeId, updateVolumePayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update Volume Attachment Parameters. (asynchronously) Update the properties of an existing - * Volume Attachment. + * Update information of a volume. (asynchronously) Update name, description or labels of the + * volume. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) + * @param region The STACKIT Region of the resources. (required) * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param updateAttachedVolumePayload Request a volume attachment update. (required) + * @param updateVolumePayload Request an update of a volume. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -21947,7 +28506,7 @@ public ApiResponse updateAttachedVolumeWithHttpInfo( * * * - * + * * * * @@ -21955,28 +28514,30 @@ public ApiResponse updateAttachedVolumeWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Response to update call. Provide the updated volume attachment object. -
200 Volume has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateAttachedVolumeAsync( + public okhttp3.Call updateVolumeAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull String region, @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateAttachedVolumePayload updateAttachedVolumePayload, - final ApiCallback _callback) + @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateAttachedVolumeValidateBeforeCall( - projectId, serverId, volumeId, updateAttachedVolumePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + updateVolumeValidateBeforeCall( + projectId, region, volumeId, updateVolumePayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateBackup + * Build call for v2beta1ConfigureNetworkAreaRegion * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @param updateBackupPayload Request an update of a backup. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1ConfigureNetworkAreaRegionPayload Request to add a new regional network area + * configuration. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -21984,18 +28545,22 @@ public okhttp3.Call updateAttachedVolumeAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Backup has been updated. -
202 Configure network area in a new region was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateBackupCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nonnull UpdateBackupPayload updateBackupPayload, + public okhttp3.Call v2beta1ConfigureNetworkAreaRegionCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1ConfigureNetworkAreaRegionPayload + v2beta1ConfigureNetworkAreaRegionPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22011,17 +28576,20 @@ public okhttp3.Call updateBackupCall( basePath = null; } - Object localVarPostBody = updateBackupPayload; + Object localVarPostBody = v2beta1ConfigureNetworkAreaRegionPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups/{backupId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "backupId" + "}", - localVarApiClient.escapeString(backupId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -22046,7 +28614,7 @@ public okhttp3.Call updateBackupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -22058,102 +28626,137 @@ public okhttp3.Call updateBackupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateBackupValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nonnull UpdateBackupPayload updateBackupPayload, + private okhttp3.Call v2beta1ConfigureNetworkAreaRegionValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1ConfigureNetworkAreaRegionPayload + v2beta1ConfigureNetworkAreaRegionPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateBackup(Async)"); + "Missing the required parameter 'organizationId' when calling v2beta1ConfigureNetworkAreaRegion(Async)"); } - // verify the required parameter 'backupId' is set - if (backupId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling v2beta1ConfigureNetworkAreaRegion(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'backupId' when calling updateBackup(Async)"); + "Missing the required parameter 'region' when calling v2beta1ConfigureNetworkAreaRegion(Async)"); } - // verify the required parameter 'updateBackupPayload' is set - if (updateBackupPayload == null) { + // verify the required parameter 'v2beta1ConfigureNetworkAreaRegionPayload' is set + if (v2beta1ConfigureNetworkAreaRegionPayload == null) { throw new ApiException( - "Missing the required parameter 'updateBackupPayload' when calling updateBackup(Async)"); + "Missing the required parameter 'v2beta1ConfigureNetworkAreaRegionPayload' when calling v2beta1ConfigureNetworkAreaRegion(Async)"); } - return updateBackupCall(projectId, backupId, updateBackupPayload, _callback); + return v2beta1ConfigureNetworkAreaRegionCall( + organizationId, + areaId, + region, + v2beta1ConfigureNetworkAreaRegionPayload, + _callback); } /** - * Update information of a backup. Update name or labels of the backup. + * Configure a region for a network area. Configure a new region for a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @param updateBackupPayload Request an update of a backup. (required) - * @return Backup + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1ConfigureNetworkAreaRegionPayload Request to add a new regional network area + * configuration. (required) + * @return RegionalArea * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Backup has been updated. -
202 Configure network area in a new region was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Backup updateBackup( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nonnull UpdateBackupPayload updateBackupPayload) + public RegionalArea v2beta1ConfigureNetworkAreaRegion( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1ConfigureNetworkAreaRegionPayload + v2beta1ConfigureNetworkAreaRegionPayload) throws ApiException { - ApiResponse localVarResp = - updateBackupWithHttpInfo(projectId, backupId, updateBackupPayload); + ApiResponse localVarResp = + v2beta1ConfigureNetworkAreaRegionWithHttpInfo( + organizationId, areaId, region, v2beta1ConfigureNetworkAreaRegionPayload); return localVarResp.getData(); } /** - * Update information of a backup. Update name or labels of the backup. + * Configure a region for a network area. Configure a new region for a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @param updateBackupPayload Request an update of a backup. (required) - * @return ApiResponse<Backup> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1ConfigureNetworkAreaRegionPayload Request to add a new regional network area + * configuration. (required) + * @return ApiResponse<RegionalArea> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Backup has been updated. -
202 Configure network area in a new region was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateBackupWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nonnull UpdateBackupPayload updateBackupPayload) + public ApiResponse v2beta1ConfigureNetworkAreaRegionWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1ConfigureNetworkAreaRegionPayload + v2beta1ConfigureNetworkAreaRegionPayload) throws ApiException { okhttp3.Call localVarCall = - updateBackupValidateBeforeCall(projectId, backupId, updateBackupPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1ConfigureNetworkAreaRegionValidateBeforeCall( + organizationId, + areaId, + region, + v2beta1ConfigureNetworkAreaRegionPayload, + null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update information of a backup. (asynchronously) Update name or labels of the backup. + * Configure a region for a network area. (asynchronously) Configure a new region for a network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param backupId The identifier (ID) of a STACKIT Backup. (required) - * @param updateBackupPayload Request an update of a backup. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1ConfigureNetworkAreaRegionPayload Request to add a new regional network area + * configuration. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -22162,34 +28765,43 @@ public ApiResponse updateBackupWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Backup has been updated. -
202 Configure network area in a new region was accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateBackupAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID backupId, - @javax.annotation.Nonnull UpdateBackupPayload updateBackupPayload, - final ApiCallback _callback) + public okhttp3.Call v2beta1ConfigureNetworkAreaRegionAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1ConfigureNetworkAreaRegionPayload + v2beta1ConfigureNetworkAreaRegionPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateBackupValidateBeforeCall(projectId, backupId, updateBackupPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1ConfigureNetworkAreaRegionValidateBeforeCall( + organizationId, + areaId, + region, + v2beta1ConfigureNetworkAreaRegionPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateImage + * Build call for v2beta1CreateSnapshot * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param updateImagePayload Request an update of an Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1CreateSnapshotPayload Request a snapshot creation. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -22197,7 +28809,7 @@ public okhttp3.Call updateBackupAsync( * * * - * + * * * * @@ -22205,10 +28817,10 @@ public okhttp3.Call updateBackupAsync( * *
Response Details
Status Code Description Response Headers
200 Response to update call. Provide the updated image object. -
201 Create request for Snapshot accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateImageCall( + public okhttp3.Call v2beta1CreateSnapshotCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2beta1CreateSnapshotPayload v2beta1CreateSnapshotPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22224,17 +28836,17 @@ public okhttp3.Call updateImageCall( basePath = null; } - Object localVarPostBody = updateImagePayload; + Object localVarPostBody = v2beta1CreateSnapshotPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}" + "/v2beta1/projects/{projectId}/regions/{region}/snapshots" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -22259,7 +28871,7 @@ public okhttp3.Call updateImageCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -22271,47 +28883,48 @@ public okhttp3.Call updateImageCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateImageValidateBeforeCall( + private okhttp3.Call v2beta1CreateSnapshotValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2beta1CreateSnapshotPayload v2beta1CreateSnapshotPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateImage(Async)"); + "Missing the required parameter 'projectId' when calling v2beta1CreateSnapshot(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling updateImage(Async)"); + "Missing the required parameter 'region' when calling v2beta1CreateSnapshot(Async)"); } - // verify the required parameter 'updateImagePayload' is set - if (updateImagePayload == null) { + // verify the required parameter 'v2beta1CreateSnapshotPayload' is set + if (v2beta1CreateSnapshotPayload == null) { throw new ApiException( - "Missing the required parameter 'updateImagePayload' when calling updateImage(Async)"); + "Missing the required parameter 'v2beta1CreateSnapshotPayload' when calling v2beta1CreateSnapshot(Async)"); } - return updateImageCall(projectId, imageId, updateImagePayload, _callback); + return v2beta1CreateSnapshotCall( + projectId, region, v2beta1CreateSnapshotPayload, _callback); } /** - * Update Image Parameters. Update the properties of an existing Image inside a project. + * Create new Snapshot. Create a new Snapshot from a Volume in a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param updateImagePayload Request an update of an Image. (required) - * @return Image + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1CreateSnapshotPayload Request a snapshot creation. (required) + * @return Snapshot * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -22319,30 +28932,30 @@ private okhttp3.Call updateImageValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Response to update call. Provide the updated image object. -
201 Create request for Snapshot accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Image updateImage( + public Snapshot v2beta1CreateSnapshot( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2beta1CreateSnapshotPayload v2beta1CreateSnapshotPayload) throws ApiException { - ApiResponse localVarResp = - updateImageWithHttpInfo(projectId, imageId, updateImagePayload); + ApiResponse localVarResp = + v2beta1CreateSnapshotWithHttpInfo(projectId, region, v2beta1CreateSnapshotPayload); return localVarResp.getData(); } /** - * Update Image Parameters. Update the properties of an existing Image inside a project. + * Create new Snapshot. Create a new Snapshot from a Volume in a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param updateImagePayload Request an update of an Image. (required) - * @return ApiResponse<Image> + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1CreateSnapshotPayload Request a snapshot creation. (required) + * @return ApiResponse<Snapshot> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -22350,24 +28963,24 @@ public Image updateImage( * *
Response Details
Status Code Description Response Headers
200 Response to update call. Provide the updated image object. -
201 Create request for Snapshot accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateImageWithHttpInfo( + public ApiResponse v2beta1CreateSnapshotWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2beta1CreateSnapshotPayload v2beta1CreateSnapshotPayload) throws ApiException { okhttp3.Call localVarCall = - updateImageValidateBeforeCall(projectId, imageId, updateImagePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1CreateSnapshotValidateBeforeCall( + projectId, region, v2beta1CreateSnapshotPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update Image Parameters. (asynchronously) Update the properties of an existing Image inside a - * project. + * Create new Snapshot. (asynchronously) Create a new Snapshot from a Volume in a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param updateImagePayload Request an update of an Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1CreateSnapshotPayload Request a snapshot creation. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -22376,7 +28989,7 @@ public ApiResponse updateImageWithHttpInfo( * * * - * + * * * * @@ -22384,25 +28997,27 @@ public ApiResponse updateImageWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Response to update call. Provide the updated image object. -
201 Create request for Snapshot accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateImageAsync( + public okhttp3.Call v2beta1CreateSnapshotAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2beta1CreateSnapshotPayload v2beta1CreateSnapshotPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateImageValidateBeforeCall(projectId, imageId, updateImagePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1CreateSnapshotValidateBeforeCall( + projectId, region, v2beta1CreateSnapshotPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateImageScopeLocal + * Build call for v2beta1DeleteNetworkAreaRegion * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -22410,17 +29025,19 @@ public okhttp3.Call updateImageAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Response to update image-scope to local. Provide the updated image object. -
202 Regional configuration has been deleted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateImageScopeLocalCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + public okhttp3.Call v2beta1DeleteNetworkAreaRegionCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22440,13 +29057,16 @@ public okhttp3.Call updateImageScopeLocalCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/publish" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -22483,90 +29103,104 @@ public okhttp3.Call updateImageScopeLocalCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateImageScopeLocalValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + private okhttp3.Call v2beta1DeleteNetworkAreaRegionValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateImageScopeLocal(Async)"); + "Missing the required parameter 'organizationId' when calling v2beta1DeleteNetworkAreaRegion(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling v2beta1DeleteNetworkAreaRegion(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling updateImageScopeLocal(Async)"); + "Missing the required parameter 'region' when calling v2beta1DeleteNetworkAreaRegion(Async)"); } - return updateImageScopeLocalCall(projectId, imageId, _callback); + return v2beta1DeleteNetworkAreaRegionCall(organizationId, areaId, region, _callback); } /** - * Update Image Scope to Local. Update the scope property of an existing Image inside a project - * to local. + * Delete a configuration of region for a network area. Delete a current configuration of region + * for a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return Image + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Response to update image-scope to local. Provide the updated image object. -
202 Regional configuration has been deleted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Image updateImageScopeLocal( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public void v2beta1DeleteNetworkAreaRegion( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region) throws ApiException { - ApiResponse localVarResp = updateImageScopeLocalWithHttpInfo(projectId, imageId); - return localVarResp.getData(); + v2beta1DeleteNetworkAreaRegionWithHttpInfo(organizationId, areaId, region); } /** - * Update Image Scope to Local. Update the scope property of an existing Image inside a project - * to local. + * Delete a configuration of region for a network area. Delete a current configuration of region + * for a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return ApiResponse<Image> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Response to update image-scope to local. Provide the updated image object. -
202 Regional configuration has been deleted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateImageScopeLocalWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public ApiResponse v2beta1DeleteNetworkAreaRegionWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region) throws ApiException { okhttp3.Call localVarCall = - updateImageScopeLocalValidateBeforeCall(projectId, imageId, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + v2beta1DeleteNetworkAreaRegionValidateBeforeCall( + organizationId, areaId, region, null); + return localVarApiClient.execute(localVarCall); } /** - * Update Image Scope to Local. (asynchronously) Update the scope property of an existing Image - * inside a project to local. + * Delete a configuration of region for a network area. (asynchronously) Delete a current + * configuration of region for a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -22575,32 +29209,35 @@ public ApiResponse updateImageScopeLocalWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Response to update image-scope to local. Provide the updated image object. -
202 Regional configuration has been deleted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateImageScopeLocalAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - final ApiCallback _callback) + public okhttp3.Call v2beta1DeleteNetworkAreaRegionAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateImageScopeLocalValidateBeforeCall(projectId, imageId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + v2beta1DeleteNetworkAreaRegionValidateBeforeCall( + organizationId, areaId, region, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for updateImageScopePublic + * Build call for v2beta1DeleteSnapshot * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -22608,7 +29245,7 @@ public okhttp3.Call updateImageScopeLocalAsync( * * * - * + * * * * @@ -22616,9 +29253,10 @@ public okhttp3.Call updateImageScopeLocalAsync( * *
Response Details
Status Code Description Response Headers
200 Response to update image-scope to public. Provide the updated image object. -
204 Snapshot delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateImageScopePublicCall( + public okhttp3.Call v2beta1DeleteSnapshotCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22638,13 +29276,16 @@ public okhttp3.Call updateImageScopePublicCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/publish" + "/v2beta1/projects/{projectId}/regions/{region}/snapshots/{snapshotId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "snapshotId" + "}", + localVarApiClient.escapeString(snapshotId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -22669,7 +29310,7 @@ public okhttp3.Call updateImageScopePublicCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PUT", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -22681,40 +29322,46 @@ public okhttp3.Call updateImageScopePublicCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateImageScopePublicValidateBeforeCall( + private okhttp3.Call v2beta1DeleteSnapshotValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateImageScopePublic(Async)"); + "Missing the required parameter 'projectId' when calling v2beta1DeleteSnapshot(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling updateImageScopePublic(Async)"); + "Missing the required parameter 'region' when calling v2beta1DeleteSnapshot(Async)"); } - return updateImageScopePublicCall(projectId, imageId, _callback); + // verify the required parameter 'snapshotId' is set + if (snapshotId == null) { + throw new ApiException( + "Missing the required parameter 'snapshotId' when calling v2beta1DeleteSnapshot(Async)"); + } + + return v2beta1DeleteSnapshotCall(projectId, region, snapshotId, _callback); } /** - * Update Image Scope to Public. Update the scope property of an existing Image inside a project - * to public. + * Delete a snapshot. Delete a snapshot that is part of the project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return Image + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -22722,27 +29369,28 @@ private okhttp3.Call updateImageScopePublicValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Response to update image-scope to public. Provide the updated image object. -
204 Snapshot delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Image updateImageScopePublic( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public void v2beta1DeleteSnapshot( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId) throws ApiException { - ApiResponse localVarResp = updateImageScopePublicWithHttpInfo(projectId, imageId); - return localVarResp.getData(); + v2beta1DeleteSnapshotWithHttpInfo(projectId, region, snapshotId); } /** - * Update Image Scope to Public. Update the scope property of an existing Image inside a project - * to public. + * Delete a snapshot. Delete a snapshot that is part of the project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @return ApiResponse<Image> + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @return ApiResponse<Void> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -22750,21 +29398,22 @@ public Image updateImageScopePublic( * *
Response Details
Status Code Description Response Headers
200 Response to update image-scope to public. Provide the updated image object. -
204 Snapshot delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateImageScopePublicWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, @javax.annotation.Nonnull UUID imageId) + public ApiResponse v2beta1DeleteSnapshotWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId) throws ApiException { okhttp3.Call localVarCall = - updateImageScopePublicValidateBeforeCall(projectId, imageId, null); - Type localVarReturnType = new TypeToken() {}.getType(); - return localVarApiClient.execute(localVarCall, localVarReturnType); + v2beta1DeleteSnapshotValidateBeforeCall(projectId, region, snapshotId, null); + return localVarApiClient.execute(localVarCall); } /** - * Update Image Scope to Public. (asynchronously) Update the scope property of an existing Image - * inside a project to public. + * Delete a snapshot. (asynchronously) Delete a snapshot that is part of the project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -22773,7 +29422,7 @@ public ApiResponse updateImageScopePublicWithHttpInfo( * * * - * + * * * * @@ -22781,25 +29430,25 @@ public ApiResponse updateImageScopePublicWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Response to update image-scope to public. Provide the updated image object. -
204 Snapshot delete request has been accepted. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateImageScopePublicAsync( + public okhttp3.Call v2beta1DeleteSnapshotAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateImageScopePublicValidateBeforeCall(projectId, imageId, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); - localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); + v2beta1DeleteSnapshotValidateBeforeCall(projectId, region, snapshotId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for updateImageShare + * Build call for v2beta1GetAreaRegion * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param updateImageSharePayload Update an Image Share. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -22807,7 +29456,7 @@ public okhttp3.Call updateImageScopePublicAsync( * * * - * + * * * * @@ -22815,10 +29464,10 @@ public okhttp3.Call updateImageScopePublicAsync( * *
Response Details
Status Code Description Response Headers
200 Updating Image share successful. -
200 Show configured region details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateImageShareCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload, + public okhttp3.Call v2beta1GetAreaRegionCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22834,17 +29483,20 @@ public okhttp3.Call updateImageShareCall( basePath = null; } - Object localVarPostBody = updateImageSharePayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "imageId" + "}", - localVarApiClient.escapeString(imageId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -22858,7 +29510,7 @@ public okhttp3.Call updateImageShareCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -22869,7 +29521,7 @@ public okhttp3.Call updateImageShareCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -22881,47 +29533,48 @@ public okhttp3.Call updateImageShareCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateImageShareValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload, + private okhttp3.Call v2beta1GetAreaRegionValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateImageShare(Async)"); + "Missing the required parameter 'organizationId' when calling v2beta1GetAreaRegion(Async)"); } - // verify the required parameter 'imageId' is set - if (imageId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling updateImageShare(Async)"); + "Missing the required parameter 'areaId' when calling v2beta1GetAreaRegion(Async)"); } - // verify the required parameter 'updateImageSharePayload' is set - if (updateImageSharePayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'updateImageSharePayload' when calling updateImageShare(Async)"); + "Missing the required parameter 'region' when calling v2beta1GetAreaRegion(Async)"); } - return updateImageShareCall(projectId, imageId, updateImageSharePayload, _callback); + return v2beta1GetAreaRegionCall(organizationId, areaId, region, _callback); } /** - * Update image share. Update share of an Image. Projects will be appended to existing list. + * Get details about a configured region. Get details about a configured region in a network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param updateImageSharePayload Update an Image Share. (required) - * @return ImageShare + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @return RegionalArea * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -22929,30 +29582,31 @@ private okhttp3.Call updateImageShareValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Updating Image share successful. -
200 Show configured region details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ImageShare updateImageShare( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload) + public RegionalArea v2beta1GetAreaRegion( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region) throws ApiException { - ApiResponse localVarResp = - updateImageShareWithHttpInfo(projectId, imageId, updateImageSharePayload); + ApiResponse localVarResp = + v2beta1GetAreaRegionWithHttpInfo(organizationId, areaId, region); return localVarResp.getData(); } /** - * Update image share. Update share of an Image. Projects will be appended to existing list. + * Get details about a configured region. Get details about a configured region in a network + * area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param updateImageSharePayload Update an Image Share. (required) - * @return ApiResponse<ImageShare> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @return ApiResponse<RegionalArea> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -22960,25 +29614,24 @@ public ImageShare updateImageShare( * *
Response Details
Status Code Description Response Headers
200 Updating Image share successful. -
200 Show configured region details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateImageShareWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload) + public ApiResponse v2beta1GetAreaRegionWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region) throws ApiException { okhttp3.Call localVarCall = - updateImageShareValidateBeforeCall( - projectId, imageId, updateImageSharePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1GetAreaRegionValidateBeforeCall(organizationId, areaId, region, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update image share. (asynchronously) Update share of an Image. Projects will be appended to - * existing list. + * Get details about a configured region. (asynchronously) Get details about a configured region + * in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param imageId The identifier (ID) of a STACKIT Image. (required) - * @param updateImageSharePayload Update an Image Share. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -22987,7 +29640,7 @@ public ApiResponse updateImageShareWithHttpInfo( * * * - * + * * * * @@ -22995,26 +29648,26 @@ public ApiResponse updateImageShareWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Updating Image share successful. -
200 Show configured region details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateImageShareAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImageSharePayload updateImageSharePayload, - final ApiCallback _callback) + public okhttp3.Call v2beta1GetAreaRegionAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateImageShareValidateBeforeCall( - projectId, imageId, updateImageSharePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1GetAreaRegionValidateBeforeCall(organizationId, areaId, region, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateKeyPair + * Build call for v2beta1GetSnapshot * - * @param keypairName The name of an SSH keypair. (required) - * @param updateKeyPairPayload Request an update of an SSH keypair. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -23022,7 +29675,7 @@ public okhttp3.Call updateImageShareAsync( * * * - * + * * * * @@ -23030,9 +29683,10 @@ public okhttp3.Call updateImageShareAsync( * *
Response Details
Status Code Description Response Headers
200 SSH keypair has been updated. -
200 Show snapshot details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateKeyPairCall( - @javax.annotation.Nonnull String keypairName, - @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload, + public okhttp3.Call v2beta1GetSnapshotCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -23048,14 +29702,20 @@ public okhttp3.Call updateKeyPairCall( basePath = null; } - Object localVarPostBody = updateKeyPairPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/keypairs/{keypairName}" + "/v2beta1/projects/{projectId}/regions/{region}/snapshots/{snapshotId}" .replace( - "{" + "keypairName" + "}", - localVarApiClient.escapeString(keypairName.toString())); + "{" + "projectId" + "}", + localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "snapshotId" + "}", + localVarApiClient.escapeString(snapshotId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -23069,7 +29729,7 @@ public okhttp3.Call updateKeyPairCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -23080,7 +29740,7 @@ public okhttp3.Call updateKeyPairCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -23092,39 +29752,47 @@ public okhttp3.Call updateKeyPairCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateKeyPairValidateBeforeCall( - @javax.annotation.Nonnull String keypairName, - @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload, + private okhttp3.Call v2beta1GetSnapshotValidateBeforeCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'keypairName' is set - if (keypairName == null) { + // verify the required parameter 'projectId' is set + if (projectId == null) { throw new ApiException( - "Missing the required parameter 'keypairName' when calling updateKeyPair(Async)"); + "Missing the required parameter 'projectId' when calling v2beta1GetSnapshot(Async)"); } - // verify the required parameter 'updateKeyPairPayload' is set - if (updateKeyPairPayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'updateKeyPairPayload' when calling updateKeyPair(Async)"); + "Missing the required parameter 'region' when calling v2beta1GetSnapshot(Async)"); } - return updateKeyPairCall(keypairName, updateKeyPairPayload, _callback); + // verify the required parameter 'snapshotId' is set + if (snapshotId == null) { + throw new ApiException( + "Missing the required parameter 'snapshotId' when calling v2beta1GetSnapshot(Async)"); + } + + return v2beta1GetSnapshotCall(projectId, region, snapshotId, _callback); } /** - * Update information of an SSH keypair. Update labels of the SSH keypair. + * Get details about a snapshot. Get details about a block device snapshot. * - * @param keypairName The name of an SSH keypair. (required) - * @param updateKeyPairPayload Request an update of an SSH keypair. (required) - * @return Keypair + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @return Snapshot * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -23132,28 +29800,30 @@ private okhttp3.Call updateKeyPairValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 SSH keypair has been updated. -
200 Show snapshot details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Keypair updateKeyPair( - @javax.annotation.Nonnull String keypairName, - @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload) + public Snapshot v2beta1GetSnapshot( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId) throws ApiException { - ApiResponse localVarResp = - updateKeyPairWithHttpInfo(keypairName, updateKeyPairPayload); + ApiResponse localVarResp = + v2beta1GetSnapshotWithHttpInfo(projectId, region, snapshotId); return localVarResp.getData(); } /** - * Update information of an SSH keypair. Update labels of the SSH keypair. + * Get details about a snapshot. Get details about a block device snapshot. * - * @param keypairName The name of an SSH keypair. (required) - * @param updateKeyPairPayload Request an update of an SSH keypair. (required) - * @return ApiResponse<Keypair> + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @return ApiResponse<Snapshot> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -23161,21 +29831,23 @@ public Keypair updateKeyPair( * *
Response Details
Status Code Description Response Headers
200 SSH keypair has been updated. -
200 Show snapshot details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateKeyPairWithHttpInfo( - @javax.annotation.Nonnull String keypairName, - @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload) + public ApiResponse v2beta1GetSnapshotWithHttpInfo( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId) throws ApiException { okhttp3.Call localVarCall = - updateKeyPairValidateBeforeCall(keypairName, updateKeyPairPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1GetSnapshotValidateBeforeCall(projectId, region, snapshotId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update information of an SSH keypair. (asynchronously) Update labels of the SSH keypair. + * Get details about a snapshot. (asynchronously) Get details about a block device snapshot. * - * @param keypairName The name of an SSH keypair. (required) - * @param updateKeyPairPayload Request an update of an SSH keypair. (required) + * @param projectId The identifier (ID) of a STACKIT Project. (required) + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -23184,7 +29856,7 @@ public ApiResponse updateKeyPairWithHttpInfo( * * * - * + * * * * @@ -23192,26 +29864,25 @@ public ApiResponse updateKeyPairWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 SSH keypair has been updated. -
200 Show snapshot details. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateKeyPairAsync( - @javax.annotation.Nonnull String keypairName, - @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload, - final ApiCallback _callback) + public okhttp3.Call v2beta1GetSnapshotAsync( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateKeyPairValidateBeforeCall(keypairName, updateKeyPairPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1GetSnapshotValidateBeforeCall(projectId, region, snapshotId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateNetworkAreaRoute + * Build call for v2beta1ListAreaRegions * * @param organizationId The identifier (ID) of a STACKIT Organization. (required) * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) - * @param updateNetworkAreaRoutePayload Request an update of a network route. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -23219,7 +29890,7 @@ public okhttp3.Call updateKeyPairAsync( * * * - * + * * * * @@ -23227,11 +29898,9 @@ public okhttp3.Call updateKeyPairAsync( * *
Response Details
Status Code Description Response Headers
200 Update request for network successful. -
200 List all configured area regions. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateNetworkAreaRouteCall( + public okhttp3.Call v2beta1ListAreaRegionsCall( @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - @javax.annotation.Nonnull UpdateNetworkAreaRoutePayload updateNetworkAreaRoutePayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -23247,20 +29916,17 @@ public okhttp3.Call updateNetworkAreaRouteCall( basePath = null; } - Object localVarPostBody = updateNetworkAreaRoutePayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/routes/{routeId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions" .replace( "{" + "organizationId" + "}", localVarApiClient.escapeString(organizationId.toString())) .replace( "{" + "areaId" + "}", - localVarApiClient.escapeString(areaId.toString())) - .replace( - "{" + "routeId" + "}", - localVarApiClient.escapeString(routeId.toString())); + localVarApiClient.escapeString(areaId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -23274,7 +29940,7 @@ public okhttp3.Call updateNetworkAreaRouteCall( localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -23285,7 +29951,7 @@ public okhttp3.Call updateNetworkAreaRouteCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -23297,56 +29963,39 @@ public okhttp3.Call updateNetworkAreaRouteCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateNetworkAreaRouteValidateBeforeCall( + private okhttp3.Call v2beta1ListAreaRegionsValidateBeforeCall( @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - @javax.annotation.Nonnull UpdateNetworkAreaRoutePayload updateNetworkAreaRoutePayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'organizationId' is set if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'organizationId' when calling updateNetworkAreaRoute(Async)"); + "Missing the required parameter 'organizationId' when calling v2beta1ListAreaRegions(Async)"); } // verify the required parameter 'areaId' is set if (areaId == null) { throw new ApiException( - "Missing the required parameter 'areaId' when calling updateNetworkAreaRoute(Async)"); - } - - // verify the required parameter 'routeId' is set - if (routeId == null) { - throw new ApiException( - "Missing the required parameter 'routeId' when calling updateNetworkAreaRoute(Async)"); - } - - // verify the required parameter 'updateNetworkAreaRoutePayload' is set - if (updateNetworkAreaRoutePayload == null) { - throw new ApiException( - "Missing the required parameter 'updateNetworkAreaRoutePayload' when calling updateNetworkAreaRoute(Async)"); + "Missing the required parameter 'areaId' when calling v2beta1ListAreaRegions(Async)"); } - return updateNetworkAreaRouteCall( - organizationId, areaId, routeId, updateNetworkAreaRoutePayload, _callback); + return v2beta1ListAreaRegionsCall(organizationId, areaId, _callback); } /** - * Update a network route. Update a network route defined in a network area. + * List all configured regions in a network area. Get a list of all configured regions. * * @param organizationId The identifier (ID) of a STACKIT Organization. (required) * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) - * @param updateNetworkAreaRoutePayload Request an update of a network route. (required) - * @return Route + * @return RegionalAreaListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -23354,33 +30003,27 @@ private okhttp3.Call updateNetworkAreaRouteValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Update request for network successful. -
200 List all configured area regions. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Route updateNetworkAreaRoute( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - @javax.annotation.Nonnull UpdateNetworkAreaRoutePayload updateNetworkAreaRoutePayload) + public RegionalAreaListResponse v2beta1ListAreaRegions( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) throws ApiException { - ApiResponse localVarResp = - updateNetworkAreaRouteWithHttpInfo( - organizationId, areaId, routeId, updateNetworkAreaRoutePayload); + ApiResponse localVarResp = + v2beta1ListAreaRegionsWithHttpInfo(organizationId, areaId); return localVarResp.getData(); } /** - * Update a network route. Update a network route defined in a network area. + * List all configured regions in a network area. Get a list of all configured regions. * * @param organizationId The identifier (ID) of a STACKIT Organization. (required) * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) - * @param updateNetworkAreaRoutePayload Request an update of a network route. (required) - * @return ApiResponse<Route> + * @return ApiResponse<RegionalAreaListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -23388,26 +30031,21 @@ public Route updateNetworkAreaRoute( * *
Response Details
Status Code Description Response Headers
200 Update request for network successful. -
200 List all configured area regions. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateNetworkAreaRouteWithHttpInfo( - @javax.annotation.Nonnull UUID organizationId, - @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - @javax.annotation.Nonnull UpdateNetworkAreaRoutePayload updateNetworkAreaRoutePayload) + public ApiResponse v2beta1ListAreaRegionsWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) throws ApiException { okhttp3.Call localVarCall = - updateNetworkAreaRouteValidateBeforeCall( - organizationId, areaId, routeId, updateNetworkAreaRoutePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1ListAreaRegionsValidateBeforeCall(organizationId, areaId, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update a network route. (asynchronously) Update a network route defined in a network area. + * List all configured regions in a network area. (asynchronously) Get a list of all configured + * regions. * * @param organizationId The identifier (ID) of a STACKIT Organization. (required) * @param areaId The identifier (ID) of a STACKIT Network Area. (required) - * @param routeId The identifier (ID) of a STACKIT Route. (required) - * @param updateNetworkAreaRoutePayload Request an update of a network route. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -23416,7 +30054,7 @@ public ApiResponse updateNetworkAreaRouteWithHttpInfo( * * * - * + * * * * @@ -23424,29 +30062,25 @@ public ApiResponse updateNetworkAreaRouteWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Update request for network successful. -
200 List all configured area regions. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateNetworkAreaRouteAsync( + public okhttp3.Call v2beta1ListAreaRegionsAsync( @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId, - @javax.annotation.Nonnull UUID routeId, - @javax.annotation.Nonnull UpdateNetworkAreaRoutePayload updateNetworkAreaRoutePayload, - final ApiCallback _callback) + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateNetworkAreaRouteValidateBeforeCall( - organizationId, areaId, routeId, updateNetworkAreaRoutePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1ListAreaRegionsValidateBeforeCall(organizationId, areaId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateNic + * Build call for v2beta1ListSnapshotsInProject * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @param updateNicPayload Request an update of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -23454,20 +30088,18 @@ public okhttp3.Call updateNetworkAreaRouteAsync( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Network interface has been updated. -
200 List project snapshots. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateNicCall( + public okhttp3.Call v2beta1ListSnapshotsInProjectCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, - @javax.annotation.Nonnull UpdateNicPayload updateNicPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -23483,20 +30115,17 @@ public okhttp3.Call updateNicCall( basePath = null; } - Object localVarPostBody = updateNicPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}/nics/{nicId}" + "/v2beta1/projects/{projectId}/regions/{region}/snapshots" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "networkId" + "}", - localVarApiClient.escapeString(networkId.toString())) - .replace( - "{" + "nicId" + "}", - localVarApiClient.escapeString(nicId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -23504,13 +30133,18 @@ public okhttp3.Call updateNicCall( Map localVarCookieParams = new HashMap(); Map localVarFormParams = new HashMap(); + if (labelSelector != null) { + localVarQueryParams.addAll( + localVarApiClient.parameterToPair("label_selector", labelSelector)); + } + final String[] localVarAccepts = {"application/json"}; final String localVarAccept = localVarApiClient.selectHeaderAccept(localVarAccepts); if (localVarAccept != null) { localVarHeaderParams.put("Accept", localVarAccept); } - final String[] localVarContentTypes = {"application/json"}; + final String[] localVarContentTypes = {}; final String localVarContentType = localVarApiClient.selectHeaderContentType(localVarContentTypes); if (localVarContentType != null) { @@ -23521,7 +30155,7 @@ public okhttp3.Call updateNicCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -23533,119 +30167,98 @@ public okhttp3.Call updateNicCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateNicValidateBeforeCall( + private okhttp3.Call v2beta1ListSnapshotsInProjectValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, - @javax.annotation.Nonnull UpdateNicPayload updateNicPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateNic(Async)"); - } - - // verify the required parameter 'networkId' is set - if (networkId == null) { - throw new ApiException( - "Missing the required parameter 'networkId' when calling updateNic(Async)"); - } - - // verify the required parameter 'nicId' is set - if (nicId == null) { - throw new ApiException( - "Missing the required parameter 'nicId' when calling updateNic(Async)"); + "Missing the required parameter 'projectId' when calling v2beta1ListSnapshotsInProject(Async)"); } - // verify the required parameter 'updateNicPayload' is set - if (updateNicPayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'updateNicPayload' when calling updateNic(Async)"); + "Missing the required parameter 'region' when calling v2beta1ListSnapshotsInProject(Async)"); } - return updateNicCall(projectId, networkId, nicId, updateNicPayload, _callback); + return v2beta1ListSnapshotsInProjectCall(projectId, region, labelSelector, _callback); } /** - * Update a network interface. Update the properties of an existing network interface inside a - * network. + * List all snapshots inside a project. Get a list of all snapshots inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @param updateNicPayload Request an update of a network interface. (required) - * @return NIC + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return SnapshotListResponse * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Network interface has been updated. -
200 List project snapshots. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public NIC updateNic( + public SnapshotListResponse v2beta1ListSnapshotsInProject( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, - @javax.annotation.Nonnull UpdateNicPayload updateNicPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { - ApiResponse localVarResp = - updateNicWithHttpInfo(projectId, networkId, nicId, updateNicPayload); + ApiResponse localVarResp = + v2beta1ListSnapshotsInProjectWithHttpInfo(projectId, region, labelSelector); return localVarResp.getData(); } /** - * Update a network interface. Update the properties of an existing network interface inside a - * network. + * List all snapshots inside a project. Get a list of all snapshots inside a project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @param updateNicPayload Request an update of a network interface. (required) - * @return ApiResponse<NIC> + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) + * @return ApiResponse<SnapshotListResponse> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Network interface has been updated. -
200 List project snapshots. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateNicWithHttpInfo( + public ApiResponse v2beta1ListSnapshotsInProjectWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, - @javax.annotation.Nonnull UpdateNicPayload updateNicPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector) throws ApiException { okhttp3.Call localVarCall = - updateNicValidateBeforeCall(projectId, networkId, nicId, updateNicPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1ListSnapshotsInProjectValidateBeforeCall( + projectId, region, labelSelector, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update a network interface. (asynchronously) Update the properties of an existing network - * interface inside a network. + * List all snapshots inside a project. (asynchronously) Get a list of all snapshots inside a + * project. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param networkId The identifier (ID) of a STACKIT Network. (required) - * @param nicId The identifier (ID) of a network interface. (required) - * @param updateNicPayload Request an update of a network interface. (required) + * @param region The STACKIT Region of the resources. (required) + * @param labelSelector Filter resources by labels. (optional) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -23654,37 +30267,36 @@ public ApiResponse updateNicWithHttpInfo( * * * - * + * * * * * - * * *
Response Details
Status Code Description Response Headers
200 Network interface has been updated. -
200 List project snapshots. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateNicAsync( + public okhttp3.Call v2beta1ListSnapshotsInProjectAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull UUID nicId, - @javax.annotation.Nonnull UpdateNicPayload updateNicPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nullable String labelSelector, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateNicValidateBeforeCall( - projectId, networkId, nicId, updateNicPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1ListSnapshotsInProjectValidateBeforeCall( + projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updatePublicIP + * Build call for v2beta1UpdateBackup * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) - * @param updatePublicIPPayload Request an update of a public IP. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param v2beta1UpdateBackupPayload Request an update of a backup. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -23692,7 +30304,7 @@ public okhttp3.Call updateNicAsync( * * * - * + * * * * @@ -23700,10 +30312,11 @@ public okhttp3.Call updateNicAsync( * *
Response Details
Status Code Description Response Headers
200 Public IP has been updated. -
200 Backup has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updatePublicIPCall( + public okhttp3.Call v2beta1UpdateBackupCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, - @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull V2beta1UpdateBackupPayload v2beta1UpdateBackupPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -23719,17 +30332,20 @@ public okhttp3.Call updatePublicIPCall( basePath = null; } - Object localVarPostBody = updatePublicIPPayload; + Object localVarPostBody = v2beta1UpdateBackupPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/public-ips/{publicIpId}" + "/v2beta1/projects/{projectId}/regions/{region}/backups/{backupId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "publicIpId" + "}", - localVarApiClient.escapeString(publicIpId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "backupId" + "}", + localVarApiClient.escapeString(backupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -23766,47 +30382,56 @@ public okhttp3.Call updatePublicIPCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updatePublicIPValidateBeforeCall( + private okhttp3.Call v2beta1UpdateBackupValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, - @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull V2beta1UpdateBackupPayload v2beta1UpdateBackupPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updatePublicIP(Async)"); + "Missing the required parameter 'projectId' when calling v2beta1UpdateBackup(Async)"); } - // verify the required parameter 'publicIpId' is set - if (publicIpId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'publicIpId' when calling updatePublicIP(Async)"); + "Missing the required parameter 'region' when calling v2beta1UpdateBackup(Async)"); } - // verify the required parameter 'updatePublicIPPayload' is set - if (updatePublicIPPayload == null) { + // verify the required parameter 'backupId' is set + if (backupId == null) { throw new ApiException( - "Missing the required parameter 'updatePublicIPPayload' when calling updatePublicIP(Async)"); + "Missing the required parameter 'backupId' when calling v2beta1UpdateBackup(Async)"); } - return updatePublicIPCall(projectId, publicIpId, updatePublicIPPayload, _callback); + // verify the required parameter 'v2beta1UpdateBackupPayload' is set + if (v2beta1UpdateBackupPayload == null) { + throw new ApiException( + "Missing the required parameter 'v2beta1UpdateBackupPayload' when calling v2beta1UpdateBackup(Async)"); + } + + return v2beta1UpdateBackupCall( + projectId, region, backupId, v2beta1UpdateBackupPayload, _callback); } /** - * Update a public IP. Update the properties of an existing public IP inside a project. + * Update information of a backup. Update name or labels of the backup. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) - * @param updatePublicIPPayload Request an update of a public IP. (required) - * @return PublicIp + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param v2beta1UpdateBackupPayload Request an update of a backup. (required) + * @return Backup * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -23814,30 +30439,33 @@ private okhttp3.Call updatePublicIPValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Public IP has been updated. -
200 Backup has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public PublicIp updatePublicIP( + public Backup v2beta1UpdateBackup( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, - @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull V2beta1UpdateBackupPayload v2beta1UpdateBackupPayload) throws ApiException { - ApiResponse localVarResp = - updatePublicIPWithHttpInfo(projectId, publicIpId, updatePublicIPPayload); + ApiResponse localVarResp = + v2beta1UpdateBackupWithHttpInfo( + projectId, region, backupId, v2beta1UpdateBackupPayload); return localVarResp.getData(); } /** - * Update a public IP. Update the properties of an existing public IP inside a project. + * Update information of a backup. Update name or labels of the backup. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) - * @param updatePublicIPPayload Request an update of a public IP. (required) - * @return ApiResponse<PublicIp> + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param v2beta1UpdateBackupPayload Request an update of a backup. (required) + * @return ApiResponse<Backup> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -23845,25 +30473,26 @@ public PublicIp updatePublicIP( * *
Response Details
Status Code Description Response Headers
200 Public IP has been updated. -
200 Backup has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updatePublicIPWithHttpInfo( + public ApiResponse v2beta1UpdateBackupWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, - @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull V2beta1UpdateBackupPayload v2beta1UpdateBackupPayload) throws ApiException { okhttp3.Call localVarCall = - updatePublicIPValidateBeforeCall( - projectId, publicIpId, updatePublicIPPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateBackupValidateBeforeCall( + projectId, region, backupId, v2beta1UpdateBackupPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update a public IP. (asynchronously) Update the properties of an existing public IP inside a - * project. + * Update information of a backup. (asynchronously) Update name or labels of the backup. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param publicIpId The identifier (ID) of a Public IP. (required) - * @param updatePublicIPPayload Request an update of a public IP. (required) + * @param region The STACKIT Region of the resources. (required) + * @param backupId The identifier (ID) of a STACKIT Backup. (required) + * @param v2beta1UpdateBackupPayload Request an update of a backup. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -23872,7 +30501,7 @@ public ApiResponse updatePublicIPWithHttpInfo( * * * - * + * * * * @@ -23880,27 +30509,30 @@ public ApiResponse updatePublicIPWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Public IP has been updated. -
200 Backup has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updatePublicIPAsync( + public okhttp3.Call v2beta1UpdateBackupAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID publicIpId, - @javax.annotation.Nonnull UpdatePublicIPPayload updatePublicIPPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID backupId, + @javax.annotation.Nonnull V2beta1UpdateBackupPayload v2beta1UpdateBackupPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updatePublicIPValidateBeforeCall( - projectId, publicIpId, updatePublicIPPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateBackupValidateBeforeCall( + projectId, region, backupId, v2beta1UpdateBackupPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateSecurityGroup + * Build call for v2beta1UpdateNetworkAreaRegion * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param updateSecurityGroupPayload Request an update of a security group. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1UpdateNetworkAreaRegionPayload Request an update of a regional network area. + * (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -23908,18 +30540,21 @@ public okhttp3.Call updatePublicIPAsync( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Updating security group successful. -
200 Regional area has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateSecurityGroupCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UpdateSecurityGroupPayload updateSecurityGroupPayload, + public okhttp3.Call v2beta1UpdateNetworkAreaRegionCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1UpdateNetworkAreaRegionPayload v2beta1UpdateNetworkAreaRegionPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -23935,17 +30570,20 @@ public okhttp3.Call updateSecurityGroupCall( basePath = null; } - Object localVarPostBody = updateSecurityGroupPayload; + Object localVarPostBody = v2beta1UpdateNetworkAreaRegionPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "securityGroupId" + "}", - localVarApiClient.escapeString(securityGroupId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -23982,105 +30620,129 @@ public okhttp3.Call updateSecurityGroupCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateSecurityGroupValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UpdateSecurityGroupPayload updateSecurityGroupPayload, + private okhttp3.Call v2beta1UpdateNetworkAreaRegionValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1UpdateNetworkAreaRegionPayload v2beta1UpdateNetworkAreaRegionPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateSecurityGroup(Async)"); + "Missing the required parameter 'organizationId' when calling v2beta1UpdateNetworkAreaRegion(Async)"); } - // verify the required parameter 'securityGroupId' is set - if (securityGroupId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { + throw new ApiException( + "Missing the required parameter 'areaId' when calling v2beta1UpdateNetworkAreaRegion(Async)"); + } + + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'securityGroupId' when calling updateSecurityGroup(Async)"); + "Missing the required parameter 'region' when calling v2beta1UpdateNetworkAreaRegion(Async)"); } - // verify the required parameter 'updateSecurityGroupPayload' is set - if (updateSecurityGroupPayload == null) { + // verify the required parameter 'v2beta1UpdateNetworkAreaRegionPayload' is set + if (v2beta1UpdateNetworkAreaRegionPayload == null) { throw new ApiException( - "Missing the required parameter 'updateSecurityGroupPayload' when calling updateSecurityGroup(Async)"); + "Missing the required parameter 'v2beta1UpdateNetworkAreaRegionPayload' when calling v2beta1UpdateNetworkAreaRegion(Async)"); } - return updateSecurityGroupCall( - projectId, securityGroupId, updateSecurityGroupPayload, _callback); + return v2beta1UpdateNetworkAreaRegionCall( + organizationId, areaId, region, v2beta1UpdateNetworkAreaRegionPayload, _callback); } /** - * Update information of a security group. Update labels of the security group. + * Update a region for a network area. Update a new region for a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param updateSecurityGroupPayload Request an update of a security group. (required) - * @return SecurityGroup + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1UpdateNetworkAreaRegionPayload Request an update of a regional network area. + * (required) + * @return RegionalArea * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Updating security group successful. -
200 Regional area has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public SecurityGroup updateSecurityGroup( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UpdateSecurityGroupPayload updateSecurityGroupPayload) + public RegionalArea v2beta1UpdateNetworkAreaRegion( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1UpdateNetworkAreaRegionPayload v2beta1UpdateNetworkAreaRegionPayload) throws ApiException { - ApiResponse localVarResp = - updateSecurityGroupWithHttpInfo( - projectId, securityGroupId, updateSecurityGroupPayload); + ApiResponse localVarResp = + v2beta1UpdateNetworkAreaRegionWithHttpInfo( + organizationId, areaId, region, v2beta1UpdateNetworkAreaRegionPayload); return localVarResp.getData(); } /** - * Update information of a security group. Update labels of the security group. + * Update a region for a network area. Update a new region for a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param updateSecurityGroupPayload Request an update of a security group. (required) - * @return ApiResponse<SecurityGroup> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1UpdateNetworkAreaRegionPayload Request an update of a regional network area. + * (required) + * @return ApiResponse<RegionalArea> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Updating security group successful. -
200 Regional area has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateSecurityGroupWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UpdateSecurityGroupPayload updateSecurityGroupPayload) + public ApiResponse v2beta1UpdateNetworkAreaRegionWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1UpdateNetworkAreaRegionPayload v2beta1UpdateNetworkAreaRegionPayload) throws ApiException { okhttp3.Call localVarCall = - updateSecurityGroupValidateBeforeCall( - projectId, securityGroupId, updateSecurityGroupPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateNetworkAreaRegionValidateBeforeCall( + organizationId, + areaId, + region, + v2beta1UpdateNetworkAreaRegionPayload, + null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update information of a security group. (asynchronously) Update labels of the security group. + * Update a region for a network area. (asynchronously) Update a new region for a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) - * @param updateSecurityGroupPayload Request an update of a security group. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param v2beta1UpdateNetworkAreaRegionPayload Request an update of a regional network area. + * (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -24089,35 +30751,44 @@ public ApiResponse updateSecurityGroupWithHttpInfo( * * * - * + * * * * * + * * *
Response Details
Status Code Description Response Headers
200 Updating security group successful. -
200 Regional area has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
409 A conflict has occurred. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateSecurityGroupAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID securityGroupId, - @javax.annotation.Nonnull UpdateSecurityGroupPayload updateSecurityGroupPayload, - final ApiCallback _callback) + public okhttp3.Call v2beta1UpdateNetworkAreaRegionAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2beta1UpdateNetworkAreaRegionPayload v2beta1UpdateNetworkAreaRegionPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateSecurityGroupValidateBeforeCall( - projectId, securityGroupId, updateSecurityGroupPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateNetworkAreaRegionValidateBeforeCall( + organizationId, + areaId, + region, + v2beta1UpdateNetworkAreaRegionPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateServer + * Build call for v2beta1UpdateRouteOfArea * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param updateServerPayload Request an update of a server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param v2beta1UpdateRouteOfAreaPayload Request an update of a network route. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -24125,18 +30796,21 @@ public okhttp3.Call updateSecurityGroupAsync( * * * - * + * * * * * * - *
Response Details
Status Code Description Response Headers
200 Server has been updated. -
200 Update request for network successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
404 The object was not found. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
- */ - public okhttp3.Call updateServerCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UpdateServerPayload updateServerPayload, + * + */ + public okhttp3.Call v2beta1UpdateRouteOfAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + V2beta1UpdateRouteOfAreaPayload v2beta1UpdateRouteOfAreaPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -24152,17 +30826,23 @@ public okhttp3.Call updateServerCall( basePath = null; } - Object localVarPostBody = updateServerPayload; + Object localVarPostBody = v2beta1UpdateRouteOfAreaPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}" + "/v2beta1/organizations/{organizationId}/network-areas/{areaId}/regions/{region}/routes/{routeId}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())) .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "areaId" + "}", + localVarApiClient.escapeString(areaId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "routeId" + "}", + localVarApiClient.escapeString(routeId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -24199,47 +30879,70 @@ public okhttp3.Call updateServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateServerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UpdateServerPayload updateServerPayload, + private okhttp3.Call v2beta1UpdateRouteOfAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + V2beta1UpdateRouteOfAreaPayload v2beta1UpdateRouteOfAreaPayload, final ApiCallback _callback) throws ApiException { - // verify the required parameter 'projectId' is set - if (projectId == null) { + // verify the required parameter 'organizationId' is set + if (organizationId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateServer(Async)"); + "Missing the required parameter 'organizationId' when calling v2beta1UpdateRouteOfArea(Async)"); } - // verify the required parameter 'serverId' is set - if (serverId == null) { + // verify the required parameter 'areaId' is set + if (areaId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling updateServer(Async)"); + "Missing the required parameter 'areaId' when calling v2beta1UpdateRouteOfArea(Async)"); } - // verify the required parameter 'updateServerPayload' is set - if (updateServerPayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'updateServerPayload' when calling updateServer(Async)"); + "Missing the required parameter 'region' when calling v2beta1UpdateRouteOfArea(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { + throw new ApiException( + "Missing the required parameter 'routeId' when calling v2beta1UpdateRouteOfArea(Async)"); + } + + // verify the required parameter 'v2beta1UpdateRouteOfAreaPayload' is set + if (v2beta1UpdateRouteOfAreaPayload == null) { + throw new ApiException( + "Missing the required parameter 'v2beta1UpdateRouteOfAreaPayload' when calling v2beta1UpdateRouteOfArea(Async)"); } - return updateServerCall(projectId, serverId, updateServerPayload, _callback); + return v2beta1UpdateRouteOfAreaCall( + organizationId, + areaId, + region, + routeId, + v2beta1UpdateRouteOfAreaPayload, + _callback); } /** - * Update information of a server. Update name or labels of the server. + * Update a network route. Update a network route defined in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param updateServerPayload Request an update of a server. (required) - * @return Server + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param v2beta1UpdateRouteOfAreaPayload Request an update of a network route. (required) + * @return Route * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -24247,30 +30950,36 @@ private okhttp3.Call updateServerValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Server has been updated. -
200 Update request for network successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Server updateServer( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UpdateServerPayload updateServerPayload) + public Route v2beta1UpdateRouteOfArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + V2beta1UpdateRouteOfAreaPayload v2beta1UpdateRouteOfAreaPayload) throws ApiException { - ApiResponse localVarResp = - updateServerWithHttpInfo(projectId, serverId, updateServerPayload); + ApiResponse localVarResp = + v2beta1UpdateRouteOfAreaWithHttpInfo( + organizationId, areaId, region, routeId, v2beta1UpdateRouteOfAreaPayload); return localVarResp.getData(); } /** - * Update information of a server. Update name or labels of the server. + * Update a network route. Update a network route defined in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param updateServerPayload Request an update of a server. (required) - * @return ApiResponse<Server> + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param v2beta1UpdateRouteOfAreaPayload Request an update of a network route. (required) + * @return ApiResponse<Route> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -24278,23 +30987,34 @@ public Server updateServer( * *
Response Details
Status Code Description Response Headers
200 Server has been updated. -
200 Update request for network successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateServerWithHttpInfo( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UpdateServerPayload updateServerPayload) + public ApiResponse v2beta1UpdateRouteOfAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + V2beta1UpdateRouteOfAreaPayload v2beta1UpdateRouteOfAreaPayload) throws ApiException { okhttp3.Call localVarCall = - updateServerValidateBeforeCall(projectId, serverId, updateServerPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateRouteOfAreaValidateBeforeCall( + organizationId, + areaId, + region, + routeId, + v2beta1UpdateRouteOfAreaPayload, + null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update information of a server. (asynchronously) Update name or labels of the server. + * Update a network route. (asynchronously) Update a network route defined in a network area. * - * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param serverId The identifier (ID) of a STACKIT Server. (required) - * @param updateServerPayload Request an update of a server. (required) + * @param organizationId The identifier (ID) of a STACKIT Organization. (required) + * @param areaId The identifier (ID) of a STACKIT Network Area. (required) + * @param region The STACKIT Region of the resources. (required) + * @param routeId The identifier (ID) of a STACKIT Route. (required) + * @param v2beta1UpdateRouteOfAreaPayload Request an update of a network route. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -24303,7 +31023,7 @@ public ApiResponse updateServerWithHttpInfo( * * * - * + * * * * @@ -24311,26 +31031,36 @@ public ApiResponse updateServerWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Server has been updated. -
200 Update request for network successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateServerAsync( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, - @javax.annotation.Nonnull UpdateServerPayload updateServerPayload, - final ApiCallback _callback) + public okhttp3.Call v2beta1UpdateRouteOfAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull + V2beta1UpdateRouteOfAreaPayload v2beta1UpdateRouteOfAreaPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateServerValidateBeforeCall(projectId, serverId, updateServerPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateRouteOfAreaValidateBeforeCall( + organizationId, + areaId, + region, + routeId, + v2beta1UpdateRouteOfAreaPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateSnapshot + * Build call for v2beta1UpdateSecurityGroup * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) - * @param updateSnapshotPayload Request an update of a snapshot. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param v2beta1UpdateSecurityGroupPayload Request an update of a security group. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -24338,7 +31068,7 @@ public okhttp3.Call updateServerAsync( * * * - * + * * * * @@ -24346,10 +31076,12 @@ public okhttp3.Call updateServerAsync( * *
Response Details
Status Code Description Response Headers
200 Snapshot has been updated. -
200 Updating security group successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateSnapshotCall( + public okhttp3.Call v2beta1UpdateSecurityGroupCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, - @javax.annotation.Nonnull UpdateSnapshotPayload updateSnapshotPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull + V2beta1UpdateSecurityGroupPayload v2beta1UpdateSecurityGroupPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -24365,17 +31097,20 @@ public okhttp3.Call updateSnapshotCall( basePath = null; } - Object localVarPostBody = updateSnapshotPayload; + Object localVarPostBody = v2beta1UpdateSecurityGroupPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots/{snapshotId}" + "/v2beta1/projects/{projectId}/regions/{region}/security-groups/{securityGroupId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "snapshotId" + "}", - localVarApiClient.escapeString(snapshotId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "securityGroupId" + "}", + localVarApiClient.escapeString(securityGroupId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -24412,47 +31147,57 @@ public okhttp3.Call updateSnapshotCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateSnapshotValidateBeforeCall( + private okhttp3.Call v2beta1UpdateSecurityGroupValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, - @javax.annotation.Nonnull UpdateSnapshotPayload updateSnapshotPayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull + V2beta1UpdateSecurityGroupPayload v2beta1UpdateSecurityGroupPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateSnapshot(Async)"); + "Missing the required parameter 'projectId' when calling v2beta1UpdateSecurityGroup(Async)"); } - // verify the required parameter 'snapshotId' is set - if (snapshotId == null) { + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling v2beta1UpdateSecurityGroup(Async)"); + } + + // verify the required parameter 'securityGroupId' is set + if (securityGroupId == null) { throw new ApiException( - "Missing the required parameter 'snapshotId' when calling updateSnapshot(Async)"); + "Missing the required parameter 'securityGroupId' when calling v2beta1UpdateSecurityGroup(Async)"); } - // verify the required parameter 'updateSnapshotPayload' is set - if (updateSnapshotPayload == null) { + // verify the required parameter 'v2beta1UpdateSecurityGroupPayload' is set + if (v2beta1UpdateSecurityGroupPayload == null) { throw new ApiException( - "Missing the required parameter 'updateSnapshotPayload' when calling updateSnapshot(Async)"); + "Missing the required parameter 'v2beta1UpdateSecurityGroupPayload' when calling v2beta1UpdateSecurityGroup(Async)"); } - return updateSnapshotCall(projectId, snapshotId, updateSnapshotPayload, _callback); + return v2beta1UpdateSecurityGroupCall( + projectId, region, securityGroupId, v2beta1UpdateSecurityGroupPayload, _callback); } /** - * Update information of the snapshot. Update information like name or labels of the snapshot. + * Update information of a security group. Update labels of the security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) - * @param updateSnapshotPayload Request an update of a snapshot. (required) - * @return Snapshot + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param v2beta1UpdateSecurityGroupPayload Request an update of a security group. (required) + * @return SecurityGroup * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -24460,30 +31205,34 @@ private okhttp3.Call updateSnapshotValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Snapshot has been updated. -
200 Updating security group successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Snapshot updateSnapshot( + public SecurityGroup v2beta1UpdateSecurityGroup( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, - @javax.annotation.Nonnull UpdateSnapshotPayload updateSnapshotPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull + V2beta1UpdateSecurityGroupPayload v2beta1UpdateSecurityGroupPayload) throws ApiException { - ApiResponse localVarResp = - updateSnapshotWithHttpInfo(projectId, snapshotId, updateSnapshotPayload); + ApiResponse localVarResp = + v2beta1UpdateSecurityGroupWithHttpInfo( + projectId, region, securityGroupId, v2beta1UpdateSecurityGroupPayload); return localVarResp.getData(); } /** - * Update information of the snapshot. Update information like name or labels of the snapshot. + * Update information of a security group. Update labels of the security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) - * @param updateSnapshotPayload Request an update of a snapshot. (required) - * @return ApiResponse<Snapshot> + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param v2beta1UpdateSecurityGroupPayload Request an update of a security group. (required) + * @return ApiResponse<SecurityGroup> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -24491,25 +31240,31 @@ public Snapshot updateSnapshot( * *
Response Details
Status Code Description Response Headers
200 Snapshot has been updated. -
200 Updating security group successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateSnapshotWithHttpInfo( + public ApiResponse v2beta1UpdateSecurityGroupWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, - @javax.annotation.Nonnull UpdateSnapshotPayload updateSnapshotPayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull + V2beta1UpdateSecurityGroupPayload v2beta1UpdateSecurityGroupPayload) throws ApiException { okhttp3.Call localVarCall = - updateSnapshotValidateBeforeCall( - projectId, snapshotId, updateSnapshotPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateSecurityGroupValidateBeforeCall( + projectId, + region, + securityGroupId, + v2beta1UpdateSecurityGroupPayload, + null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update information of the snapshot. (asynchronously) Update information like name or labels - * of the snapshot. + * Update information of a security group. (asynchronously) Update labels of the security group. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) - * @param updateSnapshotPayload Request an update of a snapshot. (required) + * @param region The STACKIT Region of the resources. (required) + * @param securityGroupId The identifier (ID) of a STACKIT Security Group. (required) + * @param v2beta1UpdateSecurityGroupPayload Request an update of a security group. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -24518,7 +31273,7 @@ public ApiResponse updateSnapshotWithHttpInfo( * * * - * + * * * * @@ -24526,27 +31281,34 @@ public ApiResponse updateSnapshotWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Snapshot has been updated. -
200 Updating security group successful. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateSnapshotAsync( + public okhttp3.Call v2beta1UpdateSecurityGroupAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID snapshotId, - @javax.annotation.Nonnull UpdateSnapshotPayload updateSnapshotPayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID securityGroupId, + @javax.annotation.Nonnull + V2beta1UpdateSecurityGroupPayload v2beta1UpdateSecurityGroupPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateSnapshotValidateBeforeCall( - projectId, snapshotId, updateSnapshotPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateSecurityGroupValidateBeforeCall( + projectId, + region, + securityGroupId, + v2beta1UpdateSecurityGroupPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateVolume + * Build call for v2beta1UpdateSnapshot * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param updateVolumePayload Request an update of a volume. (required) + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param v2beta1UpdateSnapshotPayload Request an update of a snapshot. (required) * @param _callback Callback for upload/download progress * @return Call to execute * @throws ApiException If fail to serialize the request body object @@ -24554,7 +31316,7 @@ public okhttp3.Call updateSnapshotAsync( * * * - * + * * * * @@ -24562,10 +31324,11 @@ public okhttp3.Call updateSnapshotAsync( * *
Response Details
Status Code Description Response Headers
200 Volume has been updated. -
200 Snapshot has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateVolumeCall( + public okhttp3.Call v2beta1UpdateSnapshotCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, + @javax.annotation.Nonnull V2beta1UpdateSnapshotPayload v2beta1UpdateSnapshotPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -24581,17 +31344,20 @@ public okhttp3.Call updateVolumeCall( basePath = null; } - Object localVarPostBody = updateVolumePayload; + Object localVarPostBody = v2beta1UpdateSnapshotPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes/{volumeId}" + "/v2beta1/projects/{projectId}/regions/{region}/snapshots/{snapshotId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) .replace( - "{" + "volumeId" + "}", - localVarApiClient.escapeString(volumeId.toString())); + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) + .replace( + "{" + "snapshotId" + "}", + localVarApiClient.escapeString(snapshotId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -24628,47 +31394,56 @@ public okhttp3.Call updateVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateVolumeValidateBeforeCall( + private okhttp3.Call v2beta1UpdateSnapshotValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, + @javax.annotation.Nonnull V2beta1UpdateSnapshotPayload v2beta1UpdateSnapshotPayload, final ApiCallback _callback) throws ApiException { // verify the required parameter 'projectId' is set if (projectId == null) { throw new ApiException( - "Missing the required parameter 'projectId' when calling updateVolume(Async)"); + "Missing the required parameter 'projectId' when calling v2beta1UpdateSnapshot(Async)"); } - // verify the required parameter 'volumeId' is set - if (volumeId == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'volumeId' when calling updateVolume(Async)"); + "Missing the required parameter 'region' when calling v2beta1UpdateSnapshot(Async)"); } - // verify the required parameter 'updateVolumePayload' is set - if (updateVolumePayload == null) { + // verify the required parameter 'snapshotId' is set + if (snapshotId == null) { throw new ApiException( - "Missing the required parameter 'updateVolumePayload' when calling updateVolume(Async)"); + "Missing the required parameter 'snapshotId' when calling v2beta1UpdateSnapshot(Async)"); + } + + // verify the required parameter 'v2beta1UpdateSnapshotPayload' is set + if (v2beta1UpdateSnapshotPayload == null) { + throw new ApiException( + "Missing the required parameter 'v2beta1UpdateSnapshotPayload' when calling v2beta1UpdateSnapshot(Async)"); } - return updateVolumeCall(projectId, volumeId, updateVolumePayload, _callback); + return v2beta1UpdateSnapshotCall( + projectId, region, snapshotId, v2beta1UpdateSnapshotPayload, _callback); } /** - * Update information of a volume. Update name, description or labels of the volume. + * Update information of the snapshot. Update information like name or labels of the snapshot. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param updateVolumePayload Request an update of a volume. (required) - * @return Volume + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param v2beta1UpdateSnapshotPayload Request an update of a snapshot. (required) + * @return Snapshot * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -24676,30 +31451,33 @@ private okhttp3.Call updateVolumeValidateBeforeCall( * *
Response Details
Status Code Description Response Headers
200 Volume has been updated. -
200 Snapshot has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public Volume updateVolume( + public Snapshot v2beta1UpdateSnapshot( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, + @javax.annotation.Nonnull V2beta1UpdateSnapshotPayload v2beta1UpdateSnapshotPayload) throws ApiException { - ApiResponse localVarResp = - updateVolumeWithHttpInfo(projectId, volumeId, updateVolumePayload); + ApiResponse localVarResp = + v2beta1UpdateSnapshotWithHttpInfo( + projectId, region, snapshotId, v2beta1UpdateSnapshotPayload); return localVarResp.getData(); } /** - * Update information of a volume. Update name, description or labels of the volume. + * Update information of the snapshot. Update information like name or labels of the snapshot. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param updateVolumePayload Request an update of a volume. (required) - * @return ApiResponse<Volume> + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param v2beta1UpdateSnapshotPayload Request an update of a snapshot. (required) + * @return ApiResponse<Snapshot> * @throws ApiException If fail to call the API, e.g. server error or cannot deserialize the * response body * @http.response.details * * * - * + * * * * @@ -24707,24 +31485,27 @@ public Volume updateVolume( * *
Response Details
Status Code Description Response Headers
200 Volume has been updated. -
200 Snapshot has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public ApiResponse updateVolumeWithHttpInfo( + public ApiResponse v2beta1UpdateSnapshotWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, + @javax.annotation.Nonnull V2beta1UpdateSnapshotPayload v2beta1UpdateSnapshotPayload) throws ApiException { okhttp3.Call localVarCall = - updateVolumeValidateBeforeCall(projectId, volumeId, updateVolumePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateSnapshotValidateBeforeCall( + projectId, region, snapshotId, v2beta1UpdateSnapshotPayload, null); + Type localVarReturnType = new TypeToken() {}.getType(); return localVarApiClient.execute(localVarCall, localVarReturnType); } /** - * Update information of a volume. (asynchronously) Update name, description or labels of the - * volume. + * Update information of the snapshot. (asynchronously) Update information like name or labels + * of the snapshot. * * @param projectId The identifier (ID) of a STACKIT Project. (required) - * @param volumeId The identifier (ID) of a STACKIT Volume. (required) - * @param updateVolumePayload Request an update of a volume. (required) + * @param region The STACKIT Region of the resources. (required) + * @param snapshotId The identifier (ID) of a STACKIT Snapshot. (required) + * @param v2beta1UpdateSnapshotPayload Request an update of a snapshot. (required) * @param _callback The callback to be executed when the API call finishes * @return The request call * @throws ApiException If fail to process the API call, e.g. serializing the request body @@ -24733,7 +31514,7 @@ public ApiResponse updateVolumeWithHttpInfo( * * * - * + * * * * @@ -24741,16 +31522,18 @@ public ApiResponse updateVolumeWithHttpInfo( * *
Response Details
Status Code Description Response Headers
200 Volume has been updated. -
200 Snapshot has been updated. -
400 A bad request. -
401 A request which was not authorized. -
403 A request which was forbidden. -
500 Internal Server Error, returns a 500 if something is broken on IaaS API Side. -
*/ - public okhttp3.Call updateVolumeAsync( + public okhttp3.Call v2beta1UpdateSnapshotAsync( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID volumeId, - @javax.annotation.Nonnull UpdateVolumePayload updateVolumePayload, - final ApiCallback _callback) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, + @javax.annotation.Nonnull V2beta1UpdateSnapshotPayload v2beta1UpdateSnapshotPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateVolumeValidateBeforeCall(projectId, volumeId, updateVolumePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2beta1UpdateSnapshotValidateBeforeCall( + projectId, region, snapshotId, v2beta1UpdateSnapshotPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AbstractOpenApiSchema.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AbstractOpenApiSchema.java index f24c23e..0d82bc7 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AbstractOpenApiSchema.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AbstractOpenApiSchema.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutesToRoutingTablePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutesToRoutingTablePayload.java new file mode 100644 index 0000000..81ec202 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutesToRoutingTablePayload.java @@ -0,0 +1,232 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonArray; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object represents a request to add network routes. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class AddRoutesToRoutingTablePayload { + public static final String SERIALIZED_NAME_ITEMS = "items"; + + @SerializedName(SERIALIZED_NAME_ITEMS) + @javax.annotation.Nonnull + private List items = new ArrayList<>(); + + public AddRoutesToRoutingTablePayload() {} + + public AddRoutesToRoutingTablePayload items(@javax.annotation.Nonnull List items) { + this.items = items; + return this; + } + + public AddRoutesToRoutingTablePayload addItemsItem(Route itemsItem) { + if (this.items == null) { + this.items = new ArrayList<>(); + } + this.items.add(itemsItem); + return this; + } + + /** + * A list of routes. + * + * @return items + */ + @javax.annotation.Nonnull + public List getItems() { + return items; + } + + public void setItems(@javax.annotation.Nonnull List items) { + this.items = items; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AddRoutesToRoutingTablePayload addRoutesToRoutingTablePayload = + (AddRoutesToRoutingTablePayload) o; + return Objects.equals(this.items, addRoutesToRoutingTablePayload.items); + } + + @Override + public int hashCode() { + return Objects.hash(items); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AddRoutesToRoutingTablePayload {\n"); + sb.append(" items: ").append(toIndentedString(items)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("items")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("items")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * AddRoutesToRoutingTablePayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!AddRoutesToRoutingTablePayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in AddRoutesToRoutingTablePayload is not found in the empty JSON string", + AddRoutesToRoutingTablePayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!AddRoutesToRoutingTablePayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `AddRoutesToRoutingTablePayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : AddRoutesToRoutingTablePayload.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the json data is an array + if (!jsonObj.get("items").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `items` to be an array in the JSON string but got `%s`", + jsonObj.get("items").toString())); + } + + JsonArray jsonArrayitems = jsonObj.getAsJsonArray("items"); + // validate the required field `items` (array) + for (int i = 0; i < jsonArrayitems.size(); i++) { + Route.validateJsonElement(jsonArrayitems.get(i)); + } + ; + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!AddRoutesToRoutingTablePayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'AddRoutesToRoutingTablePayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(AddRoutesToRoutingTablePayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, AddRoutesToRoutingTablePayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public AddRoutesToRoutingTablePayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of AddRoutesToRoutingTablePayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of AddRoutesToRoutingTablePayload + * @throws IOException if the JSON string is invalid with respect to + * AddRoutesToRoutingTablePayload + */ + public static AddRoutesToRoutingTablePayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, AddRoutesToRoutingTablePayload.class); + } + + /** + * Convert an instance of AddRoutesToRoutingTablePayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutingTableToAreaPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutingTableToAreaPayload.java new file mode 100644 index 0000000..b103aa5 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutingTableToAreaPayload.java @@ -0,0 +1,392 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.time.OffsetDateTime; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import java.util.UUID; + +/** An object representing a routing table. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class AddRoutingTableToAreaPayload { + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + + @SerializedName(SERIALIZED_NAME_CREATED_AT) + @javax.annotation.Nullable private OffsetDateTime createdAt; + + public static final String SERIALIZED_NAME_DEFAULT = "default"; + + @SerializedName(SERIALIZED_NAME_DEFAULT) + @javax.annotation.Nullable private Boolean _default = true; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + @javax.annotation.Nullable private String description; + + public static final String SERIALIZED_NAME_ID = "id"; + + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nullable private UUID id; + + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public static final String SERIALIZED_NAME_NAME = "name"; + + @SerializedName(SERIALIZED_NAME_NAME) + @javax.annotation.Nonnull + private String name; + + public static final String SERIALIZED_NAME_SYSTEM_ROUTES = "systemRoutes"; + + @SerializedName(SERIALIZED_NAME_SYSTEM_ROUTES) + @javax.annotation.Nullable private Boolean systemRoutes = true; + + public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; + + @SerializedName(SERIALIZED_NAME_UPDATED_AT) + @javax.annotation.Nullable private OffsetDateTime updatedAt; + + public AddRoutingTableToAreaPayload() {} + + public AddRoutingTableToAreaPayload( + OffsetDateTime createdAt, Boolean _default, UUID id, OffsetDateTime updatedAt) { + this(); + this.createdAt = createdAt; + this._default = _default; + this.id = id; + this.updatedAt = updatedAt; + } + + /** + * Date-time when resource was created. + * + * @return createdAt + */ + @javax.annotation.Nullable public OffsetDateTime getCreatedAt() { + return createdAt; + } + + /** + * This is the default routing table. It can't be deleted and is used if the user does not + * specify it otherwise. + * + * @return _default + */ + @javax.annotation.Nullable public Boolean getDefault() { + return _default; + } + + public AddRoutingTableToAreaPayload description(@javax.annotation.Nullable String description) { + this.description = description; + return this; + } + + /** + * Description Object. Allows string up to 255 Characters. + * + * @return description + */ + @javax.annotation.Nullable public String getDescription() { + return description; + } + + public void setDescription(@javax.annotation.Nullable String description) { + this.description = description; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return id + */ + @javax.annotation.Nullable public UUID getId() { + return id; + } + + public AddRoutingTableToAreaPayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + public AddRoutingTableToAreaPayload name(@javax.annotation.Nonnull String name) { + this.name = name; + return this; + } + + /** + * The name for a General Object. Matches Names and also UUIDs. + * + * @return name + */ + @javax.annotation.Nonnull + public String getName() { + return name; + } + + public void setName(@javax.annotation.Nonnull String name) { + this.name = name; + } + + public AddRoutingTableToAreaPayload systemRoutes( + @javax.annotation.Nullable Boolean systemRoutes) { + this.systemRoutes = systemRoutes; + return this; + } + + /** + * Get systemRoutes + * + * @return systemRoutes + */ + @javax.annotation.Nullable public Boolean getSystemRoutes() { + return systemRoutes; + } + + public void setSystemRoutes(@javax.annotation.Nullable Boolean systemRoutes) { + this.systemRoutes = systemRoutes; + } + + /** + * Date-time when resource was last updated. + * + * @return updatedAt + */ + @javax.annotation.Nullable public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + AddRoutingTableToAreaPayload addRoutingTableToAreaPayload = + (AddRoutingTableToAreaPayload) o; + return Objects.equals(this.createdAt, addRoutingTableToAreaPayload.createdAt) + && Objects.equals(this._default, addRoutingTableToAreaPayload._default) + && Objects.equals(this.description, addRoutingTableToAreaPayload.description) + && Objects.equals(this.id, addRoutingTableToAreaPayload.id) + && Objects.equals(this.labels, addRoutingTableToAreaPayload.labels) + && Objects.equals(this.name, addRoutingTableToAreaPayload.name) + && Objects.equals(this.systemRoutes, addRoutingTableToAreaPayload.systemRoutes) + && Objects.equals(this.updatedAt, addRoutingTableToAreaPayload.updatedAt); + } + + @Override + public int hashCode() { + return Objects.hash( + createdAt, _default, description, id, labels, name, systemRoutes, updatedAt); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class AddRoutingTableToAreaPayload {\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" _default: ").append(toIndentedString(_default)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" systemRoutes: ").append(toIndentedString(systemRoutes)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = + new HashSet( + Arrays.asList( + "createdAt", + "default", + "description", + "id", + "labels", + "name", + "systemRoutes", + "updatedAt")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("name")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * AddRoutingTableToAreaPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!AddRoutingTableToAreaPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in AddRoutingTableToAreaPayload is not found in the empty JSON string", + AddRoutingTableToAreaPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!AddRoutingTableToAreaPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `AddRoutingTableToAreaPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : AddRoutingTableToAreaPayload.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) + && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `description` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("description").toString())); + } + if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) + && !jsonObj.get("id").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); + } + if (!jsonObj.get("name").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `name` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("name").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!AddRoutingTableToAreaPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'AddRoutingTableToAreaPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(AddRoutingTableToAreaPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, AddRoutingTableToAreaPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public AddRoutingTableToAreaPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of AddRoutingTableToAreaPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of AddRoutingTableToAreaPayload + * @throws IOException if the JSON string is invalid with respect to + * AddRoutingTableToAreaPayload + */ + public static AddRoutingTableToAreaPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, AddRoutingTableToAreaPayload.class); + } + + /** + * Convert an instance of AddRoutingTableToAreaPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddVolumeToServerPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddVolumeToServerPayload.java index e070bec..531cfb0 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddVolumeToServerPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddVolumeToServerPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AffinityGroup.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AffinityGroup.java index 8dfea6a..9479c2d 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AffinityGroup.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AffinityGroup.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AffinityGroupListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AffinityGroupListResponse.java index 874bb38..1fa715e 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AffinityGroupListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AffinityGroupListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AllowedAddressesInner.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AllowedAddressesInner.java index 6f11142..1eb39ff 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AllowedAddressesInner.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AllowedAddressesInner.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AreaId.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AreaId.java index 51dd31d..ca6c0f9 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AreaId.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AreaId.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AvailabilityZoneListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AvailabilityZoneListResponse.java index 0d5586f..2a1ffe6 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AvailabilityZoneListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AvailabilityZoneListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Backup.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Backup.java index 7e43613..d05e1da 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Backup.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Backup.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -142,9 +142,9 @@ public Backup labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupListResponse.java index 4ec0e37..6f040d6 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupSource.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupSource.java index 05a5d9c..4c5516a 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupSource.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupSource.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BaseSecurityGroupRule.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BaseSecurityGroupRule.java index af9fd7b..87820b2 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BaseSecurityGroupRule.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BaseSecurityGroupRule.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -23,6 +23,7 @@ import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import java.io.IOException; +import java.time.OffsetDateTime; import java.util.Arrays; import java.util.HashSet; import java.util.Map; @@ -35,6 +36,11 @@ value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class BaseSecurityGroupRule { + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + + @SerializedName(SERIALIZED_NAME_CREATED_AT) + @javax.annotation.Nullable private OffsetDateTime createdAt; + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; @SerializedName(SERIALIZED_NAME_DESCRIPTION) @@ -81,12 +87,29 @@ public class BaseSecurityGroupRule { @SerializedName(SERIALIZED_NAME_SECURITY_GROUP_ID) @javax.annotation.Nullable private UUID securityGroupId; + public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; + + @SerializedName(SERIALIZED_NAME_UPDATED_AT) + @javax.annotation.Nullable private OffsetDateTime updatedAt; + public BaseSecurityGroupRule() {} - public BaseSecurityGroupRule(UUID id, UUID securityGroupId) { + public BaseSecurityGroupRule( + OffsetDateTime createdAt, UUID id, UUID securityGroupId, OffsetDateTime updatedAt) { this(); + this.createdAt = createdAt; this.id = id; this.securityGroupId = securityGroupId; + this.updatedAt = updatedAt; + } + + /** + * Date-time when resource was created. + * + * @return createdAt + */ + @javax.annotation.Nullable public OffsetDateTime getCreatedAt() { + return createdAt; } public BaseSecurityGroupRule description(@javax.annotation.Nullable String description) { @@ -238,6 +261,15 @@ public void setRemoteSecurityGroupId(@javax.annotation.Nullable UUID remoteSecur return securityGroupId; } + /** + * Date-time when resource was last updated. + * + * @return updatedAt + */ + @javax.annotation.Nullable public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + @Override public boolean equals(Object o) { if (this == o) { @@ -247,7 +279,8 @@ public boolean equals(Object o) { return false; } BaseSecurityGroupRule baseSecurityGroupRule = (BaseSecurityGroupRule) o; - return Objects.equals(this.description, baseSecurityGroupRule.description) + return Objects.equals(this.createdAt, baseSecurityGroupRule.createdAt) + && Objects.equals(this.description, baseSecurityGroupRule.description) && Objects.equals(this.direction, baseSecurityGroupRule.direction) && Objects.equals(this.ethertype, baseSecurityGroupRule.ethertype) && Objects.equals(this.icmpParameters, baseSecurityGroupRule.icmpParameters) @@ -256,12 +289,14 @@ public boolean equals(Object o) { && Objects.equals(this.portRange, baseSecurityGroupRule.portRange) && Objects.equals( this.remoteSecurityGroupId, baseSecurityGroupRule.remoteSecurityGroupId) - && Objects.equals(this.securityGroupId, baseSecurityGroupRule.securityGroupId); + && Objects.equals(this.securityGroupId, baseSecurityGroupRule.securityGroupId) + && Objects.equals(this.updatedAt, baseSecurityGroupRule.updatedAt); } @Override public int hashCode() { return Objects.hash( + createdAt, description, direction, ethertype, @@ -270,13 +305,15 @@ public int hashCode() { ipRange, portRange, remoteSecurityGroupId, - securityGroupId); + securityGroupId, + updatedAt); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class BaseSecurityGroupRule {\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" direction: ").append(toIndentedString(direction)).append("\n"); sb.append(" ethertype: ").append(toIndentedString(ethertype)).append("\n"); @@ -288,6 +325,7 @@ public String toString() { .append(toIndentedString(remoteSecurityGroupId)) .append("\n"); sb.append(" securityGroupId: ").append(toIndentedString(securityGroupId)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append("}"); return sb.toString(); } @@ -311,6 +349,7 @@ private String toIndentedString(Object o) { openapiFields = new HashSet( Arrays.asList( + "createdAt", "description", "direction", "ethertype", @@ -319,7 +358,8 @@ private String toIndentedString(Object o) { "ipRange", "portRange", "remoteSecurityGroupId", - "securityGroupId")); + "securityGroupId", + "updatedAt")); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(Arrays.asList("direction")); diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolume.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolume.java index 6da5095..670339b 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolume.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolume.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolumeSource.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolumeSource.java index ddd332d..36877a0 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolumeSource.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolumeSource.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateAffinityGroupPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateAffinityGroupPayload.java index 8c5d254..db48094 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateAffinityGroupPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateAffinityGroupPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateBackupPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateBackupPayload.java index 14de2d1..0a40d49 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateBackupPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateBackupPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -59,9 +59,9 @@ public CreateBackupPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateImagePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateImagePayload.java index be293f5..fcaf5f5 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateImagePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateImagePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -232,9 +232,9 @@ public CreateImagePayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateKeyPairPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateKeyPairPayload.java index d31476a..1428399 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateKeyPairPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateKeyPairPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -101,9 +101,9 @@ public CreateKeyPairPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkPayload.java new file mode 100644 index 0000000..2e71f53 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkPayload.java @@ -0,0 +1,247 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents the request body for a mgmt network create. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateManagementNetworkPayload { + public static final String SERIALIZED_NAME_IPV6_ASSIGNMENT = "ipv6Assignment"; + + @SerializedName(SERIALIZED_NAME_IPV6_ASSIGNMENT) + @javax.annotation.Nullable private String ipv6Assignment; + + public static final String SERIALIZED_NAME_NAME = "name"; + + @SerializedName(SERIALIZED_NAME_NAME) + @javax.annotation.Nonnull + private String name; + + public CreateManagementNetworkPayload() {} + + public CreateManagementNetworkPayload ipv6Assignment( + @javax.annotation.Nullable String ipv6Assignment) { + this.ipv6Assignment = ipv6Assignment; + return this; + } + + /** + * IPv6 assignment method; either 'dhcp' for stateful dhcpv6, or slaac for autoconfig. + * Possible values: `dhcp`, `slaac`. + * + * @return ipv6Assignment + */ + @javax.annotation.Nullable public String getIpv6Assignment() { + return ipv6Assignment; + } + + public void setIpv6Assignment(@javax.annotation.Nullable String ipv6Assignment) { + this.ipv6Assignment = ipv6Assignment; + } + + public CreateManagementNetworkPayload name(@javax.annotation.Nonnull String name) { + this.name = name; + return this; + } + + /** + * The name for a General Object. Matches Names and also UUIDs. + * + * @return name + */ + @javax.annotation.Nonnull + public String getName() { + return name; + } + + public void setName(@javax.annotation.Nonnull String name) { + this.name = name; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CreateManagementNetworkPayload createManagementNetworkPayload = + (CreateManagementNetworkPayload) o; + return Objects.equals(this.ipv6Assignment, createManagementNetworkPayload.ipv6Assignment) + && Objects.equals(this.name, createManagementNetworkPayload.name); + } + + @Override + public int hashCode() { + return Objects.hash(ipv6Assignment, name); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CreateManagementNetworkPayload {\n"); + sb.append(" ipv6Assignment: ").append(toIndentedString(ipv6Assignment)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("ipv6Assignment", "name")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("name")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * CreateManagementNetworkPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CreateManagementNetworkPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in CreateManagementNetworkPayload is not found in the empty JSON string", + CreateManagementNetworkPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CreateManagementNetworkPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `CreateManagementNetworkPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : CreateManagementNetworkPayload.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("ipv6Assignment") != null && !jsonObj.get("ipv6Assignment").isJsonNull()) + && !jsonObj.get("ipv6Assignment").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `ipv6Assignment` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("ipv6Assignment").toString())); + } + if (!jsonObj.get("name").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `name` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("name").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateManagementNetworkPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateManagementNetworkPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(CreateManagementNetworkPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateManagementNetworkPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CreateManagementNetworkPayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of CreateManagementNetworkPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateManagementNetworkPayload + * @throws IOException if the JSON string is invalid with respect to + * CreateManagementNetworkPayload + */ + public static CreateManagementNetworkPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CreateManagementNetworkPayload.class); + } + + /** + * Convert an instance of CreateManagementNetworkPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkRoutePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkRoutePayload.java new file mode 100644 index 0000000..d5eac12 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkRoutePayload.java @@ -0,0 +1,235 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonArray; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object represents a request to add management network routes. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateManagementNetworkRoutePayload { + public static final String SERIALIZED_NAME_ITEMS = "items"; + + @SerializedName(SERIALIZED_NAME_ITEMS) + @javax.annotation.Nonnull + private List items = new ArrayList<>(); + + public CreateManagementNetworkRoutePayload() {} + + public CreateManagementNetworkRoutePayload items( + @javax.annotation.Nonnull List items) { + this.items = items; + return this; + } + + public CreateManagementNetworkRoutePayload addItemsItem(ManagementRoute itemsItem) { + if (this.items == null) { + this.items = new ArrayList<>(); + } + this.items.add(itemsItem); + return this; + } + + /** + * A list of management routes. + * + * @return items + */ + @javax.annotation.Nonnull + public List getItems() { + return items; + } + + public void setItems(@javax.annotation.Nonnull List items) { + this.items = items; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CreateManagementNetworkRoutePayload createManagementNetworkRoutePayload = + (CreateManagementNetworkRoutePayload) o; + return Objects.equals(this.items, createManagementNetworkRoutePayload.items); + } + + @Override + public int hashCode() { + return Objects.hash(items); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CreateManagementNetworkRoutePayload {\n"); + sb.append(" items: ").append(toIndentedString(items)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("items")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("items")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * CreateManagementNetworkRoutePayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CreateManagementNetworkRoutePayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in CreateManagementNetworkRoutePayload is not found in the empty JSON string", + CreateManagementNetworkRoutePayload.openapiRequiredFields + .toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CreateManagementNetworkRoutePayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `CreateManagementNetworkRoutePayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : CreateManagementNetworkRoutePayload.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the json data is an array + if (!jsonObj.get("items").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `items` to be an array in the JSON string but got `%s`", + jsonObj.get("items").toString())); + } + + JsonArray jsonArrayitems = jsonObj.getAsJsonArray("items"); + // validate the required field `items` (array) + for (int i = 0; i < jsonArrayitems.size(); i++) { + ManagementRoute.validateJsonElement(jsonArrayitems.get(i)); + } + ; + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateManagementNetworkRoutePayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateManagementNetworkRoutePayload' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(CreateManagementNetworkRoutePayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateManagementNetworkRoutePayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CreateManagementNetworkRoutePayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of CreateManagementNetworkRoutePayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateManagementNetworkRoutePayload + * @throws IOException if the JSON string is invalid with respect to + * CreateManagementNetworkRoutePayload + */ + public static CreateManagementNetworkRoutePayload fromJson(String jsonString) + throws IOException { + return JSON.getGson().fromJson(jsonString, CreateManagementNetworkRoutePayload.class); + } + + /** + * Convert an instance of CreateManagementNetworkRoutePayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaPayload.java index cf2f31a..ac28ea4 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -29,17 +29,11 @@ import java.util.Objects; import java.util.Set; -/** CreateNetworkAreaPayload */ +/** Object that represents the network area create request. */ @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class CreateNetworkAreaPayload { - public static final String SERIALIZED_NAME_ADDRESS_FAMILY = "addressFamily"; - - @SerializedName(SERIALIZED_NAME_ADDRESS_FAMILY) - @javax.annotation.Nonnull - private CreateAreaAddressFamily addressFamily; - public static final String SERIALIZED_NAME_LABELS = "labels"; @SerializedName(SERIALIZED_NAME_LABELS) @@ -53,26 +47,6 @@ public class CreateNetworkAreaPayload { public CreateNetworkAreaPayload() {} - public CreateNetworkAreaPayload addressFamily( - @javax.annotation.Nonnull CreateAreaAddressFamily addressFamily) { - this.addressFamily = addressFamily; - return this; - } - - /** - * Get addressFamily - * - * @return addressFamily - */ - @javax.annotation.Nonnull - public CreateAreaAddressFamily getAddressFamily() { - return addressFamily; - } - - public void setAddressFamily(@javax.annotation.Nonnull CreateAreaAddressFamily addressFamily) { - this.addressFamily = addressFamily; - } - public CreateNetworkAreaPayload labels(@javax.annotation.Nullable Object labels) { this.labels = labels; return this; @@ -80,9 +54,9 @@ public CreateNetworkAreaPayload labels(@javax.annotation.Nullable Object labels) /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -100,7 +74,7 @@ public CreateNetworkAreaPayload name(@javax.annotation.Nonnull String name) { } /** - * The name for a General Object. Matches Names and also UUIDs. + * Get name * * @return name */ @@ -122,21 +96,19 @@ public boolean equals(Object o) { return false; } CreateNetworkAreaPayload createNetworkAreaPayload = (CreateNetworkAreaPayload) o; - return Objects.equals(this.addressFamily, createNetworkAreaPayload.addressFamily) - && Objects.equals(this.labels, createNetworkAreaPayload.labels) + return Objects.equals(this.labels, createNetworkAreaPayload.labels) && Objects.equals(this.name, createNetworkAreaPayload.name); } @Override public int hashCode() { - return Objects.hash(addressFamily, labels, name); + return Objects.hash(labels, name); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class CreateNetworkAreaPayload {\n"); - sb.append(" addressFamily: ").append(toIndentedString(addressFamily)).append("\n"); sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append("}"); @@ -159,10 +131,10 @@ private String toIndentedString(Object o) { static { // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(Arrays.asList("addressFamily", "labels", "name")); + openapiFields = new HashSet(Arrays.asList("labels", "name")); // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(Arrays.asList("addressFamily", "name")); + openapiRequiredFields = new HashSet(Arrays.asList("name")); } /** @@ -203,8 +175,6 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } } JsonObject jsonObj = jsonElement.getAsJsonObject(); - // validate the required field `addressFamily` - CreateAreaAddressFamily.validateJsonElement(jsonObj.get("addressFamily")); if (!jsonObj.get("name").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaRangePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaRangePayload.java index fb7bd2a..9f82b50 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaRangePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaRangePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaRoutePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaRoutePayload.java index c51fa38..90d86a0 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaRoutePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkAreaRoutePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -32,42 +32,44 @@ import java.util.Objects; import java.util.Set; -/** CreateNetworkAreaRoutePayload */ +/** Object represents a request to add network routes. */ @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class CreateNetworkAreaRoutePayload { - public static final String SERIALIZED_NAME_IPV4 = "ipv4"; + public static final String SERIALIZED_NAME_ITEMS = "items"; - @SerializedName(SERIALIZED_NAME_IPV4) - @javax.annotation.Nullable private List ipv4 = new ArrayList<>(); + @SerializedName(SERIALIZED_NAME_ITEMS) + @javax.annotation.Nonnull + private List items = new ArrayList<>(); public CreateNetworkAreaRoutePayload() {} - public CreateNetworkAreaRoutePayload ipv4(@javax.annotation.Nullable List ipv4) { - this.ipv4 = ipv4; + public CreateNetworkAreaRoutePayload items(@javax.annotation.Nonnull List items) { + this.items = items; return this; } - public CreateNetworkAreaRoutePayload addIpv4Item(Route ipv4Item) { - if (this.ipv4 == null) { - this.ipv4 = new ArrayList<>(); + public CreateNetworkAreaRoutePayload addItemsItem(Route itemsItem) { + if (this.items == null) { + this.items = new ArrayList<>(); } - this.ipv4.add(ipv4Item); + this.items.add(itemsItem); return this; } /** * A list of routes. * - * @return ipv4 + * @return items */ - @javax.annotation.Nullable public List getIpv4() { - return ipv4; + @javax.annotation.Nonnull + public List getItems() { + return items; } - public void setIpv4(@javax.annotation.Nullable List ipv4) { - this.ipv4 = ipv4; + public void setItems(@javax.annotation.Nonnull List items) { + this.items = items; } @Override @@ -80,19 +82,19 @@ public boolean equals(Object o) { } CreateNetworkAreaRoutePayload createNetworkAreaRoutePayload = (CreateNetworkAreaRoutePayload) o; - return Objects.equals(this.ipv4, createNetworkAreaRoutePayload.ipv4); + return Objects.equals(this.items, createNetworkAreaRoutePayload.items); } @Override public int hashCode() { - return Objects.hash(ipv4); + return Objects.hash(items); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class CreateNetworkAreaRoutePayload {\n"); - sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); + sb.append(" items: ").append(toIndentedString(items)).append("\n"); sb.append("}"); return sb.toString(); } @@ -113,10 +115,10 @@ private String toIndentedString(Object o) { static { // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(Arrays.asList("ipv4")); + openapiFields = new HashSet(Arrays.asList("items")); // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(0); + openapiRequiredFields = new HashSet(Arrays.asList("items")); } /** @@ -147,25 +149,31 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti entry.getKey(), jsonElement.toString())); } } - JsonObject jsonObj = jsonElement.getAsJsonObject(); - if (jsonObj.get("ipv4") != null && !jsonObj.get("ipv4").isJsonNull()) { - JsonArray jsonArrayipv4 = jsonObj.getAsJsonArray("ipv4"); - if (jsonArrayipv4 != null) { - // ensure the json data is an array - if (!jsonObj.get("ipv4").isJsonArray()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `ipv4` to be an array in the JSON string but got `%s`", - jsonObj.get("ipv4").toString())); - } - - // validate the optional field `ipv4` (array) - for (int i = 0; i < jsonArrayipv4.size(); i++) { - Route.validateJsonElement(jsonArrayipv4.get(i)); - } - ; + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : CreateNetworkAreaRoutePayload.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); } } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the json data is an array + if (!jsonObj.get("items").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `items` to be an array in the JSON string but got `%s`", + jsonObj.get("items").toString())); + } + + JsonArray jsonArrayitems = jsonObj.getAsJsonArray("items"); + // validate the required field `items` (array) + for (int i = 0; i < jsonArrayitems.size(); i++) { + Route.validateJsonElement(jsonArrayitems.get(i)); + } + ; } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4.java new file mode 100644 index 0000000..6a21594 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4.java @@ -0,0 +1,290 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; + +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateNetworkIPv4 extends AbstractOpenApiSchema { + private static final Logger log = Logger.getLogger(CreateNetworkIPv4.class.getName()); + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateNetworkIPv4.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateNetworkIPv4' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter adapterCreateNetworkIPv4WithPrefix = + gson.getDelegateAdapter(this, TypeToken.get(CreateNetworkIPv4WithPrefix.class)); + final TypeAdapter + adapterCreateNetworkIPv4WithPrefixLength = + gson.getDelegateAdapter( + this, TypeToken.get(CreateNetworkIPv4WithPrefixLength.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateNetworkIPv4 value) + throws IOException { + if (value == null || value.getActualInstance() == null) { + elementAdapter.write(out, null); + return; + } + + // check if the actual instance is of the type + // `CreateNetworkIPv4WithPrefix` + if (value.getActualInstance() instanceof CreateNetworkIPv4WithPrefix) { + JsonElement element = + adapterCreateNetworkIPv4WithPrefix.toJsonTree( + (CreateNetworkIPv4WithPrefix) + value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + // check if the actual instance is of the type + // `CreateNetworkIPv4WithPrefixLength` + if (value.getActualInstance() + instanceof CreateNetworkIPv4WithPrefixLength) { + JsonElement element = + adapterCreateNetworkIPv4WithPrefixLength.toJsonTree( + (CreateNetworkIPv4WithPrefixLength) + value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + throw new IOException( + "Failed to serialize as the type doesn't match oneOf schemas: CreateNetworkIPv4WithPrefix, CreateNetworkIPv4WithPrefixLength"); + } + + @Override + public CreateNetworkIPv4 read(JsonReader in) throws IOException { + Object deserialized = null; + JsonElement jsonElement = elementAdapter.read(in); + + int match = 0; + ArrayList errorMessages = new ArrayList<>(); + TypeAdapter actualAdapter = elementAdapter; + + // deserialize CreateNetworkIPv4WithPrefix + try { + // validate the JSON object to see if any exception is thrown + CreateNetworkIPv4WithPrefix.validateJsonElement(jsonElement); + actualAdapter = adapterCreateNetworkIPv4WithPrefix; + match++; + log.log( + Level.FINER, + "Input data matches schema 'CreateNetworkIPv4WithPrefix'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for CreateNetworkIPv4WithPrefix failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'CreateNetworkIPv4WithPrefix'", + e); + } + // deserialize CreateNetworkIPv4WithPrefixLength + try { + // validate the JSON object to see if any exception is thrown + CreateNetworkIPv4WithPrefixLength.validateJsonElement(jsonElement); + actualAdapter = adapterCreateNetworkIPv4WithPrefixLength; + match++; + log.log( + Level.FINER, + "Input data matches schema 'CreateNetworkIPv4WithPrefixLength'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for CreateNetworkIPv4WithPrefixLength failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'CreateNetworkIPv4WithPrefixLength'", + e); + } + + if (match == 1) { + CreateNetworkIPv4 ret = new CreateNetworkIPv4(); + ret.setActualInstance(actualAdapter.fromJsonTree(jsonElement)); + return ret; + } + + throw new IOException( + String.format( + "Failed deserialization for CreateNetworkIPv4: %d classes match result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + match, errorMessages, jsonElement.toString())); + } + }.nullSafe(); + } + } + + // store a list of schema names defined in oneOf + public static final Map> schemas = new HashMap>(); + + public CreateNetworkIPv4() { + super("oneOf", Boolean.FALSE); + } + + public CreateNetworkIPv4(Object o) { + super("oneOf", Boolean.FALSE); + setActualInstance(o); + } + + static { + schemas.put("CreateNetworkIPv4WithPrefix", CreateNetworkIPv4WithPrefix.class); + schemas.put("CreateNetworkIPv4WithPrefixLength", CreateNetworkIPv4WithPrefixLength.class); + } + + @Override + public Map> getSchemas() { + return CreateNetworkIPv4.schemas; + } + + /** + * Set the instance that matches the oneOf child schema, check the instance parameter is valid + * against the oneOf child schemas: CreateNetworkIPv4WithPrefix, + * CreateNetworkIPv4WithPrefixLength + * + *

It could be an instance of the 'oneOf' schemas. + */ + @Override + public void setActualInstance(Object instance) { + if (instance instanceof CreateNetworkIPv4WithPrefix) { + super.setActualInstance(instance); + return; + } + + if (instance instanceof CreateNetworkIPv4WithPrefixLength) { + super.setActualInstance(instance); + return; + } + + throw new RuntimeException( + "Invalid instance type. Must be CreateNetworkIPv4WithPrefix, CreateNetworkIPv4WithPrefixLength"); + } + + /** + * Get the actual instance, which can be the following: CreateNetworkIPv4WithPrefix, + * CreateNetworkIPv4WithPrefixLength + * + * @return The actual instance (CreateNetworkIPv4WithPrefix, CreateNetworkIPv4WithPrefixLength) + */ + @SuppressWarnings("unchecked") + @Override + public Object getActualInstance() { + return super.getActualInstance(); + } + + /** + * Get the actual instance of `CreateNetworkIPv4WithPrefix`. If the actual instance is not + * `CreateNetworkIPv4WithPrefix`, the ClassCastException will be thrown. + * + * @return The actual instance of `CreateNetworkIPv4WithPrefix` + * @throws ClassCastException if the instance is not `CreateNetworkIPv4WithPrefix` + */ + public CreateNetworkIPv4WithPrefix getCreateNetworkIPv4WithPrefix() throws ClassCastException { + return (CreateNetworkIPv4WithPrefix) super.getActualInstance(); + } + + /** + * Get the actual instance of `CreateNetworkIPv4WithPrefixLength`. If the actual instance is not + * `CreateNetworkIPv4WithPrefixLength`, the ClassCastException will be thrown. + * + * @return The actual instance of `CreateNetworkIPv4WithPrefixLength` + * @throws ClassCastException if the instance is not `CreateNetworkIPv4WithPrefixLength` + */ + public CreateNetworkIPv4WithPrefixLength getCreateNetworkIPv4WithPrefixLength() + throws ClassCastException { + return (CreateNetworkIPv4WithPrefixLength) super.getActualInstance(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to CreateNetworkIPv4 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + // validate oneOf schemas one by one + int validCount = 0; + ArrayList errorMessages = new ArrayList<>(); + // validate the json string with CreateNetworkIPv4WithPrefix + try { + CreateNetworkIPv4WithPrefix.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for CreateNetworkIPv4WithPrefix failed with `%s`.", + e.getMessage())); + // continue to the next one + } + // validate the json string with CreateNetworkIPv4WithPrefixLength + try { + CreateNetworkIPv4WithPrefixLength.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for CreateNetworkIPv4WithPrefixLength failed with `%s`.", + e.getMessage())); + // continue to the next one + } + if (validCount != 1) { + throw new IOException( + String.format( + "The JSON string is invalid for CreateNetworkIPv4 with oneOf schemas: CreateNetworkIPv4WithPrefix, CreateNetworkIPv4WithPrefixLength. %d class(es) match the result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + validCount, errorMessages, jsonElement.toString())); + } + } + + /** + * Create an instance of CreateNetworkIPv4 given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateNetworkIPv4 + * @throws IOException if the JSON string is invalid with respect to CreateNetworkIPv4 + */ + public static CreateNetworkIPv4 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CreateNetworkIPv4.class); + } + + /** + * Convert an instance of CreateNetworkIPv4 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4WithPrefix.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4WithPrefix.java new file mode 100644 index 0000000..45652ff --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4WithPrefix.java @@ -0,0 +1,304 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import org.openapitools.jackson.nullable.JsonNullable; + +/** The create request for an IPv4 network with a specified prefix. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateNetworkIPv4WithPrefix { + public static final String SERIALIZED_NAME_GATEWAY = "gateway"; + + @SerializedName(SERIALIZED_NAME_GATEWAY) + @javax.annotation.Nullable private String gateway; + + public static final String SERIALIZED_NAME_NAMESERVERS = "nameservers"; + + @SerializedName(SERIALIZED_NAME_NAMESERVERS) + @javax.annotation.Nullable private List nameservers = new ArrayList<>(); + + public static final String SERIALIZED_NAME_PREFIX = "prefix"; + + @SerializedName(SERIALIZED_NAME_PREFIX) + @javax.annotation.Nonnull + private String prefix; + + public CreateNetworkIPv4WithPrefix() {} + + public CreateNetworkIPv4WithPrefix gateway(@javax.annotation.Nullable String gateway) { + this.gateway = gateway; + return this; + } + + /** + * The IPv4 gateway of a network. If not specified the first IP of the network will be assigned + * as the gateway. If 'null' is sent, then the network doesn't have a gateway. + * + * @return gateway + */ + @javax.annotation.Nullable public String getGateway() { + return gateway; + } + + public void setGateway(@javax.annotation.Nullable String gateway) { + this.gateway = gateway; + } + + public CreateNetworkIPv4WithPrefix nameservers( + @javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + return this; + } + + public CreateNetworkIPv4WithPrefix addNameserversItem(String nameserversItem) { + if (this.nameservers == null) { + this.nameservers = new ArrayList<>(); + } + this.nameservers.add(nameserversItem); + return this; + } + + /** + * A list containing DNS Servers/Nameservers for IPv4. + * + * @return nameservers + */ + @javax.annotation.Nullable public List getNameservers() { + return nameservers; + } + + public void setNameservers(@javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + } + + public CreateNetworkIPv4WithPrefix prefix(@javax.annotation.Nonnull String prefix) { + this.prefix = prefix; + return this; + } + + /** + * IPv4 Classless Inter-Domain Routing (CIDR). + * + * @return prefix + */ + @javax.annotation.Nonnull + public String getPrefix() { + return prefix; + } + + public void setPrefix(@javax.annotation.Nonnull String prefix) { + this.prefix = prefix; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CreateNetworkIPv4WithPrefix createNetworkIPv4WithPrefix = (CreateNetworkIPv4WithPrefix) o; + return Objects.equals(this.gateway, createNetworkIPv4WithPrefix.gateway) + && Objects.equals(this.nameservers, createNetworkIPv4WithPrefix.nameservers) + && Objects.equals(this.prefix, createNetworkIPv4WithPrefix.prefix); + } + + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b + || (a != null + && b != null + && a.isPresent() + && b.isPresent() + && Objects.deepEquals(a.get(), b.get())); + } + + @Override + public int hashCode() { + return Objects.hash(gateway, nameservers, prefix); + } + + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[] {a.get()}) : 31; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CreateNetworkIPv4WithPrefix {\n"); + sb.append(" gateway: ").append(toIndentedString(gateway)).append("\n"); + sb.append(" nameservers: ").append(toIndentedString(nameservers)).append("\n"); + sb.append(" prefix: ").append(toIndentedString(prefix)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("gateway", "nameservers", "prefix")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("prefix")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * CreateNetworkIPv4WithPrefix + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CreateNetworkIPv4WithPrefix.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in CreateNetworkIPv4WithPrefix is not found in the empty JSON string", + CreateNetworkIPv4WithPrefix.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CreateNetworkIPv4WithPrefix.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `CreateNetworkIPv4WithPrefix` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : CreateNetworkIPv4WithPrefix.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("gateway") != null && !jsonObj.get("gateway").isJsonNull()) + && !jsonObj.get("gateway").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `gateway` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("gateway").toString())); + } + // ensure the optional json data is an array if present + if (jsonObj.get("nameservers") != null + && !jsonObj.get("nameservers").isJsonNull() + && !jsonObj.get("nameservers").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `nameservers` to be an array in the JSON string but got `%s`", + jsonObj.get("nameservers").toString())); + } + if (!jsonObj.get("prefix").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `prefix` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("prefix").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateNetworkIPv4WithPrefix.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateNetworkIPv4WithPrefix' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(CreateNetworkIPv4WithPrefix.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateNetworkIPv4WithPrefix value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CreateNetworkIPv4WithPrefix read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of CreateNetworkIPv4WithPrefix given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateNetworkIPv4WithPrefix + * @throws IOException if the JSON string is invalid with respect to CreateNetworkIPv4WithPrefix + */ + public static CreateNetworkIPv4WithPrefix fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CreateNetworkIPv4WithPrefix.class); + } + + /** + * Convert an instance of CreateNetworkIPv4WithPrefix to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4WithPrefixLength.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4WithPrefixLength.java new file mode 100644 index 0000000..f790491 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4WithPrefixLength.java @@ -0,0 +1,255 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** The create request for an IPv4 network with a wanted prefix length. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateNetworkIPv4WithPrefixLength { + public static final String SERIALIZED_NAME_NAMESERVERS = "nameservers"; + + @SerializedName(SERIALIZED_NAME_NAMESERVERS) + @javax.annotation.Nullable private List nameservers = new ArrayList<>(); + + public static final String SERIALIZED_NAME_PREFIX_LENGTH = "prefixLength"; + + @SerializedName(SERIALIZED_NAME_PREFIX_LENGTH) + @javax.annotation.Nonnull + private Long prefixLength; + + public CreateNetworkIPv4WithPrefixLength() {} + + public CreateNetworkIPv4WithPrefixLength nameservers( + @javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + return this; + } + + public CreateNetworkIPv4WithPrefixLength addNameserversItem(String nameserversItem) { + if (this.nameservers == null) { + this.nameservers = new ArrayList<>(); + } + this.nameservers.add(nameserversItem); + return this; + } + + /** + * A list containing DNS Servers/Nameservers for IPv4. + * + * @return nameservers + */ + @javax.annotation.Nullable public List getNameservers() { + return nameservers; + } + + public void setNameservers(@javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + } + + public CreateNetworkIPv4WithPrefixLength prefixLength( + @javax.annotation.Nonnull Long prefixLength) { + this.prefixLength = prefixLength; + return this; + } + + /** + * Get prefixLength minimum: 8 maximum: 29 + * + * @return prefixLength + */ + @javax.annotation.Nonnull + public Long getPrefixLength() { + return prefixLength; + } + + public void setPrefixLength(@javax.annotation.Nonnull Long prefixLength) { + this.prefixLength = prefixLength; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CreateNetworkIPv4WithPrefixLength createNetworkIPv4WithPrefixLength = + (CreateNetworkIPv4WithPrefixLength) o; + return Objects.equals(this.nameservers, createNetworkIPv4WithPrefixLength.nameservers) + && Objects.equals( + this.prefixLength, createNetworkIPv4WithPrefixLength.prefixLength); + } + + @Override + public int hashCode() { + return Objects.hash(nameservers, prefixLength); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CreateNetworkIPv4WithPrefixLength {\n"); + sb.append(" nameservers: ").append(toIndentedString(nameservers)).append("\n"); + sb.append(" prefixLength: ").append(toIndentedString(prefixLength)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("nameservers", "prefixLength")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("prefixLength")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * CreateNetworkIPv4WithPrefixLength + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CreateNetworkIPv4WithPrefixLength.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in CreateNetworkIPv4WithPrefixLength is not found in the empty JSON string", + CreateNetworkIPv4WithPrefixLength.openapiRequiredFields + .toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CreateNetworkIPv4WithPrefixLength.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `CreateNetworkIPv4WithPrefixLength` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : CreateNetworkIPv4WithPrefixLength.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the optional json data is an array if present + if (jsonObj.get("nameservers") != null + && !jsonObj.get("nameservers").isJsonNull() + && !jsonObj.get("nameservers").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `nameservers` to be an array in the JSON string but got `%s`", + jsonObj.get("nameservers").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateNetworkIPv4WithPrefixLength.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateNetworkIPv4WithPrefixLength' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(CreateNetworkIPv4WithPrefixLength.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateNetworkIPv4WithPrefixLength value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CreateNetworkIPv4WithPrefixLength read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of CreateNetworkIPv4WithPrefixLength given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateNetworkIPv4WithPrefixLength + * @throws IOException if the JSON string is invalid with respect to + * CreateNetworkIPv4WithPrefixLength + */ + public static CreateNetworkIPv4WithPrefixLength fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CreateNetworkIPv4WithPrefixLength.class); + } + + /** + * Convert an instance of CreateNetworkIPv4WithPrefixLength to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6.java new file mode 100644 index 0000000..81517cc --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6.java @@ -0,0 +1,290 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; + +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateNetworkIPv6 extends AbstractOpenApiSchema { + private static final Logger log = Logger.getLogger(CreateNetworkIPv6.class.getName()); + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateNetworkIPv6.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateNetworkIPv6' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter adapterCreateNetworkIPv6WithPrefix = + gson.getDelegateAdapter(this, TypeToken.get(CreateNetworkIPv6WithPrefix.class)); + final TypeAdapter + adapterCreateNetworkIPv6WithPrefixLength = + gson.getDelegateAdapter( + this, TypeToken.get(CreateNetworkIPv6WithPrefixLength.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateNetworkIPv6 value) + throws IOException { + if (value == null || value.getActualInstance() == null) { + elementAdapter.write(out, null); + return; + } + + // check if the actual instance is of the type + // `CreateNetworkIPv6WithPrefix` + if (value.getActualInstance() instanceof CreateNetworkIPv6WithPrefix) { + JsonElement element = + adapterCreateNetworkIPv6WithPrefix.toJsonTree( + (CreateNetworkIPv6WithPrefix) + value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + // check if the actual instance is of the type + // `CreateNetworkIPv6WithPrefixLength` + if (value.getActualInstance() + instanceof CreateNetworkIPv6WithPrefixLength) { + JsonElement element = + adapterCreateNetworkIPv6WithPrefixLength.toJsonTree( + (CreateNetworkIPv6WithPrefixLength) + value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + throw new IOException( + "Failed to serialize as the type doesn't match oneOf schemas: CreateNetworkIPv6WithPrefix, CreateNetworkIPv6WithPrefixLength"); + } + + @Override + public CreateNetworkIPv6 read(JsonReader in) throws IOException { + Object deserialized = null; + JsonElement jsonElement = elementAdapter.read(in); + + int match = 0; + ArrayList errorMessages = new ArrayList<>(); + TypeAdapter actualAdapter = elementAdapter; + + // deserialize CreateNetworkIPv6WithPrefix + try { + // validate the JSON object to see if any exception is thrown + CreateNetworkIPv6WithPrefix.validateJsonElement(jsonElement); + actualAdapter = adapterCreateNetworkIPv6WithPrefix; + match++; + log.log( + Level.FINER, + "Input data matches schema 'CreateNetworkIPv6WithPrefix'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for CreateNetworkIPv6WithPrefix failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'CreateNetworkIPv6WithPrefix'", + e); + } + // deserialize CreateNetworkIPv6WithPrefixLength + try { + // validate the JSON object to see if any exception is thrown + CreateNetworkIPv6WithPrefixLength.validateJsonElement(jsonElement); + actualAdapter = adapterCreateNetworkIPv6WithPrefixLength; + match++; + log.log( + Level.FINER, + "Input data matches schema 'CreateNetworkIPv6WithPrefixLength'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for CreateNetworkIPv6WithPrefixLength failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'CreateNetworkIPv6WithPrefixLength'", + e); + } + + if (match == 1) { + CreateNetworkIPv6 ret = new CreateNetworkIPv6(); + ret.setActualInstance(actualAdapter.fromJsonTree(jsonElement)); + return ret; + } + + throw new IOException( + String.format( + "Failed deserialization for CreateNetworkIPv6: %d classes match result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + match, errorMessages, jsonElement.toString())); + } + }.nullSafe(); + } + } + + // store a list of schema names defined in oneOf + public static final Map> schemas = new HashMap>(); + + public CreateNetworkIPv6() { + super("oneOf", Boolean.FALSE); + } + + public CreateNetworkIPv6(Object o) { + super("oneOf", Boolean.FALSE); + setActualInstance(o); + } + + static { + schemas.put("CreateNetworkIPv6WithPrefix", CreateNetworkIPv6WithPrefix.class); + schemas.put("CreateNetworkIPv6WithPrefixLength", CreateNetworkIPv6WithPrefixLength.class); + } + + @Override + public Map> getSchemas() { + return CreateNetworkIPv6.schemas; + } + + /** + * Set the instance that matches the oneOf child schema, check the instance parameter is valid + * against the oneOf child schemas: CreateNetworkIPv6WithPrefix, + * CreateNetworkIPv6WithPrefixLength + * + *

It could be an instance of the 'oneOf' schemas. + */ + @Override + public void setActualInstance(Object instance) { + if (instance instanceof CreateNetworkIPv6WithPrefix) { + super.setActualInstance(instance); + return; + } + + if (instance instanceof CreateNetworkIPv6WithPrefixLength) { + super.setActualInstance(instance); + return; + } + + throw new RuntimeException( + "Invalid instance type. Must be CreateNetworkIPv6WithPrefix, CreateNetworkIPv6WithPrefixLength"); + } + + /** + * Get the actual instance, which can be the following: CreateNetworkIPv6WithPrefix, + * CreateNetworkIPv6WithPrefixLength + * + * @return The actual instance (CreateNetworkIPv6WithPrefix, CreateNetworkIPv6WithPrefixLength) + */ + @SuppressWarnings("unchecked") + @Override + public Object getActualInstance() { + return super.getActualInstance(); + } + + /** + * Get the actual instance of `CreateNetworkIPv6WithPrefix`. If the actual instance is not + * `CreateNetworkIPv6WithPrefix`, the ClassCastException will be thrown. + * + * @return The actual instance of `CreateNetworkIPv6WithPrefix` + * @throws ClassCastException if the instance is not `CreateNetworkIPv6WithPrefix` + */ + public CreateNetworkIPv6WithPrefix getCreateNetworkIPv6WithPrefix() throws ClassCastException { + return (CreateNetworkIPv6WithPrefix) super.getActualInstance(); + } + + /** + * Get the actual instance of `CreateNetworkIPv6WithPrefixLength`. If the actual instance is not + * `CreateNetworkIPv6WithPrefixLength`, the ClassCastException will be thrown. + * + * @return The actual instance of `CreateNetworkIPv6WithPrefixLength` + * @throws ClassCastException if the instance is not `CreateNetworkIPv6WithPrefixLength` + */ + public CreateNetworkIPv6WithPrefixLength getCreateNetworkIPv6WithPrefixLength() + throws ClassCastException { + return (CreateNetworkIPv6WithPrefixLength) super.getActualInstance(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to CreateNetworkIPv6 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + // validate oneOf schemas one by one + int validCount = 0; + ArrayList errorMessages = new ArrayList<>(); + // validate the json string with CreateNetworkIPv6WithPrefix + try { + CreateNetworkIPv6WithPrefix.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for CreateNetworkIPv6WithPrefix failed with `%s`.", + e.getMessage())); + // continue to the next one + } + // validate the json string with CreateNetworkIPv6WithPrefixLength + try { + CreateNetworkIPv6WithPrefixLength.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for CreateNetworkIPv6WithPrefixLength failed with `%s`.", + e.getMessage())); + // continue to the next one + } + if (validCount != 1) { + throw new IOException( + String.format( + "The JSON string is invalid for CreateNetworkIPv6 with oneOf schemas: CreateNetworkIPv6WithPrefix, CreateNetworkIPv6WithPrefixLength. %d class(es) match the result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + validCount, errorMessages, jsonElement.toString())); + } + } + + /** + * Create an instance of CreateNetworkIPv6 given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateNetworkIPv6 + * @throws IOException if the JSON string is invalid with respect to CreateNetworkIPv6 + */ + public static CreateNetworkIPv6 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CreateNetworkIPv6.class); + } + + /** + * Convert an instance of CreateNetworkIPv6 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6WithPrefix.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6WithPrefix.java new file mode 100644 index 0000000..78acbc6 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6WithPrefix.java @@ -0,0 +1,304 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import org.openapitools.jackson.nullable.JsonNullable; + +/** The create request for an IPv6 network with a specified prefix. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateNetworkIPv6WithPrefix { + public static final String SERIALIZED_NAME_GATEWAY = "gateway"; + + @SerializedName(SERIALIZED_NAME_GATEWAY) + @javax.annotation.Nullable private String gateway; + + public static final String SERIALIZED_NAME_NAMESERVERS = "nameservers"; + + @SerializedName(SERIALIZED_NAME_NAMESERVERS) + @javax.annotation.Nullable private List nameservers = new ArrayList<>(); + + public static final String SERIALIZED_NAME_PREFIX = "prefix"; + + @SerializedName(SERIALIZED_NAME_PREFIX) + @javax.annotation.Nonnull + private String prefix; + + public CreateNetworkIPv6WithPrefix() {} + + public CreateNetworkIPv6WithPrefix gateway(@javax.annotation.Nullable String gateway) { + this.gateway = gateway; + return this; + } + + /** + * The IPv6 gateway of a network. If not specified the first IP of the network will be assigned + * as the gateway. If 'null' is sent, then the network doesn't have a gateway. + * + * @return gateway + */ + @javax.annotation.Nullable public String getGateway() { + return gateway; + } + + public void setGateway(@javax.annotation.Nullable String gateway) { + this.gateway = gateway; + } + + public CreateNetworkIPv6WithPrefix nameservers( + @javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + return this; + } + + public CreateNetworkIPv6WithPrefix addNameserversItem(String nameserversItem) { + if (this.nameservers == null) { + this.nameservers = new ArrayList<>(); + } + this.nameservers.add(nameserversItem); + return this; + } + + /** + * A list containing DNS Servers/Nameservers for IPv6. + * + * @return nameservers + */ + @javax.annotation.Nullable public List getNameservers() { + return nameservers; + } + + public void setNameservers(@javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + } + + public CreateNetworkIPv6WithPrefix prefix(@javax.annotation.Nonnull String prefix) { + this.prefix = prefix; + return this; + } + + /** + * Classless Inter-Domain Routing (CIDR) for IPv6. + * + * @return prefix + */ + @javax.annotation.Nonnull + public String getPrefix() { + return prefix; + } + + public void setPrefix(@javax.annotation.Nonnull String prefix) { + this.prefix = prefix; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CreateNetworkIPv6WithPrefix createNetworkIPv6WithPrefix = (CreateNetworkIPv6WithPrefix) o; + return Objects.equals(this.gateway, createNetworkIPv6WithPrefix.gateway) + && Objects.equals(this.nameservers, createNetworkIPv6WithPrefix.nameservers) + && Objects.equals(this.prefix, createNetworkIPv6WithPrefix.prefix); + } + + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b + || (a != null + && b != null + && a.isPresent() + && b.isPresent() + && Objects.deepEquals(a.get(), b.get())); + } + + @Override + public int hashCode() { + return Objects.hash(gateway, nameservers, prefix); + } + + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[] {a.get()}) : 31; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CreateNetworkIPv6WithPrefix {\n"); + sb.append(" gateway: ").append(toIndentedString(gateway)).append("\n"); + sb.append(" nameservers: ").append(toIndentedString(nameservers)).append("\n"); + sb.append(" prefix: ").append(toIndentedString(prefix)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("gateway", "nameservers", "prefix")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("prefix")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * CreateNetworkIPv6WithPrefix + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CreateNetworkIPv6WithPrefix.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in CreateNetworkIPv6WithPrefix is not found in the empty JSON string", + CreateNetworkIPv6WithPrefix.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CreateNetworkIPv6WithPrefix.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `CreateNetworkIPv6WithPrefix` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : CreateNetworkIPv6WithPrefix.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("gateway") != null && !jsonObj.get("gateway").isJsonNull()) + && !jsonObj.get("gateway").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `gateway` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("gateway").toString())); + } + // ensure the optional json data is an array if present + if (jsonObj.get("nameservers") != null + && !jsonObj.get("nameservers").isJsonNull() + && !jsonObj.get("nameservers").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `nameservers` to be an array in the JSON string but got `%s`", + jsonObj.get("nameservers").toString())); + } + if (!jsonObj.get("prefix").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `prefix` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("prefix").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateNetworkIPv6WithPrefix.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateNetworkIPv6WithPrefix' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(CreateNetworkIPv6WithPrefix.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateNetworkIPv6WithPrefix value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CreateNetworkIPv6WithPrefix read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of CreateNetworkIPv6WithPrefix given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateNetworkIPv6WithPrefix + * @throws IOException if the JSON string is invalid with respect to CreateNetworkIPv6WithPrefix + */ + public static CreateNetworkIPv6WithPrefix fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CreateNetworkIPv6WithPrefix.class); + } + + /** + * Convert an instance of CreateNetworkIPv6WithPrefix to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6WithPrefixLength.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6WithPrefixLength.java new file mode 100644 index 0000000..e5808de --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6WithPrefixLength.java @@ -0,0 +1,255 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** The create request for an IPv6 network with a wanted prefix length. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateNetworkIPv6WithPrefixLength { + public static final String SERIALIZED_NAME_NAMESERVERS = "nameservers"; + + @SerializedName(SERIALIZED_NAME_NAMESERVERS) + @javax.annotation.Nullable private List nameservers = new ArrayList<>(); + + public static final String SERIALIZED_NAME_PREFIX_LENGTH = "prefixLength"; + + @SerializedName(SERIALIZED_NAME_PREFIX_LENGTH) + @javax.annotation.Nonnull + private Long prefixLength; + + public CreateNetworkIPv6WithPrefixLength() {} + + public CreateNetworkIPv6WithPrefixLength nameservers( + @javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + return this; + } + + public CreateNetworkIPv6WithPrefixLength addNameserversItem(String nameserversItem) { + if (this.nameservers == null) { + this.nameservers = new ArrayList<>(); + } + this.nameservers.add(nameserversItem); + return this; + } + + /** + * A list containing DNS Servers/Nameservers for IPv6. + * + * @return nameservers + */ + @javax.annotation.Nullable public List getNameservers() { + return nameservers; + } + + public void setNameservers(@javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + } + + public CreateNetworkIPv6WithPrefixLength prefixLength( + @javax.annotation.Nonnull Long prefixLength) { + this.prefixLength = prefixLength; + return this; + } + + /** + * Get prefixLength minimum: 56 maximum: 128 + * + * @return prefixLength + */ + @javax.annotation.Nonnull + public Long getPrefixLength() { + return prefixLength; + } + + public void setPrefixLength(@javax.annotation.Nonnull Long prefixLength) { + this.prefixLength = prefixLength; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + CreateNetworkIPv6WithPrefixLength createNetworkIPv6WithPrefixLength = + (CreateNetworkIPv6WithPrefixLength) o; + return Objects.equals(this.nameservers, createNetworkIPv6WithPrefixLength.nameservers) + && Objects.equals( + this.prefixLength, createNetworkIPv6WithPrefixLength.prefixLength); + } + + @Override + public int hashCode() { + return Objects.hash(nameservers, prefixLength); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class CreateNetworkIPv6WithPrefixLength {\n"); + sb.append(" nameservers: ").append(toIndentedString(nameservers)).append("\n"); + sb.append(" prefixLength: ").append(toIndentedString(prefixLength)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("nameservers", "prefixLength")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("prefixLength")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * CreateNetworkIPv6WithPrefixLength + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!CreateNetworkIPv6WithPrefixLength.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in CreateNetworkIPv6WithPrefixLength is not found in the empty JSON string", + CreateNetworkIPv6WithPrefixLength.openapiRequiredFields + .toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!CreateNetworkIPv6WithPrefixLength.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `CreateNetworkIPv6WithPrefixLength` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : CreateNetworkIPv6WithPrefixLength.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the optional json data is an array if present + if (jsonObj.get("nameservers") != null + && !jsonObj.get("nameservers").isJsonNull() + && !jsonObj.get("nameservers").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `nameservers` to be an array in the JSON string but got `%s`", + jsonObj.get("nameservers").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateNetworkIPv6WithPrefixLength.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateNetworkIPv6WithPrefixLength' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(CreateNetworkIPv6WithPrefixLength.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateNetworkIPv6WithPrefixLength value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public CreateNetworkIPv6WithPrefixLength read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of CreateNetworkIPv6WithPrefixLength given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateNetworkIPv6WithPrefixLength + * @throws IOException if the JSON string is invalid with respect to + * CreateNetworkIPv6WithPrefixLength + */ + public static CreateNetworkIPv6WithPrefixLength fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, CreateNetworkIPv6WithPrefixLength.class); + } + + /** + * Convert an instance of CreateNetworkIPv6WithPrefixLength to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkPayload.java index 59123ff..91d386d 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -28,22 +28,28 @@ import java.util.Map; import java.util.Objects; import java.util.Set; +import java.util.UUID; /** Object that represents the request body for a network create. */ @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class CreateNetworkPayload { - public static final String SERIALIZED_NAME_ADDRESS_FAMILY = "addressFamily"; - - @SerializedName(SERIALIZED_NAME_ADDRESS_FAMILY) - @javax.annotation.Nullable private CreateNetworkAddressFamily addressFamily; - public static final String SERIALIZED_NAME_DHCP = "dhcp"; @SerializedName(SERIALIZED_NAME_DHCP) @javax.annotation.Nullable private Boolean dhcp = true; + public static final String SERIALIZED_NAME_IPV4 = "ipv4"; + + @SerializedName(SERIALIZED_NAME_IPV4) + @javax.annotation.Nullable private CreateNetworkIPv4 ipv4; + + public static final String SERIALIZED_NAME_IPV6 = "ipv6"; + + @SerializedName(SERIALIZED_NAME_IPV6) + @javax.annotation.Nullable private CreateNetworkIPv6 ipv6; + public static final String SERIALIZED_NAME_LABELS = "labels"; @SerializedName(SERIALIZED_NAME_LABELS) @@ -60,44 +66,65 @@ public class CreateNetworkPayload { @SerializedName(SERIALIZED_NAME_ROUTED) @javax.annotation.Nullable private Boolean routed; + public static final String SERIALIZED_NAME_ROUTING_TABLE_ID = "routingTableId"; + + @SerializedName(SERIALIZED_NAME_ROUTING_TABLE_ID) + @javax.annotation.Nullable private UUID routingTableId; + public CreateNetworkPayload() {} - public CreateNetworkPayload addressFamily( - @javax.annotation.Nullable CreateNetworkAddressFamily addressFamily) { - this.addressFamily = addressFamily; + public CreateNetworkPayload dhcp(@javax.annotation.Nullable Boolean dhcp) { + this.dhcp = dhcp; return this; } /** - * Get addressFamily + * Enable or disable DHCP for a network. * - * @return addressFamily + * @return dhcp */ - @javax.annotation.Nullable public CreateNetworkAddressFamily getAddressFamily() { - return addressFamily; + @javax.annotation.Nullable public Boolean getDhcp() { + return dhcp; } - public void setAddressFamily( - @javax.annotation.Nullable CreateNetworkAddressFamily addressFamily) { - this.addressFamily = addressFamily; + public void setDhcp(@javax.annotation.Nullable Boolean dhcp) { + this.dhcp = dhcp; } - public CreateNetworkPayload dhcp(@javax.annotation.Nullable Boolean dhcp) { - this.dhcp = dhcp; + public CreateNetworkPayload ipv4(@javax.annotation.Nullable CreateNetworkIPv4 ipv4) { + this.ipv4 = ipv4; return this; } /** - * Enable or disable DHCP for a network. + * Get ipv4 * - * @return dhcp + * @return ipv4 */ - @javax.annotation.Nullable public Boolean getDhcp() { - return dhcp; + @javax.annotation.Nullable public CreateNetworkIPv4 getIpv4() { + return ipv4; } - public void setDhcp(@javax.annotation.Nullable Boolean dhcp) { - this.dhcp = dhcp; + public void setIpv4(@javax.annotation.Nullable CreateNetworkIPv4 ipv4) { + this.ipv4 = ipv4; + } + + public CreateNetworkPayload ipv6(@javax.annotation.Nullable CreateNetworkIPv6 ipv6) { + this.ipv6 = ipv6; + return this; + } + + /** + * Get ipv6 + * + * @return ipv6 + */ + @javax.annotation.Nullable public CreateNetworkIPv6 getIpv6() { + return ipv6; + } + + public void setIpv6(@javax.annotation.Nullable CreateNetworkIPv6 ipv6) { + this.ipv6 = ipv6; } public CreateNetworkPayload labels(@javax.annotation.Nullable Object labels) { @@ -107,9 +134,9 @@ public CreateNetworkPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -158,6 +185,24 @@ public void setRouted(@javax.annotation.Nullable Boolean routed) { this.routed = routed; } + public CreateNetworkPayload routingTableId(@javax.annotation.Nullable UUID routingTableId) { + this.routingTableId = routingTableId; + return this; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return routingTableId + */ + @javax.annotation.Nullable public UUID getRoutingTableId() { + return routingTableId; + } + + public void setRoutingTableId(@javax.annotation.Nullable UUID routingTableId) { + this.routingTableId = routingTableId; + } + @Override public boolean equals(Object o) { if (this == o) { @@ -167,27 +212,31 @@ public boolean equals(Object o) { return false; } CreateNetworkPayload createNetworkPayload = (CreateNetworkPayload) o; - return Objects.equals(this.addressFamily, createNetworkPayload.addressFamily) - && Objects.equals(this.dhcp, createNetworkPayload.dhcp) + return Objects.equals(this.dhcp, createNetworkPayload.dhcp) + && Objects.equals(this.ipv4, createNetworkPayload.ipv4) + && Objects.equals(this.ipv6, createNetworkPayload.ipv6) && Objects.equals(this.labels, createNetworkPayload.labels) && Objects.equals(this.name, createNetworkPayload.name) - && Objects.equals(this.routed, createNetworkPayload.routed); + && Objects.equals(this.routed, createNetworkPayload.routed) + && Objects.equals(this.routingTableId, createNetworkPayload.routingTableId); } @Override public int hashCode() { - return Objects.hash(addressFamily, dhcp, labels, name, routed); + return Objects.hash(dhcp, ipv4, ipv6, labels, name, routed, routingTableId); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class CreateNetworkPayload {\n"); - sb.append(" addressFamily: ").append(toIndentedString(addressFamily)).append("\n"); sb.append(" dhcp: ").append(toIndentedString(dhcp)).append("\n"); + sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); + sb.append(" ipv6: ").append(toIndentedString(ipv6)).append("\n"); sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" routed: ").append(toIndentedString(routed)).append("\n"); + sb.append(" routingTableId: ").append(toIndentedString(routingTableId)).append("\n"); sb.append("}"); return sb.toString(); } @@ -210,7 +259,14 @@ private String toIndentedString(Object o) { // a set of all properties/fields (JSON key names) openapiFields = new HashSet( - Arrays.asList("addressFamily", "dhcp", "labels", "name", "routed")); + Arrays.asList( + "dhcp", + "ipv4", + "ipv6", + "labels", + "name", + "routed", + "routingTableId")); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(Arrays.asList("name")); @@ -254,9 +310,13 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } } JsonObject jsonObj = jsonElement.getAsJsonObject(); - // validate the optional field `addressFamily` - if (jsonObj.get("addressFamily") != null && !jsonObj.get("addressFamily").isJsonNull()) { - CreateNetworkAddressFamily.validateJsonElement(jsonObj.get("addressFamily")); + // validate the optional field `ipv4` + if (jsonObj.get("ipv4") != null && !jsonObj.get("ipv4").isJsonNull()) { + CreateNetworkIPv4.validateJsonElement(jsonObj.get("ipv4")); + } + // validate the optional field `ipv6` + if (jsonObj.get("ipv6") != null && !jsonObj.get("ipv6").isJsonNull()) { + CreateNetworkIPv6.validateJsonElement(jsonObj.get("ipv6")); } if (!jsonObj.get("name").isJsonPrimitive()) { throw new IllegalArgumentException( @@ -264,6 +324,13 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti "Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); } + if ((jsonObj.get("routingTableId") != null && !jsonObj.get("routingTableId").isJsonNull()) + && !jsonObj.get("routingTableId").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `routingTableId` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("routingTableId").toString())); + } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNicPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNicPayload.java index 4b41a84..551aecd 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNicPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNicPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -43,6 +43,11 @@ public class CreateNicPayload { @SerializedName(SERIALIZED_NAME_ALLOWED_ADDRESSES) @javax.annotation.Nullable private List allowedAddresses = new ArrayList<>(); + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + @javax.annotation.Nullable private String description; + public static final String SERIALIZED_NAME_DEVICE = "device"; @SerializedName(SERIALIZED_NAME_DEVICE) @@ -144,6 +149,24 @@ public void setAllowedAddresses( this.allowedAddresses = allowedAddresses; } + public CreateNicPayload description(@javax.annotation.Nullable String description) { + this.description = description; + return this; + } + + /** + * Description Object. Allows string up to 255 Characters. + * + * @return description + */ + @javax.annotation.Nullable public String getDescription() { + return description; + } + + public void setDescription(@javax.annotation.Nullable String description) { + this.description = description; + } + /** * Universally Unique Identifier (UUID). * @@ -205,9 +228,9 @@ public CreateNicPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -328,6 +351,7 @@ public boolean equals(Object o) { } CreateNicPayload createNicPayload = (CreateNicPayload) o; return Objects.equals(this.allowedAddresses, createNicPayload.allowedAddresses) + && Objects.equals(this.description, createNicPayload.description) && Objects.equals(this.device, createNicPayload.device) && Objects.equals(this.id, createNicPayload.id) && Objects.equals(this.ipv4, createNicPayload.ipv4) @@ -346,6 +370,7 @@ public boolean equals(Object o) { public int hashCode() { return Objects.hash( allowedAddresses, + description, device, id, ipv4, @@ -365,6 +390,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class CreateNicPayload {\n"); sb.append(" allowedAddresses: ").append(toIndentedString(allowedAddresses)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" device: ").append(toIndentedString(device)).append("\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); @@ -401,6 +427,7 @@ private String toIndentedString(Object o) { new HashSet( Arrays.asList( "allowedAddresses", + "description", "device", "id", "ipv4", @@ -465,6 +492,13 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti ; } } + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) + && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `description` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("description").toString())); + } if ((jsonObj.get("device") != null && !jsonObj.get("device").isJsonNull()) && !jsonObj.get("device").isJsonPrimitive()) { throw new IllegalArgumentException( diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateProtocol.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateProtocol.java index 7af293e..ae4c8fc 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateProtocol.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateProtocol.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreatePublicIPPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreatePublicIPPayload.java index e61574b..67558dd 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreatePublicIPPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreatePublicIPPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -74,7 +74,7 @@ public CreatePublicIPPayload(UUID id, String ip) { } /** - * Object that represents an IP address. + * String that represents an IPv4 address. * * @return ip */ @@ -89,9 +89,9 @@ public CreatePublicIPPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupPayload.java index be9904e..c677f2b 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -136,9 +136,9 @@ public CreateSecurityGroupPayload labels(@javax.annotation.Nullable Object label /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRulePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRulePayload.java index 13bfe00..40bc0d7 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRulePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRulePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -23,6 +23,7 @@ import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import java.io.IOException; +import java.time.OffsetDateTime; import java.util.Arrays; import java.util.HashSet; import java.util.Map; @@ -35,6 +36,11 @@ value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class CreateSecurityGroupRulePayload { + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + + @SerializedName(SERIALIZED_NAME_CREATED_AT) + @javax.annotation.Nullable private OffsetDateTime createdAt; + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; @SerializedName(SERIALIZED_NAME_DESCRIPTION) @@ -81,6 +87,11 @@ public class CreateSecurityGroupRulePayload { @SerializedName(SERIALIZED_NAME_SECURITY_GROUP_ID) @javax.annotation.Nullable private UUID securityGroupId; + public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; + + @SerializedName(SERIALIZED_NAME_UPDATED_AT) + @javax.annotation.Nullable private OffsetDateTime updatedAt; + public static final String SERIALIZED_NAME_PROTOCOL = "protocol"; @SerializedName(SERIALIZED_NAME_PROTOCOL) @@ -88,10 +99,22 @@ public class CreateSecurityGroupRulePayload { public CreateSecurityGroupRulePayload() {} - public CreateSecurityGroupRulePayload(UUID id, UUID securityGroupId) { + public CreateSecurityGroupRulePayload( + OffsetDateTime createdAt, UUID id, UUID securityGroupId, OffsetDateTime updatedAt) { this(); + this.createdAt = createdAt; this.id = id; this.securityGroupId = securityGroupId; + this.updatedAt = updatedAt; + } + + /** + * Date-time when resource was created. + * + * @return createdAt + */ + @javax.annotation.Nullable public OffsetDateTime getCreatedAt() { + return createdAt; } public CreateSecurityGroupRulePayload description( @@ -245,6 +268,15 @@ public void setRemoteSecurityGroupId(@javax.annotation.Nullable UUID remoteSecur return securityGroupId; } + /** + * Date-time when resource was last updated. + * + * @return updatedAt + */ + @javax.annotation.Nullable public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + public CreateSecurityGroupRulePayload protocol( @javax.annotation.Nullable CreateProtocol protocol) { this.protocol = protocol; @@ -274,7 +306,8 @@ public boolean equals(Object o) { } CreateSecurityGroupRulePayload createSecurityGroupRulePayload = (CreateSecurityGroupRulePayload) o; - return Objects.equals(this.description, createSecurityGroupRulePayload.description) + return Objects.equals(this.createdAt, createSecurityGroupRulePayload.createdAt) + && Objects.equals(this.description, createSecurityGroupRulePayload.description) && Objects.equals(this.direction, createSecurityGroupRulePayload.direction) && Objects.equals(this.ethertype, createSecurityGroupRulePayload.ethertype) && Objects.equals( @@ -287,12 +320,14 @@ public boolean equals(Object o) { createSecurityGroupRulePayload.remoteSecurityGroupId) && Objects.equals( this.securityGroupId, createSecurityGroupRulePayload.securityGroupId) + && Objects.equals(this.updatedAt, createSecurityGroupRulePayload.updatedAt) && Objects.equals(this.protocol, createSecurityGroupRulePayload.protocol); } @Override public int hashCode() { return Objects.hash( + createdAt, description, direction, ethertype, @@ -302,6 +337,7 @@ public int hashCode() { portRange, remoteSecurityGroupId, securityGroupId, + updatedAt, protocol); } @@ -309,6 +345,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class CreateSecurityGroupRulePayload {\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" direction: ").append(toIndentedString(direction)).append("\n"); sb.append(" ethertype: ").append(toIndentedString(ethertype)).append("\n"); @@ -320,6 +357,7 @@ public String toString() { .append(toIndentedString(remoteSecurityGroupId)) .append("\n"); sb.append(" securityGroupId: ").append(toIndentedString(securityGroupId)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append(" protocol: ").append(toIndentedString(protocol)).append("\n"); sb.append("}"); return sb.toString(); @@ -344,6 +382,7 @@ private String toIndentedString(Object o) { openapiFields = new HashSet( Arrays.asList( + "createdAt", "description", "direction", "ethertype", @@ -353,6 +392,7 @@ private String toIndentedString(Object o) { "portRange", "remoteSecurityGroupId", "securityGroupId", + "updatedAt", "protocol")); // a set of required properties/fields (JSON key names) diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRuleProtocol.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRuleProtocol.java index 73ae90b..77a6e5d 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRuleProtocol.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRuleProtocol.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerNetworking.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerNetworking.java index e1b3ef0..10238bd 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerNetworking.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerNetworking.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerNetworkingWithNics.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerNetworkingWithNics.java index 61df2e3..af4fe0c 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerNetworkingWithNics.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerNetworkingWithNics.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerPayload.java index 3a4740f..58e0f84 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -34,7 +34,7 @@ import java.util.Set; import java.util.UUID; -/** Representation of a single server object. */ +/** Object that represents the request body for a server create. */ @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") @@ -44,6 +44,11 @@ public class CreateServerPayload { @SerializedName(SERIALIZED_NAME_AFFINITY_GROUP) @javax.annotation.Nullable private UUID affinityGroup; + public static final String SERIALIZED_NAME_AGENT = "agent"; + + @SerializedName(SERIALIZED_NAME_AGENT) + @javax.annotation.Nullable private ServerAgent agent; + public static final String SERIALIZED_NAME_AVAILABILITY_ZONE = "availabilityZone"; @SerializedName(SERIALIZED_NAME_AVAILABILITY_ZONE) @@ -114,7 +119,8 @@ public class CreateServerPayload { public static final String SERIALIZED_NAME_NETWORKING = "networking"; @SerializedName(SERIALIZED_NAME_NETWORKING) - @javax.annotation.Nullable private CreateServerPayloadNetworking networking; + @javax.annotation.Nonnull + private CreateServerPayloadAllOfNetworking networking; public static final String SERIALIZED_NAME_NICS = "nics"; @@ -198,6 +204,24 @@ public void setAffinityGroup(@javax.annotation.Nullable UUID affinityGroup) { this.affinityGroup = affinityGroup; } + public CreateServerPayload agent(@javax.annotation.Nullable ServerAgent agent) { + this.agent = agent; + return this; + } + + /** + * Get agent + * + * @return agent + */ + @javax.annotation.Nullable public ServerAgent getAgent() { + return agent; + } + + public void setAgent(@javax.annotation.Nullable ServerAgent agent) { + this.agent = agent; + } + public CreateServerPayload availabilityZone( @javax.annotation.Nullable String availabilityZone) { this.availabilityZone = availabilityZone; @@ -308,9 +332,9 @@ public CreateServerPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -399,7 +423,7 @@ public void setName(@javax.annotation.Nonnull String name) { } public CreateServerPayload networking( - @javax.annotation.Nullable CreateServerPayloadNetworking networking) { + @javax.annotation.Nonnull CreateServerPayloadAllOfNetworking networking) { this.networking = networking; return this; } @@ -409,11 +433,13 @@ public CreateServerPayload networking( * * @return networking */ - @javax.annotation.Nullable public CreateServerPayloadNetworking getNetworking() { + @javax.annotation.Nonnull + public CreateServerPayloadAllOfNetworking getNetworking() { return networking; } - public void setNetworking(@javax.annotation.Nullable CreateServerPayloadNetworking networking) { + public void setNetworking( + @javax.annotation.Nonnull CreateServerPayloadAllOfNetworking networking) { this.networking = networking; } @@ -571,6 +597,7 @@ public boolean equals(Object o) { } CreateServerPayload createServerPayload = (CreateServerPayload) o; return Objects.equals(this.affinityGroup, createServerPayload.affinityGroup) + && Objects.equals(this.agent, createServerPayload.agent) && Objects.equals(this.availabilityZone, createServerPayload.availabilityZone) && Objects.equals(this.bootVolume, createServerPayload.bootVolume) && Objects.equals(this.createdAt, createServerPayload.createdAt) @@ -599,6 +626,7 @@ public boolean equals(Object o) { public int hashCode() { return Objects.hash( affinityGroup, + agent, availabilityZone, bootVolume, createdAt, @@ -628,6 +656,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class CreateServerPayload {\n"); sb.append(" affinityGroup: ").append(toIndentedString(affinityGroup)).append("\n"); + sb.append(" agent: ").append(toIndentedString(agent)).append("\n"); sb.append(" availabilityZone: ").append(toIndentedString(availabilityZone)).append("\n"); sb.append(" bootVolume: ").append(toIndentedString(bootVolume)).append("\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); @@ -678,6 +707,7 @@ private String toIndentedString(Object o) { new HashSet( Arrays.asList( "affinityGroup", + "agent", "availabilityZone", "bootVolume", "createdAt", @@ -702,7 +732,8 @@ private String toIndentedString(Object o) { "volumes")); // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(Arrays.asList("machineType", "name")); + openapiRequiredFields = + new HashSet(Arrays.asList("machineType", "name", "networking")); } /** @@ -750,6 +781,10 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti "Expected the field `affinityGroup` to be a primitive type in the JSON string but got `%s`", jsonObj.get("affinityGroup").toString())); } + // validate the optional field `agent` + if (jsonObj.get("agent") != null && !jsonObj.get("agent").isJsonNull()) { + ServerAgent.validateJsonElement(jsonObj.get("agent")); + } if ((jsonObj.get("availabilityZone") != null && !jsonObj.get("availabilityZone").isJsonNull()) && !jsonObj.get("availabilityZone").isJsonPrimitive()) { @@ -807,10 +842,8 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti "Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); } - // validate the optional field `networking` - if (jsonObj.get("networking") != null && !jsonObj.get("networking").isJsonNull()) { - CreateServerPayloadNetworking.validateJsonElement(jsonObj.get("networking")); - } + // validate the required field `networking` + CreateServerPayloadAllOfNetworking.validateJsonElement(jsonObj.get("networking")); if (jsonObj.get("nics") != null && !jsonObj.get("nics").isJsonNull()) { JsonArray jsonArraynics = jsonObj.getAsJsonArray("nics"); if (jsonArraynics != null) { diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerPayloadAllOfNetworking.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerPayloadAllOfNetworking.java new file mode 100644 index 0000000..629610e --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerPayloadAllOfNetworking.java @@ -0,0 +1,294 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; + +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class CreateServerPayloadAllOfNetworking extends AbstractOpenApiSchema { + private static final Logger log = + Logger.getLogger(CreateServerPayloadAllOfNetworking.class.getName()); + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!CreateServerPayloadAllOfNetworking.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'CreateServerPayloadAllOfNetworking' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter adapterCreateServerNetworking = + gson.getDelegateAdapter(this, TypeToken.get(CreateServerNetworking.class)); + final TypeAdapter + adapterCreateServerNetworkingWithNics = + gson.getDelegateAdapter( + this, TypeToken.get(CreateServerNetworkingWithNics.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, CreateServerPayloadAllOfNetworking value) + throws IOException { + if (value == null || value.getActualInstance() == null) { + elementAdapter.write(out, null); + return; + } + + // check if the actual instance is of the type `CreateServerNetworking` + if (value.getActualInstance() instanceof CreateServerNetworking) { + JsonElement element = + adapterCreateServerNetworking.toJsonTree( + (CreateServerNetworking) value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + // check if the actual instance is of the type + // `CreateServerNetworkingWithNics` + if (value.getActualInstance() + instanceof CreateServerNetworkingWithNics) { + JsonElement element = + adapterCreateServerNetworkingWithNics.toJsonTree( + (CreateServerNetworkingWithNics) + value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + throw new IOException( + "Failed to serialize as the type doesn't match oneOf schemas: CreateServerNetworking, CreateServerNetworkingWithNics"); + } + + @Override + public CreateServerPayloadAllOfNetworking read(JsonReader in) + throws IOException { + Object deserialized = null; + JsonElement jsonElement = elementAdapter.read(in); + + int match = 0; + ArrayList errorMessages = new ArrayList<>(); + TypeAdapter actualAdapter = elementAdapter; + + // deserialize CreateServerNetworking + try { + // validate the JSON object to see if any exception is thrown + CreateServerNetworking.validateJsonElement(jsonElement); + actualAdapter = adapterCreateServerNetworking; + match++; + log.log( + Level.FINER, + "Input data matches schema 'CreateServerNetworking'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for CreateServerNetworking failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'CreateServerNetworking'", + e); + } + // deserialize CreateServerNetworkingWithNics + try { + // validate the JSON object to see if any exception is thrown + CreateServerNetworkingWithNics.validateJsonElement(jsonElement); + actualAdapter = adapterCreateServerNetworkingWithNics; + match++; + log.log( + Level.FINER, + "Input data matches schema 'CreateServerNetworkingWithNics'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for CreateServerNetworkingWithNics failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'CreateServerNetworkingWithNics'", + e); + } + + if (match == 1) { + CreateServerPayloadAllOfNetworking ret = + new CreateServerPayloadAllOfNetworking(); + ret.setActualInstance(actualAdapter.fromJsonTree(jsonElement)); + return ret; + } + + throw new IOException( + String.format( + "Failed deserialization for CreateServerPayloadAllOfNetworking: %d classes match result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + match, errorMessages, jsonElement.toString())); + } + }.nullSafe(); + } + } + + // store a list of schema names defined in oneOf + public static final Map> schemas = new HashMap>(); + + public CreateServerPayloadAllOfNetworking() { + super("oneOf", Boolean.FALSE); + } + + public CreateServerPayloadAllOfNetworking(Object o) { + super("oneOf", Boolean.FALSE); + setActualInstance(o); + } + + static { + schemas.put("CreateServerNetworking", CreateServerNetworking.class); + schemas.put("CreateServerNetworkingWithNics", CreateServerNetworkingWithNics.class); + } + + @Override + public Map> getSchemas() { + return CreateServerPayloadAllOfNetworking.schemas; + } + + /** + * Set the instance that matches the oneOf child schema, check the instance parameter is valid + * against the oneOf child schemas: CreateServerNetworking, CreateServerNetworkingWithNics + * + *

It could be an instance of the 'oneOf' schemas. + */ + @Override + public void setActualInstance(Object instance) { + if (instance instanceof CreateServerNetworking) { + super.setActualInstance(instance); + return; + } + + if (instance instanceof CreateServerNetworkingWithNics) { + super.setActualInstance(instance); + return; + } + + throw new RuntimeException( + "Invalid instance type. Must be CreateServerNetworking, CreateServerNetworkingWithNics"); + } + + /** + * Get the actual instance, which can be the following: CreateServerNetworking, + * CreateServerNetworkingWithNics + * + * @return The actual instance (CreateServerNetworking, CreateServerNetworkingWithNics) + */ + @SuppressWarnings("unchecked") + @Override + public Object getActualInstance() { + return super.getActualInstance(); + } + + /** + * Get the actual instance of `CreateServerNetworking`. If the actual instance is not + * `CreateServerNetworking`, the ClassCastException will be thrown. + * + * @return The actual instance of `CreateServerNetworking` + * @throws ClassCastException if the instance is not `CreateServerNetworking` + */ + public CreateServerNetworking getCreateServerNetworking() throws ClassCastException { + return (CreateServerNetworking) super.getActualInstance(); + } + + /** + * Get the actual instance of `CreateServerNetworkingWithNics`. If the actual instance is not + * `CreateServerNetworkingWithNics`, the ClassCastException will be thrown. + * + * @return The actual instance of `CreateServerNetworkingWithNics` + * @throws ClassCastException if the instance is not `CreateServerNetworkingWithNics` + */ + public CreateServerNetworkingWithNics getCreateServerNetworkingWithNics() + throws ClassCastException { + return (CreateServerNetworkingWithNics) super.getActualInstance(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * CreateServerPayloadAllOfNetworking + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + // validate oneOf schemas one by one + int validCount = 0; + ArrayList errorMessages = new ArrayList<>(); + // validate the json string with CreateServerNetworking + try { + CreateServerNetworking.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for CreateServerNetworking failed with `%s`.", + e.getMessage())); + // continue to the next one + } + // validate the json string with CreateServerNetworkingWithNics + try { + CreateServerNetworkingWithNics.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for CreateServerNetworkingWithNics failed with `%s`.", + e.getMessage())); + // continue to the next one + } + if (validCount != 1) { + throw new IOException( + String.format( + "The JSON string is invalid for CreateServerPayloadAllOfNetworking with oneOf schemas: CreateServerNetworking, CreateServerNetworkingWithNics. %d class(es) match the result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + validCount, errorMessages, jsonElement.toString())); + } + } + + /** + * Create an instance of CreateServerPayloadAllOfNetworking given an JSON string + * + * @param jsonString JSON string + * @return An instance of CreateServerPayloadAllOfNetworking + * @throws IOException if the JSON string is invalid with respect to + * CreateServerPayloadAllOfNetworking + */ + public static CreateServerPayloadAllOfNetworking fromJson(String jsonString) + throws IOException { + return JSON.getGson().fromJson(jsonString, CreateServerPayloadAllOfNetworking.class); + } + + /** + * Convert an instance of CreateServerPayloadAllOfNetworking to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateVolumePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateVolumePayload.java index 1d2f993..66be34b 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateVolumePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateVolumePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -257,9 +257,9 @@ public CreateVolumePayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv4.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv4.java new file mode 100644 index 0000000..7cc98d4 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv4.java @@ -0,0 +1,240 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** IPv4 Classless Inter-Domain Routing (CIDR) Object. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class DestinationCIDRv4 { + public static final String SERIALIZED_NAME_TYPE = "type"; + + @SerializedName(SERIALIZED_NAME_TYPE) + @javax.annotation.Nonnull + private String type; + + public static final String SERIALIZED_NAME_VALUE = "value"; + + @SerializedName(SERIALIZED_NAME_VALUE) + @javax.annotation.Nonnull + private String value; + + public DestinationCIDRv4() {} + + public DestinationCIDRv4 type(@javax.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * Get type + * + * @return type + */ + @javax.annotation.Nonnull + public String getType() { + return type; + } + + public void setType(@javax.annotation.Nonnull String type) { + this.type = type; + } + + public DestinationCIDRv4 value(@javax.annotation.Nonnull String value) { + this.value = value; + return this; + } + + /** + * An CIDRv4 string. + * + * @return value + */ + @javax.annotation.Nonnull + public String getValue() { + return value; + } + + public void setValue(@javax.annotation.Nonnull String value) { + this.value = value; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + DestinationCIDRv4 destinationCIDRv4 = (DestinationCIDRv4) o; + return Objects.equals(this.type, destinationCIDRv4.type) + && Objects.equals(this.value, destinationCIDRv4.value); + } + + @Override + public int hashCode() { + return Objects.hash(type, value); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class DestinationCIDRv4 {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("type", "value")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("type", "value")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to DestinationCIDRv4 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!DestinationCIDRv4.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in DestinationCIDRv4 is not found in the empty JSON string", + DestinationCIDRv4.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!DestinationCIDRv4.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `DestinationCIDRv4` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : DestinationCIDRv4.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if (!jsonObj.get("type").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `type` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("type").toString())); + } + if (!jsonObj.get("value").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `value` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("value").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!DestinationCIDRv4.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'DestinationCIDRv4' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(DestinationCIDRv4.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, DestinationCIDRv4 value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public DestinationCIDRv4 read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of DestinationCIDRv4 given an JSON string + * + * @param jsonString JSON string + * @return An instance of DestinationCIDRv4 + * @throws IOException if the JSON string is invalid with respect to DestinationCIDRv4 + */ + public static DestinationCIDRv4 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, DestinationCIDRv4.class); + } + + /** + * Convert an instance of DestinationCIDRv4 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv6.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv6.java new file mode 100644 index 0000000..dbb5dd5 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv6.java @@ -0,0 +1,240 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** IPv6 Classless Inter-Domain Routing (CIDR) Object. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class DestinationCIDRv6 { + public static final String SERIALIZED_NAME_TYPE = "type"; + + @SerializedName(SERIALIZED_NAME_TYPE) + @javax.annotation.Nonnull + private String type; + + public static final String SERIALIZED_NAME_VALUE = "value"; + + @SerializedName(SERIALIZED_NAME_VALUE) + @javax.annotation.Nonnull + private String value; + + public DestinationCIDRv6() {} + + public DestinationCIDRv6 type(@javax.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * Get type + * + * @return type + */ + @javax.annotation.Nonnull + public String getType() { + return type; + } + + public void setType(@javax.annotation.Nonnull String type) { + this.type = type; + } + + public DestinationCIDRv6 value(@javax.annotation.Nonnull String value) { + this.value = value; + return this; + } + + /** + * An CIDRv6 string. + * + * @return value + */ + @javax.annotation.Nonnull + public String getValue() { + return value; + } + + public void setValue(@javax.annotation.Nonnull String value) { + this.value = value; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + DestinationCIDRv6 destinationCIDRv6 = (DestinationCIDRv6) o; + return Objects.equals(this.type, destinationCIDRv6.type) + && Objects.equals(this.value, destinationCIDRv6.value); + } + + @Override + public int hashCode() { + return Objects.hash(type, value); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class DestinationCIDRv6 {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("type", "value")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("type", "value")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to DestinationCIDRv6 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!DestinationCIDRv6.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in DestinationCIDRv6 is not found in the empty JSON string", + DestinationCIDRv6.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!DestinationCIDRv6.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `DestinationCIDRv6` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : DestinationCIDRv6.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if (!jsonObj.get("type").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `type` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("type").toString())); + } + if (!jsonObj.get("value").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `value` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("value").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!DestinationCIDRv6.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'DestinationCIDRv6' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(DestinationCIDRv6.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, DestinationCIDRv6 value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public DestinationCIDRv6 read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of DestinationCIDRv6 given an JSON string + * + * @param jsonString JSON string + * @return An instance of DestinationCIDRv6 + * @throws IOException if the JSON string is invalid with respect to DestinationCIDRv6 + */ + public static DestinationCIDRv6 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, DestinationCIDRv6.class); + } + + /** + * Convert an instance of DestinationCIDRv6 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Error.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Error.java index 58ca9d0..ce42c2b 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Error.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Error.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/GetServerLog200Response.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/GetServerLog200Response.java index 1937680..b9f508c 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/GetServerLog200Response.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/GetServerLog200Response.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ICMPParameters.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ICMPParameters.java index 60b8169..21d517b 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ICMPParameters.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ICMPParameters.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Image.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Image.java index 3c794dd..a54f085 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Image.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Image.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -232,9 +232,9 @@ public Image labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageAgent.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageAgent.java index 3ae646a..4227388 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageAgent.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageAgent.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageChecksum.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageChecksum.java index 3205f1f..ec10130 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageChecksum.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageChecksum.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageConfig.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageConfig.java index eac3891..7246214 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageConfig.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageConfig.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageCreateResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageCreateResponse.java index ae688d0..c739a3f 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageCreateResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageCreateResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageListResponse.java index 4301a06..32f1f7e 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageShare.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageShare.java index 09dfac1..11d2669 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageShare.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageShare.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageShareConsumer.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageShareConsumer.java index ce60399..3494abe 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageShareConsumer.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageShareConsumer.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/KeyPairListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/KeyPairListResponse.java index 887372f..61846d5 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/KeyPairListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/KeyPairListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Keypair.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Keypair.java index f8da10e..3fe12b1 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Keypair.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Keypair.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -100,9 +100,9 @@ public Keypair labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineType.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineType.java index e0a0a8a..86ec502 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineType.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineType.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineTypeListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineTypeListResponse.java index 59d7aa4..cdb2325 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineTypeListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineTypeListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRoute.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRoute.java new file mode 100644 index 0000000..48c828f --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRoute.java @@ -0,0 +1,333 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.time.OffsetDateTime; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import java.util.UUID; + +/** Object represents a management network route (IPv6 only). */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class ManagementRoute { + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + + @SerializedName(SERIALIZED_NAME_CREATED_AT) + @javax.annotation.Nullable private OffsetDateTime createdAt; + + public static final String SERIALIZED_NAME_DESTINATION = "destination"; + + @SerializedName(SERIALIZED_NAME_DESTINATION) + @javax.annotation.Nonnull + private ManagementRouteDestination destination; + + public static final String SERIALIZED_NAME_ID = "id"; + + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nullable private UUID id; + + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public static final String SERIALIZED_NAME_NEXTHOP = "nexthop"; + + @SerializedName(SERIALIZED_NAME_NEXTHOP) + @javax.annotation.Nonnull + private ManagementRouteNexthop nexthop; + + public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; + + @SerializedName(SERIALIZED_NAME_UPDATED_AT) + @javax.annotation.Nullable private OffsetDateTime updatedAt; + + public ManagementRoute() {} + + public ManagementRoute(OffsetDateTime createdAt, UUID id, OffsetDateTime updatedAt) { + this(); + this.createdAt = createdAt; + this.id = id; + this.updatedAt = updatedAt; + } + + /** + * Date-time when resource was created. + * + * @return createdAt + */ + @javax.annotation.Nullable public OffsetDateTime getCreatedAt() { + return createdAt; + } + + public ManagementRoute destination( + @javax.annotation.Nonnull ManagementRouteDestination destination) { + this.destination = destination; + return this; + } + + /** + * Get destination + * + * @return destination + */ + @javax.annotation.Nonnull + public ManagementRouteDestination getDestination() { + return destination; + } + + public void setDestination(@javax.annotation.Nonnull ManagementRouteDestination destination) { + this.destination = destination; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return id + */ + @javax.annotation.Nullable public UUID getId() { + return id; + } + + public ManagementRoute labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + public ManagementRoute nexthop(@javax.annotation.Nonnull ManagementRouteNexthop nexthop) { + this.nexthop = nexthop; + return this; + } + + /** + * Get nexthop + * + * @return nexthop + */ + @javax.annotation.Nonnull + public ManagementRouteNexthop getNexthop() { + return nexthop; + } + + public void setNexthop(@javax.annotation.Nonnull ManagementRouteNexthop nexthop) { + this.nexthop = nexthop; + } + + /** + * Date-time when resource was last updated. + * + * @return updatedAt + */ + @javax.annotation.Nullable public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ManagementRoute managementRoute = (ManagementRoute) o; + return Objects.equals(this.createdAt, managementRoute.createdAt) + && Objects.equals(this.destination, managementRoute.destination) + && Objects.equals(this.id, managementRoute.id) + && Objects.equals(this.labels, managementRoute.labels) + && Objects.equals(this.nexthop, managementRoute.nexthop) + && Objects.equals(this.updatedAt, managementRoute.updatedAt); + } + + @Override + public int hashCode() { + return Objects.hash(createdAt, destination, id, labels, nexthop, updatedAt); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ManagementRoute {\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" destination: ").append(toIndentedString(destination)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append(" nexthop: ").append(toIndentedString(nexthop)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = + new HashSet( + Arrays.asList( + "createdAt", + "destination", + "id", + "labels", + "nexthop", + "updatedAt")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("destination", "nexthop")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to ManagementRoute + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!ManagementRoute.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in ManagementRoute is not found in the empty JSON string", + ManagementRoute.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!ManagementRoute.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `ManagementRoute` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : ManagementRoute.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // validate the required field `destination` + ManagementRouteDestination.validateJsonElement(jsonObj.get("destination")); + if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) + && !jsonObj.get("id").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); + } + // validate the required field `nexthop` + ManagementRouteNexthop.validateJsonElement(jsonObj.get("nexthop")); + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ManagementRoute.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ManagementRoute' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(ManagementRoute.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, ManagementRoute value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public ManagementRoute read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of ManagementRoute given an JSON string + * + * @param jsonString JSON string + * @return An instance of ManagementRoute + * @throws IOException if the JSON string is invalid with respect to ManagementRoute + */ + public static ManagementRoute fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ManagementRoute.class); + } + + /** + * Convert an instance of ManagementRoute to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteDestination.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteDestination.java new file mode 100644 index 0000000..f79638f --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteDestination.java @@ -0,0 +1,230 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** ManagementRouteDestination */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class ManagementRouteDestination { + public static final String SERIALIZED_NAME_TYPE = "type"; + + @SerializedName(SERIALIZED_NAME_TYPE) + @javax.annotation.Nonnull + protected String type; + + public static final String SERIALIZED_NAME_VALUE = "value"; + + @SerializedName(SERIALIZED_NAME_VALUE) + @javax.annotation.Nonnull + private String value; + + public ManagementRouteDestination() { + this.type = this.getClass().getSimpleName(); + } + + public ManagementRouteDestination type(@javax.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * Get type + * + * @return type + */ + @javax.annotation.Nonnull + public String getType() { + return type; + } + + public void setType(@javax.annotation.Nonnull String type) { + this.type = type; + } + + public ManagementRouteDestination value(@javax.annotation.Nonnull String value) { + this.value = value; + return this; + } + + /** + * An CIDRv6 string. + * + * @return value + */ + @javax.annotation.Nonnull + public String getValue() { + return value; + } + + public void setValue(@javax.annotation.Nonnull String value) { + this.value = value; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ManagementRouteDestination managementRouteDestination = (ManagementRouteDestination) o; + return Objects.equals(this.type, managementRouteDestination.type) + && Objects.equals(this.value, managementRouteDestination.value); + } + + @Override + public int hashCode() { + return Objects.hash(type, value); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ManagementRouteDestination {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("type", "value")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("type", "value")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to ManagementRouteDestination + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!ManagementRouteDestination.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in ManagementRouteDestination is not found in the empty JSON string", + ManagementRouteDestination.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!ManagementRouteDestination.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `ManagementRouteDestination` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : ManagementRouteDestination.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ManagementRouteDestination.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ManagementRouteDestination' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(ManagementRouteDestination.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, ManagementRouteDestination value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public ManagementRouteDestination read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of ManagementRouteDestination given an JSON string + * + * @param jsonString JSON string + * @return An instance of ManagementRouteDestination + * @throws IOException if the JSON string is invalid with respect to ManagementRouteDestination + */ + public static ManagementRouteDestination fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ManagementRouteDestination.class); + } + + /** + * Convert an instance of ManagementRouteDestination to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteListResponse.java new file mode 100644 index 0000000..e975db8 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteListResponse.java @@ -0,0 +1,229 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonArray; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Management route list response. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class ManagementRouteListResponse { + public static final String SERIALIZED_NAME_ITEMS = "items"; + + @SerializedName(SERIALIZED_NAME_ITEMS) + @javax.annotation.Nonnull + private List items = new ArrayList<>(); + + public ManagementRouteListResponse() {} + + public ManagementRouteListResponse items( + @javax.annotation.Nonnull List items) { + this.items = items; + return this; + } + + public ManagementRouteListResponse addItemsItem(ManagementRoute itemsItem) { + if (this.items == null) { + this.items = new ArrayList<>(); + } + this.items.add(itemsItem); + return this; + } + + /** + * A list of management routes. + * + * @return items + */ + @javax.annotation.Nonnull + public List getItems() { + return items; + } + + public void setItems(@javax.annotation.Nonnull List items) { + this.items = items; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ManagementRouteListResponse managementRouteListResponse = (ManagementRouteListResponse) o; + return Objects.equals(this.items, managementRouteListResponse.items); + } + + @Override + public int hashCode() { + return Objects.hash(items); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ManagementRouteListResponse {\n"); + sb.append(" items: ").append(toIndentedString(items)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("items")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("items")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * ManagementRouteListResponse + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!ManagementRouteListResponse.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in ManagementRouteListResponse is not found in the empty JSON string", + ManagementRouteListResponse.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!ManagementRouteListResponse.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `ManagementRouteListResponse` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : ManagementRouteListResponse.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the json data is an array + if (!jsonObj.get("items").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `items` to be an array in the JSON string but got `%s`", + jsonObj.get("items").toString())); + } + + JsonArray jsonArrayitems = jsonObj.getAsJsonArray("items"); + // validate the required field `items` (array) + for (int i = 0; i < jsonArrayitems.size(); i++) { + ManagementRoute.validateJsonElement(jsonArrayitems.get(i)); + } + ; + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ManagementRouteListResponse.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ManagementRouteListResponse' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(ManagementRouteListResponse.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, ManagementRouteListResponse value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public ManagementRouteListResponse read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of ManagementRouteListResponse given an JSON string + * + * @param jsonString JSON string + * @return An instance of ManagementRouteListResponse + * @throws IOException if the JSON string is invalid with respect to ManagementRouteListResponse + */ + public static ManagementRouteListResponse fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ManagementRouteListResponse.class); + } + + /** + * Convert an instance of ManagementRouteListResponse to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteNexthop.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteNexthop.java new file mode 100644 index 0000000..271a4c1 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteNexthop.java @@ -0,0 +1,229 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** ManagementRouteNexthop */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class ManagementRouteNexthop { + public static final String SERIALIZED_NAME_TYPE = "type"; + + @SerializedName(SERIALIZED_NAME_TYPE) + @javax.annotation.Nonnull + protected String type; + + public static final String SERIALIZED_NAME_VALUE = "value"; + + @SerializedName(SERIALIZED_NAME_VALUE) + @javax.annotation.Nonnull + private String value; + + public ManagementRouteNexthop() { + this.type = this.getClass().getSimpleName(); + } + + public ManagementRouteNexthop type(@javax.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * Get type + * + * @return type + */ + @javax.annotation.Nonnull + public String getType() { + return type; + } + + public void setType(@javax.annotation.Nonnull String type) { + this.type = type; + } + + public ManagementRouteNexthop value(@javax.annotation.Nonnull String value) { + this.value = value; + return this; + } + + /** + * An IPv6 address. + * + * @return value + */ + @javax.annotation.Nonnull + public String getValue() { + return value; + } + + public void setValue(@javax.annotation.Nonnull String value) { + this.value = value; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ManagementRouteNexthop managementRouteNexthop = (ManagementRouteNexthop) o; + return Objects.equals(this.type, managementRouteNexthop.type) + && Objects.equals(this.value, managementRouteNexthop.value); + } + + @Override + public int hashCode() { + return Objects.hash(type, value); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ManagementRouteNexthop {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("type", "value")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("type", "value")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to ManagementRouteNexthop + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!ManagementRouteNexthop.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in ManagementRouteNexthop is not found in the empty JSON string", + ManagementRouteNexthop.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!ManagementRouteNexthop.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `ManagementRouteNexthop` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : ManagementRouteNexthop.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ManagementRouteNexthop.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ManagementRouteNexthop' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(ManagementRouteNexthop.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, ManagementRouteNexthop value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public ManagementRouteNexthop read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of ManagementRouteNexthop given an JSON string + * + * @param jsonString JSON string + * @return An instance of ManagementRouteNexthop + * @throws IOException if the JSON string is invalid with respect to ManagementRouteNexthop + */ + public static ManagementRouteNexthop fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ManagementRouteNexthop.class); + } + + /** + * Convert an instance of ManagementRouteNexthop to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NIC.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NIC.java index d5871f3..d5a88ef 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NIC.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NIC.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -43,6 +43,11 @@ public class NIC { @SerializedName(SERIALIZED_NAME_ALLOWED_ADDRESSES) @javax.annotation.Nullable private List allowedAddresses = new ArrayList<>(); + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + @javax.annotation.Nullable private String description; + public static final String SERIALIZED_NAME_DEVICE = "device"; @SerializedName(SERIALIZED_NAME_DEVICE) @@ -143,6 +148,24 @@ public void setAllowedAddresses( this.allowedAddresses = allowedAddresses; } + public NIC description(@javax.annotation.Nullable String description) { + this.description = description; + return this; + } + + /** + * Description Object. Allows string up to 255 Characters. + * + * @return description + */ + @javax.annotation.Nullable public String getDescription() { + return description; + } + + public void setDescription(@javax.annotation.Nullable String description) { + this.description = description; + } + /** * Universally Unique Identifier (UUID). * @@ -204,9 +227,9 @@ public NIC labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -327,6 +350,7 @@ public boolean equals(Object o) { } NIC NIC = (NIC) o; return Objects.equals(this.allowedAddresses, NIC.allowedAddresses) + && Objects.equals(this.description, NIC.description) && Objects.equals(this.device, NIC.device) && Objects.equals(this.id, NIC.id) && Objects.equals(this.ipv4, NIC.ipv4) @@ -345,6 +369,7 @@ public boolean equals(Object o) { public int hashCode() { return Objects.hash( allowedAddresses, + description, device, id, ipv4, @@ -364,6 +389,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class NIC {\n"); sb.append(" allowedAddresses: ").append(toIndentedString(allowedAddresses)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" device: ").append(toIndentedString(device)).append("\n"); sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); @@ -400,6 +426,7 @@ private String toIndentedString(Object o) { new HashSet( Arrays.asList( "allowedAddresses", + "description", "device", "id", "ipv4", @@ -464,6 +491,13 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti ; } } + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) + && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `description` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("description").toString())); + } if ((jsonObj.get("device") != null && !jsonObj.get("device").isJsonNull()) && !jsonObj.get("device").isJsonPrimitive()) { throw new IllegalArgumentException( diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NICListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NICListResponse.java index 3210f01..b48b12a 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NICListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NICListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Network.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Network.java index 921c01e..cd89bb7 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Network.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Network.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -24,17 +24,17 @@ import com.google.gson.stream.JsonWriter; import java.io.IOException; import java.time.OffsetDateTime; -import java.util.ArrayList; import java.util.Arrays; import java.util.HashSet; -import java.util.List; import java.util.Map; import java.util.Objects; import java.util.Set; import java.util.UUID; -import org.openapitools.jackson.nullable.JsonNullable; -/** Object that represents a network. */ +/** + * Object that represents a network. If no routing table is specified, the default routing table is + * used. + */ @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") @@ -49,15 +49,21 @@ public class Network { @SerializedName(SERIALIZED_NAME_DHCP) @javax.annotation.Nullable private Boolean dhcp; - public static final String SERIALIZED_NAME_GATEWAY = "gateway"; + public static final String SERIALIZED_NAME_ID = "id"; + + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nonnull + private UUID id; - @SerializedName(SERIALIZED_NAME_GATEWAY) - @javax.annotation.Nullable private String gateway; + public static final String SERIALIZED_NAME_IPV4 = "ipv4"; - public static final String SERIALIZED_NAME_GATEWAYV6 = "gatewayv6"; + @SerializedName(SERIALIZED_NAME_IPV4) + @javax.annotation.Nullable private NetworkIPv4 ipv4; - @SerializedName(SERIALIZED_NAME_GATEWAYV6) - @javax.annotation.Nullable private String gatewayv6; + public static final String SERIALIZED_NAME_IPV6 = "ipv6"; + + @SerializedName(SERIALIZED_NAME_IPV6) + @javax.annotation.Nullable private NetworkIPv6 ipv6; public static final String SERIALIZED_NAME_LABELS = "labels"; @@ -70,47 +76,21 @@ public class Network { @javax.annotation.Nonnull private String name; - public static final String SERIALIZED_NAME_NAMESERVERS = "nameservers"; - - @SerializedName(SERIALIZED_NAME_NAMESERVERS) - @javax.annotation.Nullable private List nameservers = new ArrayList<>(); - - public static final String SERIALIZED_NAME_NAMESERVERS_V6 = "nameserversV6"; - - @SerializedName(SERIALIZED_NAME_NAMESERVERS_V6) - @javax.annotation.Nullable private List nameserversV6 = new ArrayList<>(); - - public static final String SERIALIZED_NAME_NETWORK_ID = "networkId"; - - @SerializedName(SERIALIZED_NAME_NETWORK_ID) - @javax.annotation.Nonnull - private UUID networkId; - - public static final String SERIALIZED_NAME_PREFIXES = "prefixes"; - - @SerializedName(SERIALIZED_NAME_PREFIXES) - @javax.annotation.Nullable private List prefixes = new ArrayList<>(); - - public static final String SERIALIZED_NAME_PREFIXES_V6 = "prefixesV6"; - - @SerializedName(SERIALIZED_NAME_PREFIXES_V6) - @javax.annotation.Nullable private List prefixesV6 = new ArrayList<>(); - - public static final String SERIALIZED_NAME_PUBLIC_IP = "publicIp"; - - @SerializedName(SERIALIZED_NAME_PUBLIC_IP) - @javax.annotation.Nullable private String publicIp; - public static final String SERIALIZED_NAME_ROUTED = "routed"; @SerializedName(SERIALIZED_NAME_ROUTED) @javax.annotation.Nullable private Boolean routed; - public static final String SERIALIZED_NAME_STATE = "state"; + public static final String SERIALIZED_NAME_ROUTING_TABLE_ID = "routingTableId"; + + @SerializedName(SERIALIZED_NAME_ROUTING_TABLE_ID) + @javax.annotation.Nullable private UUID routingTableId; - @SerializedName(SERIALIZED_NAME_STATE) + public static final String SERIALIZED_NAME_STATUS = "status"; + + @SerializedName(SERIALIZED_NAME_STATUS) @javax.annotation.Nonnull - private String state; + private String status; public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; @@ -152,42 +132,59 @@ public void setDhcp(@javax.annotation.Nullable Boolean dhcp) { this.dhcp = dhcp; } - public Network gateway(@javax.annotation.Nullable String gateway) { - this.gateway = gateway; + public Network id(@javax.annotation.Nonnull UUID id) { + this.id = id; return this; } /** - * The gateway of a network. If not specified the first IP of the network will be assigned as - * the gateway. If 'null' is sent, then the network doesn't have a gateway. + * Universally Unique Identifier (UUID). * - * @return gateway + * @return id */ - @javax.annotation.Nullable public String getGateway() { - return gateway; + @javax.annotation.Nonnull + public UUID getId() { + return id; } - public void setGateway(@javax.annotation.Nullable String gateway) { - this.gateway = gateway; + public void setId(@javax.annotation.Nonnull UUID id) { + this.id = id; } - public Network gatewayv6(@javax.annotation.Nullable String gatewayv6) { - this.gatewayv6 = gatewayv6; + public Network ipv4(@javax.annotation.Nullable NetworkIPv4 ipv4) { + this.ipv4 = ipv4; return this; } /** - * The gateway of a network. If not specified the first IP of the network will be assigned as - * the gateway. If 'null' is sent, then the network doesn't have a gateway. + * Get ipv4 * - * @return gatewayv6 + * @return ipv4 */ - @javax.annotation.Nullable public String getGatewayv6() { - return gatewayv6; + @javax.annotation.Nullable public NetworkIPv4 getIpv4() { + return ipv4; } - public void setGatewayv6(@javax.annotation.Nullable String gatewayv6) { - this.gatewayv6 = gatewayv6; + public void setIpv4(@javax.annotation.Nullable NetworkIPv4 ipv4) { + this.ipv4 = ipv4; + } + + public Network ipv6(@javax.annotation.Nullable NetworkIPv6 ipv6) { + this.ipv6 = ipv6; + return this; + } + + /** + * Get ipv6 + * + * @return ipv6 + */ + @javax.annotation.Nullable public NetworkIPv6 getIpv6() { + return ipv6; + } + + public void setIpv6(@javax.annotation.Nullable NetworkIPv6 ipv6) { + this.ipv6 = ipv6; } public Network labels(@javax.annotation.Nullable Object labels) { @@ -197,9 +194,9 @@ public Network labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -230,167 +227,44 @@ public void setName(@javax.annotation.Nonnull String name) { this.name = name; } - public Network nameservers(@javax.annotation.Nullable List nameservers) { - this.nameservers = nameservers; - return this; - } - - public Network addNameserversItem(String nameserversItem) { - if (this.nameservers == null) { - this.nameservers = new ArrayList<>(); - } - this.nameservers.add(nameserversItem); - return this; - } - - /** - * A list containing DNS Servers/Nameservers for IPv4. - * - * @return nameservers - */ - @javax.annotation.Nullable public List getNameservers() { - return nameservers; - } - - public void setNameservers(@javax.annotation.Nullable List nameservers) { - this.nameservers = nameservers; - } - - public Network nameserversV6(@javax.annotation.Nullable List nameserversV6) { - this.nameserversV6 = nameserversV6; - return this; - } - - public Network addNameserversV6Item(String nameserversV6Item) { - if (this.nameserversV6 == null) { - this.nameserversV6 = new ArrayList<>(); - } - this.nameserversV6.add(nameserversV6Item); + public Network routed(@javax.annotation.Nullable Boolean routed) { + this.routed = routed; return this; } /** - * A list containing DNS Servers/Nameservers for IPv6. + * Shows if the network is routed and therefore accessible from other networks. * - * @return nameserversV6 + * @return routed */ - @javax.annotation.Nullable public List getNameserversV6() { - return nameserversV6; + @javax.annotation.Nullable public Boolean getRouted() { + return routed; } - public void setNameserversV6(@javax.annotation.Nullable List nameserversV6) { - this.nameserversV6 = nameserversV6; + public void setRouted(@javax.annotation.Nullable Boolean routed) { + this.routed = routed; } - public Network networkId(@javax.annotation.Nonnull UUID networkId) { - this.networkId = networkId; + public Network routingTableId(@javax.annotation.Nullable UUID routingTableId) { + this.routingTableId = routingTableId; return this; } /** * Universally Unique Identifier (UUID). * - * @return networkId + * @return routingTableId */ - @javax.annotation.Nonnull - public UUID getNetworkId() { - return networkId; + @javax.annotation.Nullable public UUID getRoutingTableId() { + return routingTableId; } - public void setNetworkId(@javax.annotation.Nonnull UUID networkId) { - this.networkId = networkId; + public void setRoutingTableId(@javax.annotation.Nullable UUID routingTableId) { + this.routingTableId = routingTableId; } - public Network prefixes(@javax.annotation.Nullable List prefixes) { - this.prefixes = prefixes; - return this; - } - - public Network addPrefixesItem(String prefixesItem) { - if (this.prefixes == null) { - this.prefixes = new ArrayList<>(); - } - this.prefixes.add(prefixesItem); - return this; - } - - /** - * Get prefixes - * - * @return prefixes - */ - @javax.annotation.Nullable public List getPrefixes() { - return prefixes; - } - - public void setPrefixes(@javax.annotation.Nullable List prefixes) { - this.prefixes = prefixes; - } - - public Network prefixesV6(@javax.annotation.Nullable List prefixesV6) { - this.prefixesV6 = prefixesV6; - return this; - } - - public Network addPrefixesV6Item(String prefixesV6Item) { - if (this.prefixesV6 == null) { - this.prefixesV6 = new ArrayList<>(); - } - this.prefixesV6.add(prefixesV6Item); - return this; - } - - /** - * Get prefixesV6 - * - * @return prefixesV6 - */ - @javax.annotation.Nullable public List getPrefixesV6() { - return prefixesV6; - } - - public void setPrefixesV6(@javax.annotation.Nullable List prefixesV6) { - this.prefixesV6 = prefixesV6; - } - - public Network publicIp(@javax.annotation.Nullable String publicIp) { - this.publicIp = publicIp; - return this; - } - - /** - * Object that represents an IP address. - * - * @return publicIp - */ - @javax.annotation.Nullable public String getPublicIp() { - return publicIp; - } - - public void setPublicIp(@javax.annotation.Nullable String publicIp) { - this.publicIp = publicIp; - } - - public Network routed(@javax.annotation.Nullable Boolean routed) { - this.routed = routed; - return this; - } - - /** - * Shows if the network is routed and therefore accessible from other networks. - * - * @return routed - */ - @javax.annotation.Nullable public Boolean getRouted() { - return routed; - } - - public void setRouted(@javax.annotation.Nullable Boolean routed) { - this.routed = routed; - } - - public Network state(@javax.annotation.Nonnull String state) { - this.state = state; + public Network status(@javax.annotation.Nonnull String status) { + this.status = status; return this; } @@ -399,15 +273,15 @@ public Network state(@javax.annotation.Nonnull String state) { * `DELETING`, `DELETED`, `FAILED`, `UPDATED`, * `UPDATING`. * - * @return state + * @return status */ @javax.annotation.Nonnull - public String getState() { - return state; + public String getStatus() { + return status; } - public void setState(@javax.annotation.Nonnull String state) { - this.state = state; + public void setStatus(@javax.annotation.Nonnull String status) { + this.status = status; } /** @@ -430,75 +304,47 @@ public boolean equals(Object o) { Network network = (Network) o; return Objects.equals(this.createdAt, network.createdAt) && Objects.equals(this.dhcp, network.dhcp) - && Objects.equals(this.gateway, network.gateway) - && Objects.equals(this.gatewayv6, network.gatewayv6) + && Objects.equals(this.id, network.id) + && Objects.equals(this.ipv4, network.ipv4) + && Objects.equals(this.ipv6, network.ipv6) && Objects.equals(this.labels, network.labels) && Objects.equals(this.name, network.name) - && Objects.equals(this.nameservers, network.nameservers) - && Objects.equals(this.nameserversV6, network.nameserversV6) - && Objects.equals(this.networkId, network.networkId) - && Objects.equals(this.prefixes, network.prefixes) - && Objects.equals(this.prefixesV6, network.prefixesV6) - && Objects.equals(this.publicIp, network.publicIp) && Objects.equals(this.routed, network.routed) - && Objects.equals(this.state, network.state) + && Objects.equals(this.routingTableId, network.routingTableId) + && Objects.equals(this.status, network.status) && Objects.equals(this.updatedAt, network.updatedAt); } - private static boolean equalsNullable(JsonNullable a, JsonNullable b) { - return a == b - || (a != null - && b != null - && a.isPresent() - && b.isPresent() - && Objects.deepEquals(a.get(), b.get())); - } - @Override public int hashCode() { return Objects.hash( createdAt, dhcp, - gateway, - gatewayv6, + id, + ipv4, + ipv6, labels, name, - nameservers, - nameserversV6, - networkId, - prefixes, - prefixesV6, - publicIp, routed, - state, + routingTableId, + status, updatedAt); } - private static int hashCodeNullable(JsonNullable a) { - if (a == null) { - return 1; - } - return a.isPresent() ? Arrays.deepHashCode(new Object[] {a.get()}) : 31; - } - @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class Network {\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); sb.append(" dhcp: ").append(toIndentedString(dhcp)).append("\n"); - sb.append(" gateway: ").append(toIndentedString(gateway)).append("\n"); - sb.append(" gatewayv6: ").append(toIndentedString(gatewayv6)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); + sb.append(" ipv6: ").append(toIndentedString(ipv6)).append("\n"); sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); - sb.append(" nameservers: ").append(toIndentedString(nameservers)).append("\n"); - sb.append(" nameserversV6: ").append(toIndentedString(nameserversV6)).append("\n"); - sb.append(" networkId: ").append(toIndentedString(networkId)).append("\n"); - sb.append(" prefixes: ").append(toIndentedString(prefixes)).append("\n"); - sb.append(" prefixesV6: ").append(toIndentedString(prefixesV6)).append("\n"); - sb.append(" publicIp: ").append(toIndentedString(publicIp)).append("\n"); sb.append(" routed: ").append(toIndentedString(routed)).append("\n"); - sb.append(" state: ").append(toIndentedString(state)).append("\n"); + sb.append(" routingTableId: ").append(toIndentedString(routingTableId)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append("}"); return sb.toString(); @@ -525,22 +371,18 @@ private String toIndentedString(Object o) { Arrays.asList( "createdAt", "dhcp", - "gateway", - "gatewayv6", + "id", + "ipv4", + "ipv6", "labels", "name", - "nameservers", - "nameserversV6", - "networkId", - "prefixes", - "prefixesV6", - "publicIp", "routed", - "state", + "routingTableId", + "status", "updatedAt")); // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(Arrays.asList("name", "networkId", "state")); + openapiRequiredFields = new HashSet(Arrays.asList("id", "name", "status")); } /** @@ -581,19 +423,19 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } } JsonObject jsonObj = jsonElement.getAsJsonObject(); - if ((jsonObj.get("gateway") != null && !jsonObj.get("gateway").isJsonNull()) - && !jsonObj.get("gateway").isJsonPrimitive()) { + if (!jsonObj.get("id").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( - "Expected the field `gateway` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("gateway").toString())); + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); } - if ((jsonObj.get("gatewayv6") != null && !jsonObj.get("gatewayv6").isJsonNull()) - && !jsonObj.get("gatewayv6").isJsonPrimitive()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `gatewayv6` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("gatewayv6").toString())); + // validate the optional field `ipv4` + if (jsonObj.get("ipv4") != null && !jsonObj.get("ipv4").isJsonNull()) { + NetworkIPv4.validateJsonElement(jsonObj.get("ipv4")); + } + // validate the optional field `ipv6` + if (jsonObj.get("ipv6") != null && !jsonObj.get("ipv6").isJsonNull()) { + NetworkIPv6.validateJsonElement(jsonObj.get("ipv6")); } if (!jsonObj.get("name").isJsonPrimitive()) { throw new IllegalArgumentException( @@ -601,60 +443,18 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti "Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); } - // ensure the optional json data is an array if present - if (jsonObj.get("nameservers") != null - && !jsonObj.get("nameservers").isJsonNull() - && !jsonObj.get("nameservers").isJsonArray()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `nameservers` to be an array in the JSON string but got `%s`", - jsonObj.get("nameservers").toString())); - } - // ensure the optional json data is an array if present - if (jsonObj.get("nameserversV6") != null - && !jsonObj.get("nameserversV6").isJsonNull() - && !jsonObj.get("nameserversV6").isJsonArray()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `nameserversV6` to be an array in the JSON string but got `%s`", - jsonObj.get("nameserversV6").toString())); - } - if (!jsonObj.get("networkId").isJsonPrimitive()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `networkId` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("networkId").toString())); - } - // ensure the optional json data is an array if present - if (jsonObj.get("prefixes") != null - && !jsonObj.get("prefixes").isJsonNull() - && !jsonObj.get("prefixes").isJsonArray()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `prefixes` to be an array in the JSON string but got `%s`", - jsonObj.get("prefixes").toString())); - } - // ensure the optional json data is an array if present - if (jsonObj.get("prefixesV6") != null - && !jsonObj.get("prefixesV6").isJsonNull() - && !jsonObj.get("prefixesV6").isJsonArray()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `prefixesV6` to be an array in the JSON string but got `%s`", - jsonObj.get("prefixesV6").toString())); - } - if ((jsonObj.get("publicIp") != null && !jsonObj.get("publicIp").isJsonNull()) - && !jsonObj.get("publicIp").isJsonPrimitive()) { + if ((jsonObj.get("routingTableId") != null && !jsonObj.get("routingTableId").isJsonNull()) + && !jsonObj.get("routingTableId").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( - "Expected the field `publicIp` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("publicIp").toString())); + "Expected the field `routingTableId` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("routingTableId").toString())); } - if (!jsonObj.get("state").isJsonPrimitive()) { + if (!jsonObj.get("status").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( - "Expected the field `state` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("state").toString())); + "Expected the field `status` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("status").toString())); } } diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkArea.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkArea.java index 4535d73..4f97546 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkArea.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkArea.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -36,21 +36,15 @@ value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class NetworkArea { - public static final String SERIALIZED_NAME_AREA_ID = "areaId"; - - @SerializedName(SERIALIZED_NAME_AREA_ID) - @javax.annotation.Nonnull - private UUID areaId; - public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; @SerializedName(SERIALIZED_NAME_CREATED_AT) @javax.annotation.Nullable private OffsetDateTime createdAt; - public static final String SERIALIZED_NAME_IPV4 = "ipv4"; + public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_IPV4) - @javax.annotation.Nullable private NetworkAreaIPv4 ipv4; + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nullable private UUID id; public static final String SERIALIZED_NAME_LABELS = "labels"; @@ -66,14 +60,7 @@ public class NetworkArea { public static final String SERIALIZED_NAME_PROJECT_COUNT = "projectCount"; @SerializedName(SERIALIZED_NAME_PROJECT_COUNT) - @javax.annotation.Nonnull - private Long projectCount; - - public static final String SERIALIZED_NAME_STATE = "state"; - - @SerializedName(SERIALIZED_NAME_STATE) - @javax.annotation.Nonnull - private String state; + @javax.annotation.Nullable private Long projectCount; public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; @@ -82,31 +69,15 @@ public class NetworkArea { public NetworkArea() {} - public NetworkArea(OffsetDateTime createdAt, OffsetDateTime updatedAt) { + public NetworkArea( + OffsetDateTime createdAt, UUID id, Long projectCount, OffsetDateTime updatedAt) { this(); this.createdAt = createdAt; + this.id = id; + this.projectCount = projectCount; this.updatedAt = updatedAt; } - public NetworkArea areaId(@javax.annotation.Nonnull UUID areaId) { - this.areaId = areaId; - return this; - } - - /** - * Universally Unique Identifier (UUID). - * - * @return areaId - */ - @javax.annotation.Nonnull - public UUID getAreaId() { - return areaId; - } - - public void setAreaId(@javax.annotation.Nonnull UUID areaId) { - this.areaId = areaId; - } - /** * Date-time when resource was created. * @@ -116,22 +87,13 @@ public void setAreaId(@javax.annotation.Nonnull UUID areaId) { return createdAt; } - public NetworkArea ipv4(@javax.annotation.Nullable NetworkAreaIPv4 ipv4) { - this.ipv4 = ipv4; - return this; - } - /** - * Get ipv4 + * Universally Unique Identifier (UUID). * - * @return ipv4 + * @return id */ - @javax.annotation.Nullable public NetworkAreaIPv4 getIpv4() { - return ipv4; - } - - public void setIpv4(@javax.annotation.Nullable NetworkAreaIPv4 ipv4) { - this.ipv4 = ipv4; + @javax.annotation.Nullable public UUID getId() { + return id; } public NetworkArea labels(@javax.annotation.Nullable Object labels) { @@ -141,9 +103,9 @@ public NetworkArea labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -174,46 +136,15 @@ public void setName(@javax.annotation.Nonnull String name) { this.name = name; } - public NetworkArea projectCount(@javax.annotation.Nonnull Long projectCount) { - this.projectCount = projectCount; - return this; - } - /** * The amount of projects currently referencing a specific area. minimum: 0 * * @return projectCount */ - @javax.annotation.Nonnull - public Long getProjectCount() { + @javax.annotation.Nullable public Long getProjectCount() { return projectCount; } - public void setProjectCount(@javax.annotation.Nonnull Long projectCount) { - this.projectCount = projectCount; - } - - public NetworkArea state(@javax.annotation.Nonnull String state) { - this.state = state; - return this; - } - - /** - * The state of a resource object. Possible values: `CREATING`, `CREATED`, - * `DELETING`, `DELETED`, `FAILED`, `UPDATED`, - * `UPDATING`. - * - * @return state - */ - @javax.annotation.Nonnull - public String getState() { - return state; - } - - public void setState(@javax.annotation.Nonnull String state) { - this.state = state; - } - /** * Date-time when resource was last updated. * @@ -232,32 +163,28 @@ public boolean equals(Object o) { return false; } NetworkArea networkArea = (NetworkArea) o; - return Objects.equals(this.areaId, networkArea.areaId) - && Objects.equals(this.createdAt, networkArea.createdAt) - && Objects.equals(this.ipv4, networkArea.ipv4) + return Objects.equals(this.createdAt, networkArea.createdAt) + && Objects.equals(this.id, networkArea.id) && Objects.equals(this.labels, networkArea.labels) && Objects.equals(this.name, networkArea.name) && Objects.equals(this.projectCount, networkArea.projectCount) - && Objects.equals(this.state, networkArea.state) && Objects.equals(this.updatedAt, networkArea.updatedAt); } @Override public int hashCode() { - return Objects.hash(areaId, createdAt, ipv4, labels, name, projectCount, state, updatedAt); + return Objects.hash(createdAt, id, labels, name, projectCount, updatedAt); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class NetworkArea {\n"); - sb.append(" areaId: ").append(toIndentedString(areaId)).append("\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); - sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" projectCount: ").append(toIndentedString(projectCount)).append("\n"); - sb.append(" state: ").append(toIndentedString(state)).append("\n"); sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append("}"); return sb.toString(); @@ -282,18 +209,10 @@ private String toIndentedString(Object o) { openapiFields = new HashSet( Arrays.asList( - "areaId", - "createdAt", - "ipv4", - "labels", - "name", - "projectCount", - "state", - "updatedAt")); + "createdAt", "id", "labels", "name", "projectCount", "updatedAt")); // a set of required properties/fields (JSON key names) - openapiRequiredFields = - new HashSet(Arrays.asList("areaId", "name", "projectCount", "state")); + openapiRequiredFields = new HashSet(Arrays.asList("name")); } /** @@ -334,15 +253,12 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } } JsonObject jsonObj = jsonElement.getAsJsonObject(); - if (!jsonObj.get("areaId").isJsonPrimitive()) { + if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) + && !jsonObj.get("id").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( - "Expected the field `areaId` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("areaId").toString())); - } - // validate the optional field `ipv4` - if (jsonObj.get("ipv4") != null && !jsonObj.get("ipv4").isJsonNull()) { - NetworkAreaIPv4.validateJsonElement(jsonObj.get("ipv4")); + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); } if (!jsonObj.get("name").isJsonPrimitive()) { throw new IllegalArgumentException( @@ -350,12 +266,6 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti "Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); } - if (!jsonObj.get("state").isJsonPrimitive()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `state` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("state").toString())); - } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkAreaListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkAreaListResponse.java index 1916cef..ff634b7 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkAreaListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkAreaListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkIPv4.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkIPv4.java new file mode 100644 index 0000000..5d25812 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkIPv4.java @@ -0,0 +1,342 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import org.openapitools.jackson.nullable.JsonNullable; + +/** Object that represents the IPv4 part of a network. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class NetworkIPv4 { + public static final String SERIALIZED_NAME_GATEWAY = "gateway"; + + @SerializedName(SERIALIZED_NAME_GATEWAY) + @javax.annotation.Nullable private String gateway; + + public static final String SERIALIZED_NAME_NAMESERVERS = "nameservers"; + + @SerializedName(SERIALIZED_NAME_NAMESERVERS) + @javax.annotation.Nullable private List nameservers = new ArrayList<>(); + + public static final String SERIALIZED_NAME_PREFIXES = "prefixes"; + + @SerializedName(SERIALIZED_NAME_PREFIXES) + @javax.annotation.Nonnull + private List prefixes = new ArrayList<>(); + + public static final String SERIALIZED_NAME_PUBLIC_IP = "publicIp"; + + @SerializedName(SERIALIZED_NAME_PUBLIC_IP) + @javax.annotation.Nullable private String publicIp; + + public NetworkIPv4() {} + + public NetworkIPv4(String publicIp) { + this(); + this.publicIp = publicIp; + } + + public NetworkIPv4 gateway(@javax.annotation.Nullable String gateway) { + this.gateway = gateway; + return this; + } + + /** + * The IPv4 gateway of a network. If not specified the first IP of the network will be assigned + * as the gateway. If 'null' is sent, then the network doesn't have a gateway. + * + * @return gateway + */ + @javax.annotation.Nullable public String getGateway() { + return gateway; + } + + public void setGateway(@javax.annotation.Nullable String gateway) { + this.gateway = gateway; + } + + public NetworkIPv4 nameservers(@javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + return this; + } + + public NetworkIPv4 addNameserversItem(String nameserversItem) { + if (this.nameservers == null) { + this.nameservers = new ArrayList<>(); + } + this.nameservers.add(nameserversItem); + return this; + } + + /** + * A list containing DNS Servers/Nameservers for IPv4. + * + * @return nameservers + */ + @javax.annotation.Nullable public List getNameservers() { + return nameservers; + } + + public void setNameservers(@javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + } + + public NetworkIPv4 prefixes(@javax.annotation.Nonnull List prefixes) { + this.prefixes = prefixes; + return this; + } + + public NetworkIPv4 addPrefixesItem(String prefixesItem) { + if (this.prefixes == null) { + this.prefixes = new ArrayList<>(); + } + this.prefixes.add(prefixesItem); + return this; + } + + /** + * Get prefixes + * + * @return prefixes + */ + @javax.annotation.Nonnull + public List getPrefixes() { + return prefixes; + } + + public void setPrefixes(@javax.annotation.Nonnull List prefixes) { + this.prefixes = prefixes; + } + + /** + * String that represents an IPv4 address. + * + * @return publicIp + */ + @javax.annotation.Nullable public String getPublicIp() { + return publicIp; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NetworkIPv4 networkIPv4 = (NetworkIPv4) o; + return Objects.equals(this.gateway, networkIPv4.gateway) + && Objects.equals(this.nameservers, networkIPv4.nameservers) + && Objects.equals(this.prefixes, networkIPv4.prefixes) + && Objects.equals(this.publicIp, networkIPv4.publicIp); + } + + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b + || (a != null + && b != null + && a.isPresent() + && b.isPresent() + && Objects.deepEquals(a.get(), b.get())); + } + + @Override + public int hashCode() { + return Objects.hash(gateway, nameservers, prefixes, publicIp); + } + + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[] {a.get()}) : 31; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NetworkIPv4 {\n"); + sb.append(" gateway: ").append(toIndentedString(gateway)).append("\n"); + sb.append(" nameservers: ").append(toIndentedString(nameservers)).append("\n"); + sb.append(" prefixes: ").append(toIndentedString(prefixes)).append("\n"); + sb.append(" publicIp: ").append(toIndentedString(publicIp)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = + new HashSet( + Arrays.asList("gateway", "nameservers", "prefixes", "publicIp")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("prefixes")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to NetworkIPv4 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!NetworkIPv4.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in NetworkIPv4 is not found in the empty JSON string", + NetworkIPv4.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!NetworkIPv4.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `NetworkIPv4` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : NetworkIPv4.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("gateway") != null && !jsonObj.get("gateway").isJsonNull()) + && !jsonObj.get("gateway").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `gateway` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("gateway").toString())); + } + // ensure the optional json data is an array if present + if (jsonObj.get("nameservers") != null + && !jsonObj.get("nameservers").isJsonNull() + && !jsonObj.get("nameservers").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `nameservers` to be an array in the JSON string but got `%s`", + jsonObj.get("nameservers").toString())); + } + // ensure the required json array is present + if (jsonObj.get("prefixes") == null) { + throw new IllegalArgumentException( + "Expected the field `linkedContent` to be an array in the JSON string but got `null`"); + } else if (!jsonObj.get("prefixes").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `prefixes` to be an array in the JSON string but got `%s`", + jsonObj.get("prefixes").toString())); + } + if ((jsonObj.get("publicIp") != null && !jsonObj.get("publicIp").isJsonNull()) + && !jsonObj.get("publicIp").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `publicIp` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("publicIp").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!NetworkIPv4.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'NetworkIPv4' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(NetworkIPv4.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, NetworkIPv4 value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public NetworkIPv4 read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of NetworkIPv4 given an JSON string + * + * @param jsonString JSON string + * @return An instance of NetworkIPv4 + * @throws IOException if the JSON string is invalid with respect to NetworkIPv4 + */ + public static NetworkIPv4 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, NetworkIPv4.class); + } + + /** + * Convert an instance of NetworkIPv4 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkIPv6.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkIPv6.java new file mode 100644 index 0000000..a805e87 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkIPv6.java @@ -0,0 +1,312 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import org.openapitools.jackson.nullable.JsonNullable; + +/** Object that represents the IPv6 part of a network. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class NetworkIPv6 { + public static final String SERIALIZED_NAME_GATEWAY = "gateway"; + + @SerializedName(SERIALIZED_NAME_GATEWAY) + @javax.annotation.Nullable private String gateway; + + public static final String SERIALIZED_NAME_NAMESERVERS = "nameservers"; + + @SerializedName(SERIALIZED_NAME_NAMESERVERS) + @javax.annotation.Nullable private List nameservers = new ArrayList<>(); + + public static final String SERIALIZED_NAME_PREFIXES = "prefixes"; + + @SerializedName(SERIALIZED_NAME_PREFIXES) + @javax.annotation.Nonnull + private List prefixes = new ArrayList<>(); + + public NetworkIPv6() {} + + public NetworkIPv6 gateway(@javax.annotation.Nullable String gateway) { + this.gateway = gateway; + return this; + } + + /** + * The IPv6 gateway of a network. If not specified the first IP of the network will be assigned + * as the gateway. If 'null' is sent, then the network doesn't have a gateway. + * + * @return gateway + */ + @javax.annotation.Nullable public String getGateway() { + return gateway; + } + + public void setGateway(@javax.annotation.Nullable String gateway) { + this.gateway = gateway; + } + + public NetworkIPv6 nameservers(@javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + return this; + } + + public NetworkIPv6 addNameserversItem(String nameserversItem) { + if (this.nameservers == null) { + this.nameservers = new ArrayList<>(); + } + this.nameservers.add(nameserversItem); + return this; + } + + /** + * A list containing DNS Servers/Nameservers for IPv6. + * + * @return nameservers + */ + @javax.annotation.Nullable public List getNameservers() { + return nameservers; + } + + public void setNameservers(@javax.annotation.Nullable List nameservers) { + this.nameservers = nameservers; + } + + public NetworkIPv6 prefixes(@javax.annotation.Nonnull List prefixes) { + this.prefixes = prefixes; + return this; + } + + public NetworkIPv6 addPrefixesItem(String prefixesItem) { + if (this.prefixes == null) { + this.prefixes = new ArrayList<>(); + } + this.prefixes.add(prefixesItem); + return this; + } + + /** + * Get prefixes + * + * @return prefixes + */ + @javax.annotation.Nonnull + public List getPrefixes() { + return prefixes; + } + + public void setPrefixes(@javax.annotation.Nonnull List prefixes) { + this.prefixes = prefixes; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NetworkIPv6 networkIPv6 = (NetworkIPv6) o; + return Objects.equals(this.gateway, networkIPv6.gateway) + && Objects.equals(this.nameservers, networkIPv6.nameservers) + && Objects.equals(this.prefixes, networkIPv6.prefixes); + } + + private static boolean equalsNullable(JsonNullable a, JsonNullable b) { + return a == b + || (a != null + && b != null + && a.isPresent() + && b.isPresent() + && Objects.deepEquals(a.get(), b.get())); + } + + @Override + public int hashCode() { + return Objects.hash(gateway, nameservers, prefixes); + } + + private static int hashCodeNullable(JsonNullable a) { + if (a == null) { + return 1; + } + return a.isPresent() ? Arrays.deepHashCode(new Object[] {a.get()}) : 31; + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NetworkIPv6 {\n"); + sb.append(" gateway: ").append(toIndentedString(gateway)).append("\n"); + sb.append(" nameservers: ").append(toIndentedString(nameservers)).append("\n"); + sb.append(" prefixes: ").append(toIndentedString(prefixes)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("gateway", "nameservers", "prefixes")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("prefixes")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to NetworkIPv6 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!NetworkIPv6.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in NetworkIPv6 is not found in the empty JSON string", + NetworkIPv6.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!NetworkIPv6.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `NetworkIPv6` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : NetworkIPv6.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("gateway") != null && !jsonObj.get("gateway").isJsonNull()) + && !jsonObj.get("gateway").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `gateway` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("gateway").toString())); + } + // ensure the optional json data is an array if present + if (jsonObj.get("nameservers") != null + && !jsonObj.get("nameservers").isJsonNull() + && !jsonObj.get("nameservers").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `nameservers` to be an array in the JSON string but got `%s`", + jsonObj.get("nameservers").toString())); + } + // ensure the required json array is present + if (jsonObj.get("prefixes") == null) { + throw new IllegalArgumentException( + "Expected the field `linkedContent` to be an array in the JSON string but got `null`"); + } else if (!jsonObj.get("prefixes").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `prefixes` to be an array in the JSON string but got `%s`", + jsonObj.get("prefixes").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!NetworkIPv6.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'NetworkIPv6' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(NetworkIPv6.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, NetworkIPv6 value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public NetworkIPv6 read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of NetworkIPv6 given an JSON string + * + * @param jsonString JSON string + * @return An instance of NetworkIPv6 + * @throws IOException if the JSON string is invalid with respect to NetworkIPv6 + */ + public static NetworkIPv6 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, NetworkIPv6.class); + } + + /** + * Convert an instance of NetworkIPv6 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkListResponse.java index 839d776..1cb9b34 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkRange.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkRange.java index 9b98e50..e25e4ee 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkRange.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkRange.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -41,10 +41,10 @@ public class NetworkRange { @SerializedName(SERIALIZED_NAME_CREATED_AT) @javax.annotation.Nullable private OffsetDateTime createdAt; - public static final String SERIALIZED_NAME_NETWORK_RANGE_ID = "networkRangeId"; + public static final String SERIALIZED_NAME_ID = "id"; - @SerializedName(SERIALIZED_NAME_NETWORK_RANGE_ID) - @javax.annotation.Nullable private UUID networkRangeId; + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nullable private UUID id; public static final String SERIALIZED_NAME_PREFIX = "prefix"; @@ -59,10 +59,10 @@ public class NetworkRange { public NetworkRange() {} - public NetworkRange(OffsetDateTime createdAt, UUID networkRangeId, OffsetDateTime updatedAt) { + public NetworkRange(OffsetDateTime createdAt, UUID id, OffsetDateTime updatedAt) { this(); this.createdAt = createdAt; - this.networkRangeId = networkRangeId; + this.id = id; this.updatedAt = updatedAt; } @@ -78,10 +78,10 @@ public NetworkRange(OffsetDateTime createdAt, UUID networkRangeId, OffsetDateTim /** * Universally Unique Identifier (UUID). * - * @return networkRangeId + * @return id */ - @javax.annotation.Nullable public UUID getNetworkRangeId() { - return networkRangeId; + @javax.annotation.Nullable public UUID getId() { + return id; } public NetworkRange prefix(@javax.annotation.Nonnull String prefix) { @@ -122,14 +122,14 @@ public boolean equals(Object o) { } NetworkRange networkRange = (NetworkRange) o; return Objects.equals(this.createdAt, networkRange.createdAt) - && Objects.equals(this.networkRangeId, networkRange.networkRangeId) + && Objects.equals(this.id, networkRange.id) && Objects.equals(this.prefix, networkRange.prefix) && Objects.equals(this.updatedAt, networkRange.updatedAt); } @Override public int hashCode() { - return Objects.hash(createdAt, networkRangeId, prefix, updatedAt); + return Objects.hash(createdAt, id, prefix, updatedAt); } @Override @@ -137,7 +137,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class NetworkRange {\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); - sb.append(" networkRangeId: ").append(toIndentedString(networkRangeId)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" prefix: ").append(toIndentedString(prefix)).append("\n"); sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append("}"); @@ -161,8 +161,7 @@ private String toIndentedString(Object o) { static { // a set of all properties/fields (JSON key names) openapiFields = - new HashSet( - Arrays.asList("createdAt", "networkRangeId", "prefix", "updatedAt")); + new HashSet(Arrays.asList("createdAt", "id", "prefix", "updatedAt")); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(Arrays.asList("prefix")); @@ -206,12 +205,12 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } } JsonObject jsonObj = jsonElement.getAsJsonObject(); - if ((jsonObj.get("networkRangeId") != null && !jsonObj.get("networkRangeId").isJsonNull()) - && !jsonObj.get("networkRangeId").isJsonPrimitive()) { + if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) + && !jsonObj.get("id").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( - "Expected the field `networkRangeId` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("networkRangeId").toString())); + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); } if (!jsonObj.get("prefix").isJsonPrimitive()) { throw new IllegalArgumentException( diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkRangeListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkRangeListResponse.java index f9db55e..e932d5a 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkRangeListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkRangeListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopBlackhole.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopBlackhole.java new file mode 100644 index 0000000..acf42d1 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopBlackhole.java @@ -0,0 +1,207 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents a blackhole route. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class NexthopBlackhole { + public static final String SERIALIZED_NAME_TYPE = "type"; + + @SerializedName(SERIALIZED_NAME_TYPE) + @javax.annotation.Nonnull + private String type; + + public NexthopBlackhole() {} + + public NexthopBlackhole type(@javax.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * Get type + * + * @return type + */ + @javax.annotation.Nonnull + public String getType() { + return type; + } + + public void setType(@javax.annotation.Nonnull String type) { + this.type = type; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NexthopBlackhole nexthopBlackhole = (NexthopBlackhole) o; + return Objects.equals(this.type, nexthopBlackhole.type); + } + + @Override + public int hashCode() { + return Objects.hash(type); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NexthopBlackhole {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("type")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("type")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to NexthopBlackhole + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!NexthopBlackhole.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in NexthopBlackhole is not found in the empty JSON string", + NexthopBlackhole.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!NexthopBlackhole.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `NexthopBlackhole` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : NexthopBlackhole.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if (!jsonObj.get("type").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `type` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("type").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!NexthopBlackhole.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'NexthopBlackhole' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(NexthopBlackhole.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, NexthopBlackhole value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public NexthopBlackhole read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of NexthopBlackhole given an JSON string + * + * @param jsonString JSON string + * @return An instance of NexthopBlackhole + * @throws IOException if the JSON string is invalid with respect to NexthopBlackhole + */ + public static NexthopBlackhole fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, NexthopBlackhole.class); + } + + /** + * Convert an instance of NexthopBlackhole to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopIPv4.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopIPv4.java new file mode 100644 index 0000000..2a539be --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopIPv4.java @@ -0,0 +1,239 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents an IPv4 address. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class NexthopIPv4 { + public static final String SERIALIZED_NAME_TYPE = "type"; + + @SerializedName(SERIALIZED_NAME_TYPE) + @javax.annotation.Nonnull + private String type; + + public static final String SERIALIZED_NAME_VALUE = "value"; + + @SerializedName(SERIALIZED_NAME_VALUE) + @javax.annotation.Nonnull + private String value; + + public NexthopIPv4() {} + + public NexthopIPv4 type(@javax.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * Get type + * + * @return type + */ + @javax.annotation.Nonnull + public String getType() { + return type; + } + + public void setType(@javax.annotation.Nonnull String type) { + this.type = type; + } + + public NexthopIPv4 value(@javax.annotation.Nonnull String value) { + this.value = value; + return this; + } + + /** + * An IPv4 address. + * + * @return value + */ + @javax.annotation.Nonnull + public String getValue() { + return value; + } + + public void setValue(@javax.annotation.Nonnull String value) { + this.value = value; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NexthopIPv4 nexthopIPv4 = (NexthopIPv4) o; + return Objects.equals(this.type, nexthopIPv4.type) + && Objects.equals(this.value, nexthopIPv4.value); + } + + @Override + public int hashCode() { + return Objects.hash(type, value); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NexthopIPv4 {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("type", "value")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("type", "value")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to NexthopIPv4 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!NexthopIPv4.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in NexthopIPv4 is not found in the empty JSON string", + NexthopIPv4.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!NexthopIPv4.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `NexthopIPv4` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : NexthopIPv4.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if (!jsonObj.get("type").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `type` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("type").toString())); + } + if (!jsonObj.get("value").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `value` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("value").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!NexthopIPv4.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'NexthopIPv4' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(NexthopIPv4.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, NexthopIPv4 value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public NexthopIPv4 read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of NexthopIPv4 given an JSON string + * + * @param jsonString JSON string + * @return An instance of NexthopIPv4 + * @throws IOException if the JSON string is invalid with respect to NexthopIPv4 + */ + public static NexthopIPv4 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, NexthopIPv4.class); + } + + /** + * Convert an instance of NexthopIPv4 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopIPv6.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopIPv6.java new file mode 100644 index 0000000..8e945dd --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopIPv6.java @@ -0,0 +1,239 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents an IPv6 address. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class NexthopIPv6 { + public static final String SERIALIZED_NAME_TYPE = "type"; + + @SerializedName(SERIALIZED_NAME_TYPE) + @javax.annotation.Nonnull + private String type; + + public static final String SERIALIZED_NAME_VALUE = "value"; + + @SerializedName(SERIALIZED_NAME_VALUE) + @javax.annotation.Nonnull + private String value; + + public NexthopIPv6() {} + + public NexthopIPv6 type(@javax.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * Get type + * + * @return type + */ + @javax.annotation.Nonnull + public String getType() { + return type; + } + + public void setType(@javax.annotation.Nonnull String type) { + this.type = type; + } + + public NexthopIPv6 value(@javax.annotation.Nonnull String value) { + this.value = value; + return this; + } + + /** + * An IPv6 address. + * + * @return value + */ + @javax.annotation.Nonnull + public String getValue() { + return value; + } + + public void setValue(@javax.annotation.Nonnull String value) { + this.value = value; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NexthopIPv6 nexthopIPv6 = (NexthopIPv6) o; + return Objects.equals(this.type, nexthopIPv6.type) + && Objects.equals(this.value, nexthopIPv6.value); + } + + @Override + public int hashCode() { + return Objects.hash(type, value); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NexthopIPv6 {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append(" value: ").append(toIndentedString(value)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("type", "value")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("type", "value")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to NexthopIPv6 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!NexthopIPv6.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in NexthopIPv6 is not found in the empty JSON string", + NexthopIPv6.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!NexthopIPv6.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `NexthopIPv6` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : NexthopIPv6.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if (!jsonObj.get("type").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `type` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("type").toString())); + } + if (!jsonObj.get("value").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `value` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("value").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!NexthopIPv6.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'NexthopIPv6' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(NexthopIPv6.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, NexthopIPv6 value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public NexthopIPv6 read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of NexthopIPv6 given an JSON string + * + * @param jsonString JSON string + * @return An instance of NexthopIPv6 + * @throws IOException if the JSON string is invalid with respect to NexthopIPv6 + */ + public static NexthopIPv6 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, NexthopIPv6.class); + } + + /** + * Convert an instance of NexthopIPv6 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopInternet.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopInternet.java new file mode 100644 index 0000000..0b1cb25 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopInternet.java @@ -0,0 +1,207 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents a route to the internet. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class NexthopInternet { + public static final String SERIALIZED_NAME_TYPE = "type"; + + @SerializedName(SERIALIZED_NAME_TYPE) + @javax.annotation.Nonnull + private String type; + + public NexthopInternet() {} + + public NexthopInternet type(@javax.annotation.Nonnull String type) { + this.type = type; + return this; + } + + /** + * Get type + * + * @return type + */ + @javax.annotation.Nonnull + public String getType() { + return type; + } + + public void setType(@javax.annotation.Nonnull String type) { + this.type = type; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + NexthopInternet nexthopInternet = (NexthopInternet) o; + return Objects.equals(this.type, nexthopInternet.type); + } + + @Override + public int hashCode() { + return Objects.hash(type); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class NexthopInternet {\n"); + sb.append(" type: ").append(toIndentedString(type)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("type")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("type")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to NexthopInternet + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!NexthopInternet.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in NexthopInternet is not found in the empty JSON string", + NexthopInternet.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!NexthopInternet.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `NexthopInternet` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : NexthopInternet.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if (!jsonObj.get("type").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `type` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("type").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!NexthopInternet.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'NexthopInternet' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(NexthopInternet.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, NexthopInternet value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public NexthopInternet read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of NexthopInternet given an JSON string + * + * @param jsonString JSON string + * @return An instance of NexthopInternet + * @throws IOException if the JSON string is invalid with respect to NexthopInternet + */ + public static NexthopInternet fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, NexthopInternet.class); + } + + /** + * Convert an instance of NexthopInternet to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PartialUpdateNetworkAreaPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PartialUpdateNetworkAreaPayload.java index 5e0ccb3..de0c67d 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PartialUpdateNetworkAreaPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PartialUpdateNetworkAreaPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -29,16 +29,11 @@ import java.util.Objects; import java.util.Set; -/** PartialUpdateNetworkAreaPayload */ +/** Object that represents the network area update request. */ @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class PartialUpdateNetworkAreaPayload { - public static final String SERIALIZED_NAME_ADDRESS_FAMILY = "addressFamily"; - - @SerializedName(SERIALIZED_NAME_ADDRESS_FAMILY) - @javax.annotation.Nullable private UpdateAreaAddressFamily addressFamily; - public static final String SERIALIZED_NAME_LABELS = "labels"; @SerializedName(SERIALIZED_NAME_LABELS) @@ -51,25 +46,6 @@ public class PartialUpdateNetworkAreaPayload { public PartialUpdateNetworkAreaPayload() {} - public PartialUpdateNetworkAreaPayload addressFamily( - @javax.annotation.Nullable UpdateAreaAddressFamily addressFamily) { - this.addressFamily = addressFamily; - return this; - } - - /** - * Get addressFamily - * - * @return addressFamily - */ - @javax.annotation.Nullable public UpdateAreaAddressFamily getAddressFamily() { - return addressFamily; - } - - public void setAddressFamily(@javax.annotation.Nullable UpdateAreaAddressFamily addressFamily) { - this.addressFamily = addressFamily; - } - public PartialUpdateNetworkAreaPayload labels(@javax.annotation.Nullable Object labels) { this.labels = labels; return this; @@ -77,9 +53,9 @@ public PartialUpdateNetworkAreaPayload labels(@javax.annotation.Nullable Object /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -97,7 +73,7 @@ public PartialUpdateNetworkAreaPayload name(@javax.annotation.Nullable String na } /** - * The name for a General Object. Matches Names and also UUIDs. + * Get name * * @return name */ @@ -119,21 +95,19 @@ public boolean equals(Object o) { } PartialUpdateNetworkAreaPayload partialUpdateNetworkAreaPayload = (PartialUpdateNetworkAreaPayload) o; - return Objects.equals(this.addressFamily, partialUpdateNetworkAreaPayload.addressFamily) - && Objects.equals(this.labels, partialUpdateNetworkAreaPayload.labels) + return Objects.equals(this.labels, partialUpdateNetworkAreaPayload.labels) && Objects.equals(this.name, partialUpdateNetworkAreaPayload.name); } @Override public int hashCode() { - return Objects.hash(addressFamily, labels, name); + return Objects.hash(labels, name); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class PartialUpdateNetworkAreaPayload {\n"); - sb.append(" addressFamily: ").append(toIndentedString(addressFamily)).append("\n"); sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append("}"); @@ -156,7 +130,7 @@ private String toIndentedString(Object o) { static { // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(Arrays.asList("addressFamily", "labels", "name")); + openapiFields = new HashSet(Arrays.asList("labels", "name")); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(0); @@ -191,10 +165,6 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } } JsonObject jsonObj = jsonElement.getAsJsonObject(); - // validate the optional field `addressFamily` - if (jsonObj.get("addressFamily") != null && !jsonObj.get("addressFamily").isJsonNull()) { - UpdateAreaAddressFamily.validateJsonElement(jsonObj.get("addressFamily")); - } if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { throw new IllegalArgumentException( diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PartialUpdateNetworkPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PartialUpdateNetworkPayload.java index 1d20674..6234ca1 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PartialUpdateNetworkPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PartialUpdateNetworkPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -28,22 +28,28 @@ import java.util.Map; import java.util.Objects; import java.util.Set; +import java.util.UUID; /** Object that represents the request body for a network update. */ @javax.annotation.Generated( value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class PartialUpdateNetworkPayload { - public static final String SERIALIZED_NAME_ADDRESS_FAMILY = "addressFamily"; - - @SerializedName(SERIALIZED_NAME_ADDRESS_FAMILY) - @javax.annotation.Nullable private UpdateNetworkAddressFamily addressFamily; - public static final String SERIALIZED_NAME_DHCP = "dhcp"; @SerializedName(SERIALIZED_NAME_DHCP) @javax.annotation.Nullable private Boolean dhcp; + public static final String SERIALIZED_NAME_IPV4 = "ipv4"; + + @SerializedName(SERIALIZED_NAME_IPV4) + @javax.annotation.Nullable private UpdateNetworkIPv4Body ipv4; + + public static final String SERIALIZED_NAME_IPV6 = "ipv6"; + + @SerializedName(SERIALIZED_NAME_IPV6) + @javax.annotation.Nullable private UpdateNetworkIPv6Body ipv6; + public static final String SERIALIZED_NAME_LABELS = "labels"; @SerializedName(SERIALIZED_NAME_LABELS) @@ -59,44 +65,65 @@ public class PartialUpdateNetworkPayload { @SerializedName(SERIALIZED_NAME_ROUTED) @javax.annotation.Nullable private Boolean routed; + public static final String SERIALIZED_NAME_ROUTING_TABLE_ID = "routingTableId"; + + @SerializedName(SERIALIZED_NAME_ROUTING_TABLE_ID) + @javax.annotation.Nullable private UUID routingTableId; + public PartialUpdateNetworkPayload() {} - public PartialUpdateNetworkPayload addressFamily( - @javax.annotation.Nullable UpdateNetworkAddressFamily addressFamily) { - this.addressFamily = addressFamily; + public PartialUpdateNetworkPayload dhcp(@javax.annotation.Nullable Boolean dhcp) { + this.dhcp = dhcp; return this; } /** - * Get addressFamily + * Enable or disable DHCP for a network. * - * @return addressFamily + * @return dhcp */ - @javax.annotation.Nullable public UpdateNetworkAddressFamily getAddressFamily() { - return addressFamily; + @javax.annotation.Nullable public Boolean getDhcp() { + return dhcp; } - public void setAddressFamily( - @javax.annotation.Nullable UpdateNetworkAddressFamily addressFamily) { - this.addressFamily = addressFamily; + public void setDhcp(@javax.annotation.Nullable Boolean dhcp) { + this.dhcp = dhcp; } - public PartialUpdateNetworkPayload dhcp(@javax.annotation.Nullable Boolean dhcp) { - this.dhcp = dhcp; + public PartialUpdateNetworkPayload ipv4(@javax.annotation.Nullable UpdateNetworkIPv4Body ipv4) { + this.ipv4 = ipv4; return this; } /** - * Enable or disable DHCP for a network. + * Get ipv4 * - * @return dhcp + * @return ipv4 */ - @javax.annotation.Nullable public Boolean getDhcp() { - return dhcp; + @javax.annotation.Nullable public UpdateNetworkIPv4Body getIpv4() { + return ipv4; } - public void setDhcp(@javax.annotation.Nullable Boolean dhcp) { - this.dhcp = dhcp; + public void setIpv4(@javax.annotation.Nullable UpdateNetworkIPv4Body ipv4) { + this.ipv4 = ipv4; + } + + public PartialUpdateNetworkPayload ipv6(@javax.annotation.Nullable UpdateNetworkIPv6Body ipv6) { + this.ipv6 = ipv6; + return this; + } + + /** + * Get ipv6 + * + * @return ipv6 + */ + @javax.annotation.Nullable public UpdateNetworkIPv6Body getIpv6() { + return ipv6; + } + + public void setIpv6(@javax.annotation.Nullable UpdateNetworkIPv6Body ipv6) { + this.ipv6 = ipv6; } public PartialUpdateNetworkPayload labels(@javax.annotation.Nullable Object labels) { @@ -106,9 +133,9 @@ public PartialUpdateNetworkPayload labels(@javax.annotation.Nullable Object labe /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -156,6 +183,25 @@ public void setRouted(@javax.annotation.Nullable Boolean routed) { this.routed = routed; } + public PartialUpdateNetworkPayload routingTableId( + @javax.annotation.Nullable UUID routingTableId) { + this.routingTableId = routingTableId; + return this; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return routingTableId + */ + @javax.annotation.Nullable public UUID getRoutingTableId() { + return routingTableId; + } + + public void setRoutingTableId(@javax.annotation.Nullable UUID routingTableId) { + this.routingTableId = routingTableId; + } + @Override public boolean equals(Object o) { if (this == o) { @@ -165,27 +211,31 @@ public boolean equals(Object o) { return false; } PartialUpdateNetworkPayload partialUpdateNetworkPayload = (PartialUpdateNetworkPayload) o; - return Objects.equals(this.addressFamily, partialUpdateNetworkPayload.addressFamily) - && Objects.equals(this.dhcp, partialUpdateNetworkPayload.dhcp) + return Objects.equals(this.dhcp, partialUpdateNetworkPayload.dhcp) + && Objects.equals(this.ipv4, partialUpdateNetworkPayload.ipv4) + && Objects.equals(this.ipv6, partialUpdateNetworkPayload.ipv6) && Objects.equals(this.labels, partialUpdateNetworkPayload.labels) && Objects.equals(this.name, partialUpdateNetworkPayload.name) - && Objects.equals(this.routed, partialUpdateNetworkPayload.routed); + && Objects.equals(this.routed, partialUpdateNetworkPayload.routed) + && Objects.equals(this.routingTableId, partialUpdateNetworkPayload.routingTableId); } @Override public int hashCode() { - return Objects.hash(addressFamily, dhcp, labels, name, routed); + return Objects.hash(dhcp, ipv4, ipv6, labels, name, routed, routingTableId); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class PartialUpdateNetworkPayload {\n"); - sb.append(" addressFamily: ").append(toIndentedString(addressFamily)).append("\n"); sb.append(" dhcp: ").append(toIndentedString(dhcp)).append("\n"); + sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); + sb.append(" ipv6: ").append(toIndentedString(ipv6)).append("\n"); sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" routed: ").append(toIndentedString(routed)).append("\n"); + sb.append(" routingTableId: ").append(toIndentedString(routingTableId)).append("\n"); sb.append("}"); return sb.toString(); } @@ -208,7 +258,14 @@ private String toIndentedString(Object o) { // a set of all properties/fields (JSON key names) openapiFields = new HashSet( - Arrays.asList("addressFamily", "dhcp", "labels", "name", "routed")); + Arrays.asList( + "dhcp", + "ipv4", + "ipv6", + "labels", + "name", + "routed", + "routingTableId")); // a set of required properties/fields (JSON key names) openapiRequiredFields = new HashSet(0); @@ -243,9 +300,13 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } } JsonObject jsonObj = jsonElement.getAsJsonObject(); - // validate the optional field `addressFamily` - if (jsonObj.get("addressFamily") != null && !jsonObj.get("addressFamily").isJsonNull()) { - UpdateNetworkAddressFamily.validateJsonElement(jsonObj.get("addressFamily")); + // validate the optional field `ipv4` + if (jsonObj.get("ipv4") != null && !jsonObj.get("ipv4").isJsonNull()) { + UpdateNetworkIPv4Body.validateJsonElement(jsonObj.get("ipv4")); + } + // validate the optional field `ipv6` + if (jsonObj.get("ipv6") != null && !jsonObj.get("ipv6").isJsonNull()) { + UpdateNetworkIPv6Body.validateJsonElement(jsonObj.get("ipv6")); } if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { @@ -254,6 +315,13 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti "Expected the field `name` to be a primitive type in the JSON string but got `%s`", jsonObj.get("name").toString())); } + if ((jsonObj.get("routingTableId") != null && !jsonObj.get("routingTableId").isJsonNull()) + && !jsonObj.get("routingTableId").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `routingTableId` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("routingTableId").toString())); + } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PortRange.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PortRange.java index 0d79b7f..11e479f 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PortRange.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PortRange.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Project.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Project.java index a563a97..9460980 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Project.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Project.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -47,27 +47,22 @@ public class Project { @SerializedName(SERIALIZED_NAME_CREATED_AT) @javax.annotation.Nullable private OffsetDateTime createdAt; + public static final String SERIALIZED_NAME_ID = "id"; + + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nonnull + private UUID id; + public static final String SERIALIZED_NAME_INTERNET_ACCESS = "internetAccess"; @SerializedName(SERIALIZED_NAME_INTERNET_ACCESS) @javax.annotation.Nullable private Boolean internetAccess; - public static final String SERIALIZED_NAME_OPENSTACK_PROJECT_ID = "openstackProjectId"; - - @SerializedName(SERIALIZED_NAME_OPENSTACK_PROJECT_ID) - @javax.annotation.Nullable private String openstackProjectId; - - public static final String SERIALIZED_NAME_PROJECT_ID = "projectId"; + public static final String SERIALIZED_NAME_STATUS = "status"; - @SerializedName(SERIALIZED_NAME_PROJECT_ID) + @SerializedName(SERIALIZED_NAME_STATUS) @javax.annotation.Nonnull - private UUID projectId; - - public static final String SERIALIZED_NAME_STATE = "state"; - - @SerializedName(SERIALIZED_NAME_STATE) - @javax.annotation.Nonnull - private String state; + private String status; public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; @@ -76,10 +71,9 @@ public class Project { public Project() {} - public Project(OffsetDateTime createdAt, String openstackProjectId, OffsetDateTime updatedAt) { + public Project(OffsetDateTime createdAt, OffsetDateTime updatedAt) { this(); this.createdAt = createdAt; - this.openstackProjectId = openstackProjectId; this.updatedAt = updatedAt; } @@ -111,54 +105,45 @@ public void setAreaId(@javax.annotation.Nonnull AreaId areaId) { return createdAt; } - public Project internetAccess(@javax.annotation.Nullable Boolean internetAccess) { - this.internetAccess = internetAccess; + public Project id(@javax.annotation.Nonnull UUID id) { + this.id = id; return this; } /** - * Get internetAccess + * Universally Unique Identifier (UUID). * - * @return internetAccess + * @return id */ - @javax.annotation.Nullable public Boolean getInternetAccess() { - return internetAccess; - } - - public void setInternetAccess(@javax.annotation.Nullable Boolean internetAccess) { - this.internetAccess = internetAccess; + @javax.annotation.Nonnull + public UUID getId() { + return id; } - /** - * The identifier (ID) of the OpenStack project in the main region eu01. - * - * @return openstackProjectId - */ - @javax.annotation.Nullable public String getOpenstackProjectId() { - return openstackProjectId; + public void setId(@javax.annotation.Nonnull UUID id) { + this.id = id; } - public Project projectId(@javax.annotation.Nonnull UUID projectId) { - this.projectId = projectId; + public Project internetAccess(@javax.annotation.Nullable Boolean internetAccess) { + this.internetAccess = internetAccess; return this; } /** - * Universally Unique Identifier (UUID). + * Get internetAccess * - * @return projectId + * @return internetAccess */ - @javax.annotation.Nonnull - public UUID getProjectId() { - return projectId; + @javax.annotation.Nullable public Boolean getInternetAccess() { + return internetAccess; } - public void setProjectId(@javax.annotation.Nonnull UUID projectId) { - this.projectId = projectId; + public void setInternetAccess(@javax.annotation.Nullable Boolean internetAccess) { + this.internetAccess = internetAccess; } - public Project state(@javax.annotation.Nonnull String state) { - this.state = state; + public Project status(@javax.annotation.Nonnull String status) { + this.status = status; return this; } @@ -167,15 +152,15 @@ public Project state(@javax.annotation.Nonnull String state) { * `DELETING`, `DELETED`, `FAILED`, `UPDATED`, * `UPDATING`. * - * @return state + * @return status */ @javax.annotation.Nonnull - public String getState() { - return state; + public String getStatus() { + return status; } - public void setState(@javax.annotation.Nonnull String state) { - this.state = state; + public void setStatus(@javax.annotation.Nonnull String status) { + this.status = status; } /** @@ -198,17 +183,15 @@ public boolean equals(Object o) { Project project = (Project) o; return Objects.equals(this.areaId, project.areaId) && Objects.equals(this.createdAt, project.createdAt) + && Objects.equals(this.id, project.id) && Objects.equals(this.internetAccess, project.internetAccess) - && Objects.equals(this.openstackProjectId, project.openstackProjectId) - && Objects.equals(this.projectId, project.projectId) - && Objects.equals(this.state, project.state) + && Objects.equals(this.status, project.status) && Objects.equals(this.updatedAt, project.updatedAt); } @Override public int hashCode() { - return Objects.hash( - areaId, createdAt, internetAccess, openstackProjectId, projectId, state, updatedAt); + return Objects.hash(areaId, createdAt, id, internetAccess, status, updatedAt); } @Override @@ -217,12 +200,9 @@ public String toString() { sb.append("class Project {\n"); sb.append(" areaId: ").append(toIndentedString(areaId)).append("\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" internetAccess: ").append(toIndentedString(internetAccess)).append("\n"); - sb.append(" openstackProjectId: ") - .append(toIndentedString(openstackProjectId)) - .append("\n"); - sb.append(" projectId: ").append(toIndentedString(projectId)).append("\n"); - sb.append(" state: ").append(toIndentedString(state)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append("}"); return sb.toString(); @@ -249,14 +229,13 @@ private String toIndentedString(Object o) { Arrays.asList( "areaId", "createdAt", + "id", "internetAccess", - "openstackProjectId", - "projectId", - "state", + "status", "updatedAt")); // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(Arrays.asList("areaId", "projectId", "state")); + openapiRequiredFields = new HashSet(Arrays.asList("areaId", "id", "status")); } /** @@ -299,25 +278,17 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti JsonObject jsonObj = jsonElement.getAsJsonObject(); // validate the required field `areaId` AreaId.validateJsonElement(jsonObj.get("areaId")); - if ((jsonObj.get("openstackProjectId") != null - && !jsonObj.get("openstackProjectId").isJsonNull()) - && !jsonObj.get("openstackProjectId").isJsonPrimitive()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `openstackProjectId` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("openstackProjectId").toString())); - } - if (!jsonObj.get("projectId").isJsonPrimitive()) { + if (!jsonObj.get("id").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( - "Expected the field `projectId` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("projectId").toString())); + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); } - if (!jsonObj.get("state").isJsonPrimitive()) { + if (!jsonObj.get("status").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( - "Expected the field `state` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("state").toString())); + "Expected the field `status` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("status").toString())); } } diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ProjectListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ProjectListResponse.java index 2d64ef3..46c5214 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ProjectListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ProjectListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Protocol.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Protocol.java index 8b5f0c0..d6b1f50 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Protocol.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Protocol.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicIp.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicIp.java index 02b6599..5782b49 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicIp.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicIp.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -74,7 +74,7 @@ public PublicIp(UUID id, String ip) { } /** - * Object that represents an IP address. + * String that represents an IPv4 address. * * @return ip */ @@ -89,9 +89,9 @@ public PublicIp labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicIpListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicIpListResponse.java index e891064..e48732d 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicIpListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicIpListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicNetwork.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicNetwork.java index 2e7de21..5f69c2f 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicNetwork.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicNetwork.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -40,6 +40,12 @@ public class PublicNetwork { @javax.annotation.Nonnull private String cidr; + public static final String SERIALIZED_NAME_REGION = "region"; + + @SerializedName(SERIALIZED_NAME_REGION) + @javax.annotation.Nonnull + private String region; + public PublicNetwork() {} public PublicNetwork cidr(@javax.annotation.Nonnull String cidr) { @@ -61,6 +67,25 @@ public void setCidr(@javax.annotation.Nonnull String cidr) { this.cidr = cidr; } + public PublicNetwork region(@javax.annotation.Nonnull String region) { + this.region = region; + return this; + } + + /** + * Name of the region. + * + * @return region + */ + @javax.annotation.Nonnull + public String getRegion() { + return region; + } + + public void setRegion(@javax.annotation.Nonnull String region) { + this.region = region; + } + @Override public boolean equals(Object o) { if (this == o) { @@ -70,12 +95,13 @@ public boolean equals(Object o) { return false; } PublicNetwork publicNetwork = (PublicNetwork) o; - return Objects.equals(this.cidr, publicNetwork.cidr); + return Objects.equals(this.cidr, publicNetwork.cidr) + && Objects.equals(this.region, publicNetwork.region); } @Override public int hashCode() { - return Objects.hash(cidr); + return Objects.hash(cidr, region); } @Override @@ -83,6 +109,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class PublicNetwork {\n"); sb.append(" cidr: ").append(toIndentedString(cidr)).append("\n"); + sb.append(" region: ").append(toIndentedString(region)).append("\n"); sb.append("}"); return sb.toString(); } @@ -103,10 +130,10 @@ private String toIndentedString(Object o) { static { // a set of all properties/fields (JSON key names) - openapiFields = new HashSet(Arrays.asList("cidr")); + openapiFields = new HashSet(Arrays.asList("cidr", "region")); // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(Arrays.asList("cidr")); + openapiRequiredFields = new HashSet(Arrays.asList("cidr", "region")); } /** @@ -153,6 +180,12 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti "Expected the field `cidr` to be a primitive type in the JSON string but got `%s`", jsonObj.get("cidr").toString())); } + if (!jsonObj.get("region").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `region` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("region").toString())); + } } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicNetworkListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicNetworkListResponse.java index a2614c0..6df9c70 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicNetworkListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/PublicNetworkListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Quota.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Quota.java index 839d74a..73fd79c 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Quota.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Quota.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/QuotaList.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/QuotaList.java index 2a3875f..65b322e 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/QuotaList.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/QuotaList.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/QuotaListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/QuotaListResponse.java index 6407b61..e18296e 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/QuotaListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/QuotaListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalArea.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalArea.java new file mode 100644 index 0000000..d11cad4 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalArea.java @@ -0,0 +1,222 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** The basic properties of a regional network area. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class RegionalArea { + public static final String SERIALIZED_NAME_IPV4 = "ipv4"; + + @SerializedName(SERIALIZED_NAME_IPV4) + @javax.annotation.Nullable private RegionalAreaIPv4 ipv4; + + public static final String SERIALIZED_NAME_STATUS = "status"; + + @SerializedName(SERIALIZED_NAME_STATUS) + @javax.annotation.Nullable private String status; + + public RegionalArea() {} + + public RegionalArea(String status) { + this(); + this.status = status; + } + + public RegionalArea ipv4(@javax.annotation.Nullable RegionalAreaIPv4 ipv4) { + this.ipv4 = ipv4; + return this; + } + + /** + * Get ipv4 + * + * @return ipv4 + */ + @javax.annotation.Nullable public RegionalAreaIPv4 getIpv4() { + return ipv4; + } + + public void setIpv4(@javax.annotation.Nullable RegionalAreaIPv4 ipv4) { + this.ipv4 = ipv4; + } + + /** + * The state of a resource object. Possible values: `CREATING`, `CREATED`, + * `DELETING`, `DELETED`, `FAILED`, `UPDATED`, + * `UPDATING`. + * + * @return status + */ + @javax.annotation.Nullable public String getStatus() { + return status; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RegionalArea regionalArea = (RegionalArea) o; + return Objects.equals(this.ipv4, regionalArea.ipv4) + && Objects.equals(this.status, regionalArea.status); + } + + @Override + public int hashCode() { + return Objects.hash(ipv4, status); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RegionalArea {\n"); + sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("ipv4", "status")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to RegionalArea + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!RegionalArea.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in RegionalArea is not found in the empty JSON string", + RegionalArea.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!RegionalArea.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `RegionalArea` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // validate the optional field `ipv4` + if (jsonObj.get("ipv4") != null && !jsonObj.get("ipv4").isJsonNull()) { + RegionalAreaIPv4.validateJsonElement(jsonObj.get("ipv4")); + } + if ((jsonObj.get("status") != null && !jsonObj.get("status").isJsonNull()) + && !jsonObj.get("status").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `status` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("status").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!RegionalArea.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'RegionalArea' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(RegionalArea.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, RegionalArea value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public RegionalArea read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of RegionalArea given an JSON string + * + * @param jsonString JSON string + * @return An instance of RegionalArea + * @throws IOException if the JSON string is invalid with respect to RegionalArea + */ + public static RegionalArea fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, RegionalArea.class); + } + + /** + * Convert an instance of RegionalArea to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalAreaIPv4.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalAreaIPv4.java new file mode 100644 index 0000000..2a2a30e --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalAreaIPv4.java @@ -0,0 +1,407 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonArray; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** The regional IPv4 config of a network area. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class RegionalAreaIPv4 { + public static final String SERIALIZED_NAME_DEFAULT_NAMESERVERS = "defaultNameservers"; + + @SerializedName(SERIALIZED_NAME_DEFAULT_NAMESERVERS) + @javax.annotation.Nullable private List defaultNameservers = new ArrayList<>(); + + public static final String SERIALIZED_NAME_DEFAULT_PREFIX_LEN = "defaultPrefixLen"; + + @SerializedName(SERIALIZED_NAME_DEFAULT_PREFIX_LEN) + @javax.annotation.Nonnull + private Long defaultPrefixLen = 25; + + public static final String SERIALIZED_NAME_MAX_PREFIX_LEN = "maxPrefixLen"; + + @SerializedName(SERIALIZED_NAME_MAX_PREFIX_LEN) + @javax.annotation.Nonnull + private Long maxPrefixLen = 29; + + public static final String SERIALIZED_NAME_MIN_PREFIX_LEN = "minPrefixLen"; + + @SerializedName(SERIALIZED_NAME_MIN_PREFIX_LEN) + @javax.annotation.Nonnull + private Long minPrefixLen = 24; + + public static final String SERIALIZED_NAME_NETWORK_RANGES = "networkRanges"; + + @SerializedName(SERIALIZED_NAME_NETWORK_RANGES) + @javax.annotation.Nonnull + private List networkRanges = new ArrayList<>(); + + public static final String SERIALIZED_NAME_TRANSFER_NETWORK = "transferNetwork"; + + @SerializedName(SERIALIZED_NAME_TRANSFER_NETWORK) + @javax.annotation.Nonnull + private String transferNetwork; + + public RegionalAreaIPv4() {} + + public RegionalAreaIPv4 defaultNameservers( + @javax.annotation.Nullable List defaultNameservers) { + this.defaultNameservers = defaultNameservers; + return this; + } + + public RegionalAreaIPv4 addDefaultNameserversItem(String defaultNameserversItem) { + if (this.defaultNameservers == null) { + this.defaultNameservers = new ArrayList<>(); + } + this.defaultNameservers.add(defaultNameserversItem); + return this; + } + + /** + * Get defaultNameservers + * + * @return defaultNameservers + */ + @javax.annotation.Nullable public List getDefaultNameservers() { + return defaultNameservers; + } + + public void setDefaultNameservers(@javax.annotation.Nullable List defaultNameservers) { + this.defaultNameservers = defaultNameservers; + } + + public RegionalAreaIPv4 defaultPrefixLen(@javax.annotation.Nonnull Long defaultPrefixLen) { + this.defaultPrefixLen = defaultPrefixLen; + return this; + } + + /** + * The default prefix length for networks in the network area. minimum: 24 maximum: 29 + * + * @return defaultPrefixLen + */ + @javax.annotation.Nonnull + public Long getDefaultPrefixLen() { + return defaultPrefixLen; + } + + public void setDefaultPrefixLen(@javax.annotation.Nonnull Long defaultPrefixLen) { + this.defaultPrefixLen = defaultPrefixLen; + } + + public RegionalAreaIPv4 maxPrefixLen(@javax.annotation.Nonnull Long maxPrefixLen) { + this.maxPrefixLen = maxPrefixLen; + return this; + } + + /** + * The maximal prefix length for networks in the network area. minimum: 24 maximum: 29 + * + * @return maxPrefixLen + */ + @javax.annotation.Nonnull + public Long getMaxPrefixLen() { + return maxPrefixLen; + } + + public void setMaxPrefixLen(@javax.annotation.Nonnull Long maxPrefixLen) { + this.maxPrefixLen = maxPrefixLen; + } + + public RegionalAreaIPv4 minPrefixLen(@javax.annotation.Nonnull Long minPrefixLen) { + this.minPrefixLen = minPrefixLen; + return this; + } + + /** + * The minimal prefix length for networks in the network area. minimum: 8 maximum: 29 + * + * @return minPrefixLen + */ + @javax.annotation.Nonnull + public Long getMinPrefixLen() { + return minPrefixLen; + } + + public void setMinPrefixLen(@javax.annotation.Nonnull Long minPrefixLen) { + this.minPrefixLen = minPrefixLen; + } + + public RegionalAreaIPv4 networkRanges( + @javax.annotation.Nonnull List networkRanges) { + this.networkRanges = networkRanges; + return this; + } + + public RegionalAreaIPv4 addNetworkRangesItem(NetworkRange networkRangesItem) { + if (this.networkRanges == null) { + this.networkRanges = new ArrayList<>(); + } + this.networkRanges.add(networkRangesItem); + return this; + } + + /** + * A list of network ranges. + * + * @return networkRanges + */ + @javax.annotation.Nonnull + public List getNetworkRanges() { + return networkRanges; + } + + public void setNetworkRanges(@javax.annotation.Nonnull List networkRanges) { + this.networkRanges = networkRanges; + } + + public RegionalAreaIPv4 transferNetwork(@javax.annotation.Nonnull String transferNetwork) { + this.transferNetwork = transferNetwork; + return this; + } + + /** + * IPv4 Classless Inter-Domain Routing (CIDR). + * + * @return transferNetwork + */ + @javax.annotation.Nonnull + public String getTransferNetwork() { + return transferNetwork; + } + + public void setTransferNetwork(@javax.annotation.Nonnull String transferNetwork) { + this.transferNetwork = transferNetwork; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RegionalAreaIPv4 regionalAreaIPv4 = (RegionalAreaIPv4) o; + return Objects.equals(this.defaultNameservers, regionalAreaIPv4.defaultNameservers) + && Objects.equals(this.defaultPrefixLen, regionalAreaIPv4.defaultPrefixLen) + && Objects.equals(this.maxPrefixLen, regionalAreaIPv4.maxPrefixLen) + && Objects.equals(this.minPrefixLen, regionalAreaIPv4.minPrefixLen) + && Objects.equals(this.networkRanges, regionalAreaIPv4.networkRanges) + && Objects.equals(this.transferNetwork, regionalAreaIPv4.transferNetwork); + } + + @Override + public int hashCode() { + return Objects.hash( + defaultNameservers, + defaultPrefixLen, + maxPrefixLen, + minPrefixLen, + networkRanges, + transferNetwork); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RegionalAreaIPv4 {\n"); + sb.append(" defaultNameservers: ") + .append(toIndentedString(defaultNameservers)) + .append("\n"); + sb.append(" defaultPrefixLen: ").append(toIndentedString(defaultPrefixLen)).append("\n"); + sb.append(" maxPrefixLen: ").append(toIndentedString(maxPrefixLen)).append("\n"); + sb.append(" minPrefixLen: ").append(toIndentedString(minPrefixLen)).append("\n"); + sb.append(" networkRanges: ").append(toIndentedString(networkRanges)).append("\n"); + sb.append(" transferNetwork: ").append(toIndentedString(transferNetwork)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = + new HashSet( + Arrays.asList( + "defaultNameservers", + "defaultPrefixLen", + "maxPrefixLen", + "minPrefixLen", + "networkRanges", + "transferNetwork")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = + new HashSet( + Arrays.asList( + "defaultPrefixLen", + "maxPrefixLen", + "minPrefixLen", + "networkRanges", + "transferNetwork")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to RegionalAreaIPv4 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!RegionalAreaIPv4.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in RegionalAreaIPv4 is not found in the empty JSON string", + RegionalAreaIPv4.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!RegionalAreaIPv4.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `RegionalAreaIPv4` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : RegionalAreaIPv4.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the optional json data is an array if present + if (jsonObj.get("defaultNameservers") != null + && !jsonObj.get("defaultNameservers").isJsonNull() + && !jsonObj.get("defaultNameservers").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `defaultNameservers` to be an array in the JSON string but got `%s`", + jsonObj.get("defaultNameservers").toString())); + } + // ensure the json data is an array + if (!jsonObj.get("networkRanges").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `networkRanges` to be an array in the JSON string but got `%s`", + jsonObj.get("networkRanges").toString())); + } + + JsonArray jsonArraynetworkRanges = jsonObj.getAsJsonArray("networkRanges"); + // validate the required field `networkRanges` (array) + for (int i = 0; i < jsonArraynetworkRanges.size(); i++) { + NetworkRange.validateJsonElement(jsonArraynetworkRanges.get(i)); + } + ; + if (!jsonObj.get("transferNetwork").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `transferNetwork` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("transferNetwork").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!RegionalAreaIPv4.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'RegionalAreaIPv4' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(RegionalAreaIPv4.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, RegionalAreaIPv4 value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public RegionalAreaIPv4 read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of RegionalAreaIPv4 given an JSON string + * + * @param jsonString JSON string + * @return An instance of RegionalAreaIPv4 + * @throws IOException if the JSON string is invalid with respect to RegionalAreaIPv4 + */ + public static RegionalAreaIPv4 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, RegionalAreaIPv4.class); + } + + /** + * Convert an instance of RegionalAreaIPv4 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalAreaListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalAreaListResponse.java new file mode 100644 index 0000000..cf6801e --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalAreaListResponse.java @@ -0,0 +1,212 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Regional area list response. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class RegionalAreaListResponse { + public static final String SERIALIZED_NAME_REGIONS = "regions"; + + @SerializedName(SERIALIZED_NAME_REGIONS) + @javax.annotation.Nonnull + private Map regions = new HashMap<>(); + + public RegionalAreaListResponse() {} + + public RegionalAreaListResponse regions( + @javax.annotation.Nonnull Map regions) { + this.regions = regions; + return this; + } + + public RegionalAreaListResponse putRegionsItem(String key, RegionalArea regionsItem) { + if (this.regions == null) { + this.regions = new HashMap<>(); + } + this.regions.put(key, regionsItem); + return this; + } + + /** + * Get regions + * + * @return regions + */ + @javax.annotation.Nonnull + public Map getRegions() { + return regions; + } + + public void setRegions(@javax.annotation.Nonnull Map regions) { + this.regions = regions; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RegionalAreaListResponse regionalAreaListResponse = (RegionalAreaListResponse) o; + return Objects.equals(this.regions, regionalAreaListResponse.regions); + } + + @Override + public int hashCode() { + return Objects.hash(regions); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RegionalAreaListResponse {\n"); + sb.append(" regions: ").append(toIndentedString(regions)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("regions")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("regions")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to RegionalAreaListResponse + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!RegionalAreaListResponse.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in RegionalAreaListResponse is not found in the empty JSON string", + RegionalAreaListResponse.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!RegionalAreaListResponse.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `RegionalAreaListResponse` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : RegionalAreaListResponse.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!RegionalAreaListResponse.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'RegionalAreaListResponse' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(RegionalAreaListResponse.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, RegionalAreaListResponse value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public RegionalAreaListResponse read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of RegionalAreaListResponse given an JSON string + * + * @param jsonString JSON string + * @return An instance of RegionalAreaListResponse + * @throws IOException if the JSON string is invalid with respect to RegionalAreaListResponse + */ + public static RegionalAreaListResponse fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, RegionalAreaListResponse.class); + } + + /** + * Convert an instance of RegionalAreaListResponse to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Request.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Request.java index c726c88..a773bd5 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Request.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Request.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RequestResource.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RequestResource.java index b8cc583..6f98237 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RequestResource.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RequestResource.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RescueServerPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RescueServerPayload.java index a6ad9bd..9914420 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RescueServerPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RescueServerPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ResizeServerPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ResizeServerPayload.java index fa734bc..c4e12a5 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ResizeServerPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ResizeServerPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ResizeVolumePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ResizeVolumePayload.java index a580373..5cb438f 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ResizeVolumePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ResizeVolumePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Route.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Route.java index b3a6aa1..27ca6e1 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Route.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Route.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -41,6 +41,17 @@ public class Route { @SerializedName(SERIALIZED_NAME_CREATED_AT) @javax.annotation.Nullable private OffsetDateTime createdAt; + public static final String SERIALIZED_NAME_DESTINATION = "destination"; + + @SerializedName(SERIALIZED_NAME_DESTINATION) + @javax.annotation.Nonnull + private RouteDestination destination; + + public static final String SERIALIZED_NAME_ID = "id"; + + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nullable private UUID id; + public static final String SERIALIZED_NAME_LABELS = "labels"; @SerializedName(SERIALIZED_NAME_LABELS) @@ -50,18 +61,7 @@ public class Route { @SerializedName(SERIALIZED_NAME_NEXTHOP) @javax.annotation.Nonnull - private String nexthop; - - public static final String SERIALIZED_NAME_PREFIX = "prefix"; - - @SerializedName(SERIALIZED_NAME_PREFIX) - @javax.annotation.Nonnull - private String prefix; - - public static final String SERIALIZED_NAME_ROUTE_ID = "routeId"; - - @SerializedName(SERIALIZED_NAME_ROUTE_ID) - @javax.annotation.Nullable private UUID routeId; + private RouteNexthop nexthop; public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; @@ -70,10 +70,10 @@ public class Route { public Route() {} - public Route(OffsetDateTime createdAt, UUID routeId, OffsetDateTime updatedAt) { + public Route(OffsetDateTime createdAt, UUID id, OffsetDateTime updatedAt) { this(); this.createdAt = createdAt; - this.routeId = routeId; + this.id = id; this.updatedAt = updatedAt; } @@ -86,6 +86,34 @@ public Route(OffsetDateTime createdAt, UUID routeId, OffsetDateTime updatedAt) { return createdAt; } + public Route destination(@javax.annotation.Nonnull RouteDestination destination) { + this.destination = destination; + return this; + } + + /** + * Get destination + * + * @return destination + */ + @javax.annotation.Nonnull + public RouteDestination getDestination() { + return destination; + } + + public void setDestination(@javax.annotation.Nonnull RouteDestination destination) { + this.destination = destination; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return id + */ + @javax.annotation.Nullable public UUID getId() { + return id; + } + public Route labels(@javax.annotation.Nullable Object labels) { this.labels = labels; return this; @@ -93,9 +121,9 @@ public Route labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -107,53 +135,25 @@ public void setLabels(@javax.annotation.Nullable Object labels) { this.labels = labels; } - public Route nexthop(@javax.annotation.Nonnull String nexthop) { + public Route nexthop(@javax.annotation.Nonnull RouteNexthop nexthop) { this.nexthop = nexthop; return this; } /** - * Object that represents an IP address. + * Get nexthop * * @return nexthop */ @javax.annotation.Nonnull - public String getNexthop() { + public RouteNexthop getNexthop() { return nexthop; } - public void setNexthop(@javax.annotation.Nonnull String nexthop) { + public void setNexthop(@javax.annotation.Nonnull RouteNexthop nexthop) { this.nexthop = nexthop; } - public Route prefix(@javax.annotation.Nonnull String prefix) { - this.prefix = prefix; - return this; - } - - /** - * Classless Inter-Domain Routing (CIDR). - * - * @return prefix - */ - @javax.annotation.Nonnull - public String getPrefix() { - return prefix; - } - - public void setPrefix(@javax.annotation.Nonnull String prefix) { - this.prefix = prefix; - } - - /** - * Universally Unique Identifier (UUID). - * - * @return routeId - */ - @javax.annotation.Nullable public UUID getRouteId() { - return routeId; - } - /** * Date-time when resource was last updated. * @@ -173,16 +173,16 @@ public boolean equals(Object o) { } Route route = (Route) o; return Objects.equals(this.createdAt, route.createdAt) + && Objects.equals(this.destination, route.destination) + && Objects.equals(this.id, route.id) && Objects.equals(this.labels, route.labels) && Objects.equals(this.nexthop, route.nexthop) - && Objects.equals(this.prefix, route.prefix) - && Objects.equals(this.routeId, route.routeId) && Objects.equals(this.updatedAt, route.updatedAt); } @Override public int hashCode() { - return Objects.hash(createdAt, labels, nexthop, prefix, routeId, updatedAt); + return Objects.hash(createdAt, destination, id, labels, nexthop, updatedAt); } @Override @@ -190,10 +190,10 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class Route {\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" destination: ").append(toIndentedString(destination)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); sb.append(" nexthop: ").append(toIndentedString(nexthop)).append("\n"); - sb.append(" prefix: ").append(toIndentedString(prefix)).append("\n"); - sb.append(" routeId: ").append(toIndentedString(routeId)).append("\n"); sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append("}"); return sb.toString(); @@ -219,14 +219,14 @@ private String toIndentedString(Object o) { new HashSet( Arrays.asList( "createdAt", + "destination", + "id", "labels", "nexthop", - "prefix", - "routeId", "updatedAt")); // a set of required properties/fields (JSON key names) - openapiRequiredFields = new HashSet(Arrays.asList("nexthop", "prefix")); + openapiRequiredFields = new HashSet(Arrays.asList("destination", "nexthop")); } /** @@ -267,25 +267,17 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } } JsonObject jsonObj = jsonElement.getAsJsonObject(); - if (!jsonObj.get("nexthop").isJsonPrimitive()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `nexthop` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("nexthop").toString())); - } - if (!jsonObj.get("prefix").isJsonPrimitive()) { - throw new IllegalArgumentException( - String.format( - "Expected the field `prefix` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("prefix").toString())); - } - if ((jsonObj.get("routeId") != null && !jsonObj.get("routeId").isJsonNull()) - && !jsonObj.get("routeId").isJsonPrimitive()) { + // validate the required field `destination` + RouteDestination.validateJsonElement(jsonObj.get("destination")); + if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) + && !jsonObj.get("id").isJsonPrimitive()) { throw new IllegalArgumentException( String.format( - "Expected the field `routeId` to be a primitive type in the JSON string but got `%s`", - jsonObj.get("routeId").toString())); + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); } + // validate the required field `nexthop` + RouteNexthop.validateJsonElement(jsonObj.get("nexthop")); } public static class CustomTypeAdapterFactory implements TypeAdapterFactory { diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteDestination.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteDestination.java new file mode 100644 index 0000000..c2f3d00 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteDestination.java @@ -0,0 +1,280 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; + +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class RouteDestination extends AbstractOpenApiSchema { + private static final Logger log = Logger.getLogger(RouteDestination.class.getName()); + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!RouteDestination.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'RouteDestination' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter adapterDestinationCIDRv4 = + gson.getDelegateAdapter(this, TypeToken.get(DestinationCIDRv4.class)); + final TypeAdapter adapterDestinationCIDRv6 = + gson.getDelegateAdapter(this, TypeToken.get(DestinationCIDRv6.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, RouteDestination value) + throws IOException { + if (value == null || value.getActualInstance() == null) { + elementAdapter.write(out, null); + return; + } + + // check if the actual instance is of the type `DestinationCIDRv4` + if (value.getActualInstance() instanceof DestinationCIDRv4) { + JsonElement element = + adapterDestinationCIDRv4.toJsonTree( + (DestinationCIDRv4) value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + // check if the actual instance is of the type `DestinationCIDRv6` + if (value.getActualInstance() instanceof DestinationCIDRv6) { + JsonElement element = + adapterDestinationCIDRv6.toJsonTree( + (DestinationCIDRv6) value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + throw new IOException( + "Failed to serialize as the type doesn't match oneOf schemas: DestinationCIDRv4, DestinationCIDRv6"); + } + + @Override + public RouteDestination read(JsonReader in) throws IOException { + Object deserialized = null; + JsonElement jsonElement = elementAdapter.read(in); + + int match = 0; + ArrayList errorMessages = new ArrayList<>(); + TypeAdapter actualAdapter = elementAdapter; + + // deserialize DestinationCIDRv4 + try { + // validate the JSON object to see if any exception is thrown + DestinationCIDRv4.validateJsonElement(jsonElement); + actualAdapter = adapterDestinationCIDRv4; + match++; + log.log( + Level.FINER, + "Input data matches schema 'DestinationCIDRv4'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for DestinationCIDRv4 failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'DestinationCIDRv4'", + e); + } + // deserialize DestinationCIDRv6 + try { + // validate the JSON object to see if any exception is thrown + DestinationCIDRv6.validateJsonElement(jsonElement); + actualAdapter = adapterDestinationCIDRv6; + match++; + log.log( + Level.FINER, + "Input data matches schema 'DestinationCIDRv6'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for DestinationCIDRv6 failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'DestinationCIDRv6'", + e); + } + + if (match == 1) { + RouteDestination ret = new RouteDestination(); + ret.setActualInstance(actualAdapter.fromJsonTree(jsonElement)); + return ret; + } + + throw new IOException( + String.format( + "Failed deserialization for RouteDestination: %d classes match result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + match, errorMessages, jsonElement.toString())); + } + }.nullSafe(); + } + } + + // store a list of schema names defined in oneOf + public static final Map> schemas = new HashMap>(); + + public RouteDestination() { + super("oneOf", Boolean.FALSE); + } + + public RouteDestination(Object o) { + super("oneOf", Boolean.FALSE); + setActualInstance(o); + } + + static { + schemas.put("DestinationCIDRv4", DestinationCIDRv4.class); + schemas.put("DestinationCIDRv6", DestinationCIDRv6.class); + } + + @Override + public Map> getSchemas() { + return RouteDestination.schemas; + } + + /** + * Set the instance that matches the oneOf child schema, check the instance parameter is valid + * against the oneOf child schemas: DestinationCIDRv4, DestinationCIDRv6 + * + *

It could be an instance of the 'oneOf' schemas. + */ + @Override + public void setActualInstance(Object instance) { + if (instance instanceof DestinationCIDRv4) { + super.setActualInstance(instance); + return; + } + + if (instance instanceof DestinationCIDRv6) { + super.setActualInstance(instance); + return; + } + + throw new RuntimeException( + "Invalid instance type. Must be DestinationCIDRv4, DestinationCIDRv6"); + } + + /** + * Get the actual instance, which can be the following: DestinationCIDRv4, DestinationCIDRv6 + * + * @return The actual instance (DestinationCIDRv4, DestinationCIDRv6) + */ + @SuppressWarnings("unchecked") + @Override + public Object getActualInstance() { + return super.getActualInstance(); + } + + /** + * Get the actual instance of `DestinationCIDRv4`. If the actual instance is not + * `DestinationCIDRv4`, the ClassCastException will be thrown. + * + * @return The actual instance of `DestinationCIDRv4` + * @throws ClassCastException if the instance is not `DestinationCIDRv4` + */ + public DestinationCIDRv4 getDestinationCIDRv4() throws ClassCastException { + return (DestinationCIDRv4) super.getActualInstance(); + } + + /** + * Get the actual instance of `DestinationCIDRv6`. If the actual instance is not + * `DestinationCIDRv6`, the ClassCastException will be thrown. + * + * @return The actual instance of `DestinationCIDRv6` + * @throws ClassCastException if the instance is not `DestinationCIDRv6` + */ + public DestinationCIDRv6 getDestinationCIDRv6() throws ClassCastException { + return (DestinationCIDRv6) super.getActualInstance(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to RouteDestination + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + // validate oneOf schemas one by one + int validCount = 0; + ArrayList errorMessages = new ArrayList<>(); + // validate the json string with DestinationCIDRv4 + try { + DestinationCIDRv4.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for DestinationCIDRv4 failed with `%s`.", + e.getMessage())); + // continue to the next one + } + // validate the json string with DestinationCIDRv6 + try { + DestinationCIDRv6.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for DestinationCIDRv6 failed with `%s`.", + e.getMessage())); + // continue to the next one + } + if (validCount != 1) { + throw new IOException( + String.format( + "The JSON string is invalid for RouteDestination with oneOf schemas: DestinationCIDRv4, DestinationCIDRv6. %d class(es) match the result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + validCount, errorMessages, jsonElement.toString())); + } + } + + /** + * Create an instance of RouteDestination given an JSON string + * + * @param jsonString JSON string + * @return An instance of RouteDestination + * @throws IOException if the JSON string is invalid with respect to RouteDestination + */ + public static RouteDestination fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, RouteDestination.class); + } + + /** + * Convert an instance of RouteDestination to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteListResponse.java index f0264ad..afc386f 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteNexthop.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteNexthop.java new file mode 100644 index 0000000..209cd4a --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteNexthop.java @@ -0,0 +1,388 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; + +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class RouteNexthop extends AbstractOpenApiSchema { + private static final Logger log = Logger.getLogger(RouteNexthop.class.getName()); + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!RouteNexthop.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'RouteNexthop' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter adapterNexthopIPv4 = + gson.getDelegateAdapter(this, TypeToken.get(NexthopIPv4.class)); + final TypeAdapter adapterNexthopIPv6 = + gson.getDelegateAdapter(this, TypeToken.get(NexthopIPv6.class)); + final TypeAdapter adapterNexthopInternet = + gson.getDelegateAdapter(this, TypeToken.get(NexthopInternet.class)); + final TypeAdapter adapterNexthopBlackhole = + gson.getDelegateAdapter(this, TypeToken.get(NexthopBlackhole.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, RouteNexthop value) throws IOException { + if (value == null || value.getActualInstance() == null) { + elementAdapter.write(out, null); + return; + } + + // check if the actual instance is of the type `NexthopIPv4` + if (value.getActualInstance() instanceof NexthopIPv4) { + JsonElement element = + adapterNexthopIPv4.toJsonTree( + (NexthopIPv4) value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + // check if the actual instance is of the type `NexthopIPv6` + if (value.getActualInstance() instanceof NexthopIPv6) { + JsonElement element = + adapterNexthopIPv6.toJsonTree( + (NexthopIPv6) value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + // check if the actual instance is of the type `NexthopInternet` + if (value.getActualInstance() instanceof NexthopInternet) { + JsonElement element = + adapterNexthopInternet.toJsonTree( + (NexthopInternet) value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + // check if the actual instance is of the type `NexthopBlackhole` + if (value.getActualInstance() instanceof NexthopBlackhole) { + JsonElement element = + adapterNexthopBlackhole.toJsonTree( + (NexthopBlackhole) value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + throw new IOException( + "Failed to serialize as the type doesn't match oneOf schemas: NexthopBlackhole, NexthopIPv4, NexthopIPv6, NexthopInternet"); + } + + @Override + public RouteNexthop read(JsonReader in) throws IOException { + Object deserialized = null; + JsonElement jsonElement = elementAdapter.read(in); + + int match = 0; + ArrayList errorMessages = new ArrayList<>(); + TypeAdapter actualAdapter = elementAdapter; + + // deserialize NexthopIPv4 + try { + // validate the JSON object to see if any exception is thrown + NexthopIPv4.validateJsonElement(jsonElement); + actualAdapter = adapterNexthopIPv4; + match++; + log.log(Level.FINER, "Input data matches schema 'NexthopIPv4'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for NexthopIPv4 failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'NexthopIPv4'", + e); + } + // deserialize NexthopIPv6 + try { + // validate the JSON object to see if any exception is thrown + NexthopIPv6.validateJsonElement(jsonElement); + actualAdapter = adapterNexthopIPv6; + match++; + log.log(Level.FINER, "Input data matches schema 'NexthopIPv6'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for NexthopIPv6 failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'NexthopIPv6'", + e); + } + // deserialize NexthopInternet + try { + // validate the JSON object to see if any exception is thrown + NexthopInternet.validateJsonElement(jsonElement); + actualAdapter = adapterNexthopInternet; + match++; + log.log(Level.FINER, "Input data matches schema 'NexthopInternet'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for NexthopInternet failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'NexthopInternet'", + e); + } + // deserialize NexthopBlackhole + try { + // validate the JSON object to see if any exception is thrown + NexthopBlackhole.validateJsonElement(jsonElement); + actualAdapter = adapterNexthopBlackhole; + match++; + log.log( + Level.FINER, + "Input data matches schema 'NexthopBlackhole'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for NexthopBlackhole failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'NexthopBlackhole'", + e); + } + + if (match == 1) { + RouteNexthop ret = new RouteNexthop(); + ret.setActualInstance(actualAdapter.fromJsonTree(jsonElement)); + return ret; + } + + throw new IOException( + String.format( + "Failed deserialization for RouteNexthop: %d classes match result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + match, errorMessages, jsonElement.toString())); + } + }.nullSafe(); + } + } + + // store a list of schema names defined in oneOf + public static final Map> schemas = new HashMap>(); + + public RouteNexthop() { + super("oneOf", Boolean.FALSE); + } + + public RouteNexthop(Object o) { + super("oneOf", Boolean.FALSE); + setActualInstance(o); + } + + static { + schemas.put("NexthopIPv4", NexthopIPv4.class); + schemas.put("NexthopIPv6", NexthopIPv6.class); + schemas.put("NexthopInternet", NexthopInternet.class); + schemas.put("NexthopBlackhole", NexthopBlackhole.class); + } + + @Override + public Map> getSchemas() { + return RouteNexthop.schemas; + } + + /** + * Set the instance that matches the oneOf child schema, check the instance parameter is valid + * against the oneOf child schemas: NexthopBlackhole, NexthopIPv4, NexthopIPv6, NexthopInternet + * + *

It could be an instance of the 'oneOf' schemas. + */ + @Override + public void setActualInstance(Object instance) { + if (instance instanceof NexthopIPv4) { + super.setActualInstance(instance); + return; + } + + if (instance instanceof NexthopIPv6) { + super.setActualInstance(instance); + return; + } + + if (instance instanceof NexthopInternet) { + super.setActualInstance(instance); + return; + } + + if (instance instanceof NexthopBlackhole) { + super.setActualInstance(instance); + return; + } + + throw new RuntimeException( + "Invalid instance type. Must be NexthopBlackhole, NexthopIPv4, NexthopIPv6, NexthopInternet"); + } + + /** + * Get the actual instance, which can be the following: NexthopBlackhole, NexthopIPv4, + * NexthopIPv6, NexthopInternet + * + * @return The actual instance (NexthopBlackhole, NexthopIPv4, NexthopIPv6, NexthopInternet) + */ + @SuppressWarnings("unchecked") + @Override + public Object getActualInstance() { + return super.getActualInstance(); + } + + /** + * Get the actual instance of `NexthopIPv4`. If the actual instance is not `NexthopIPv4`, the + * ClassCastException will be thrown. + * + * @return The actual instance of `NexthopIPv4` + * @throws ClassCastException if the instance is not `NexthopIPv4` + */ + public NexthopIPv4 getNexthopIPv4() throws ClassCastException { + return (NexthopIPv4) super.getActualInstance(); + } + + /** + * Get the actual instance of `NexthopIPv6`. If the actual instance is not `NexthopIPv6`, the + * ClassCastException will be thrown. + * + * @return The actual instance of `NexthopIPv6` + * @throws ClassCastException if the instance is not `NexthopIPv6` + */ + public NexthopIPv6 getNexthopIPv6() throws ClassCastException { + return (NexthopIPv6) super.getActualInstance(); + } + + /** + * Get the actual instance of `NexthopInternet`. If the actual instance is not + * `NexthopInternet`, the ClassCastException will be thrown. + * + * @return The actual instance of `NexthopInternet` + * @throws ClassCastException if the instance is not `NexthopInternet` + */ + public NexthopInternet getNexthopInternet() throws ClassCastException { + return (NexthopInternet) super.getActualInstance(); + } + + /** + * Get the actual instance of `NexthopBlackhole`. If the actual instance is not + * `NexthopBlackhole`, the ClassCastException will be thrown. + * + * @return The actual instance of `NexthopBlackhole` + * @throws ClassCastException if the instance is not `NexthopBlackhole` + */ + public NexthopBlackhole getNexthopBlackhole() throws ClassCastException { + return (NexthopBlackhole) super.getActualInstance(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to RouteNexthop + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + // validate oneOf schemas one by one + int validCount = 0; + ArrayList errorMessages = new ArrayList<>(); + // validate the json string with NexthopIPv4 + try { + NexthopIPv4.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for NexthopIPv4 failed with `%s`.", e.getMessage())); + // continue to the next one + } + // validate the json string with NexthopIPv6 + try { + NexthopIPv6.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for NexthopIPv6 failed with `%s`.", e.getMessage())); + // continue to the next one + } + // validate the json string with NexthopInternet + try { + NexthopInternet.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for NexthopInternet failed with `%s`.", + e.getMessage())); + // continue to the next one + } + // validate the json string with NexthopBlackhole + try { + NexthopBlackhole.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for NexthopBlackhole failed with `%s`.", + e.getMessage())); + // continue to the next one + } + if (validCount != 1) { + throw new IOException( + String.format( + "The JSON string is invalid for RouteNexthop with oneOf schemas: NexthopBlackhole, NexthopIPv4, NexthopIPv6, NexthopInternet. %d class(es) match the result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + validCount, errorMessages, jsonElement.toString())); + } + } + + /** + * Create an instance of RouteNexthop given an JSON string + * + * @param jsonString JSON string + * @return An instance of RouteNexthop + * @throws IOException if the JSON string is invalid with respect to RouteNexthop + */ + public static RouteNexthop fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, RouteNexthop.class); + } + + /** + * Convert an instance of RouteNexthop to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTable.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTable.java new file mode 100644 index 0000000..3235aca --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTable.java @@ -0,0 +1,385 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.time.OffsetDateTime; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import java.util.UUID; + +/** An object representing a routing table. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class RoutingTable { + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + + @SerializedName(SERIALIZED_NAME_CREATED_AT) + @javax.annotation.Nullable private OffsetDateTime createdAt; + + public static final String SERIALIZED_NAME_DEFAULT = "default"; + + @SerializedName(SERIALIZED_NAME_DEFAULT) + @javax.annotation.Nullable private Boolean _default = true; + + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + @javax.annotation.Nullable private String description; + + public static final String SERIALIZED_NAME_ID = "id"; + + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nullable private UUID id; + + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public static final String SERIALIZED_NAME_NAME = "name"; + + @SerializedName(SERIALIZED_NAME_NAME) + @javax.annotation.Nonnull + private String name; + + public static final String SERIALIZED_NAME_SYSTEM_ROUTES = "systemRoutes"; + + @SerializedName(SERIALIZED_NAME_SYSTEM_ROUTES) + @javax.annotation.Nullable private Boolean systemRoutes = true; + + public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; + + @SerializedName(SERIALIZED_NAME_UPDATED_AT) + @javax.annotation.Nullable private OffsetDateTime updatedAt; + + public RoutingTable() {} + + public RoutingTable( + OffsetDateTime createdAt, Boolean _default, UUID id, OffsetDateTime updatedAt) { + this(); + this.createdAt = createdAt; + this._default = _default; + this.id = id; + this.updatedAt = updatedAt; + } + + /** + * Date-time when resource was created. + * + * @return createdAt + */ + @javax.annotation.Nullable public OffsetDateTime getCreatedAt() { + return createdAt; + } + + /** + * This is the default routing table. It can't be deleted and is used if the user does not + * specify it otherwise. + * + * @return _default + */ + @javax.annotation.Nullable public Boolean getDefault() { + return _default; + } + + public RoutingTable description(@javax.annotation.Nullable String description) { + this.description = description; + return this; + } + + /** + * Description Object. Allows string up to 255 Characters. + * + * @return description + */ + @javax.annotation.Nullable public String getDescription() { + return description; + } + + public void setDescription(@javax.annotation.Nullable String description) { + this.description = description; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return id + */ + @javax.annotation.Nullable public UUID getId() { + return id; + } + + public RoutingTable labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + public RoutingTable name(@javax.annotation.Nonnull String name) { + this.name = name; + return this; + } + + /** + * The name for a General Object. Matches Names and also UUIDs. + * + * @return name + */ + @javax.annotation.Nonnull + public String getName() { + return name; + } + + public void setName(@javax.annotation.Nonnull String name) { + this.name = name; + } + + public RoutingTable systemRoutes(@javax.annotation.Nullable Boolean systemRoutes) { + this.systemRoutes = systemRoutes; + return this; + } + + /** + * Get systemRoutes + * + * @return systemRoutes + */ + @javax.annotation.Nullable public Boolean getSystemRoutes() { + return systemRoutes; + } + + public void setSystemRoutes(@javax.annotation.Nullable Boolean systemRoutes) { + this.systemRoutes = systemRoutes; + } + + /** + * Date-time when resource was last updated. + * + * @return updatedAt + */ + @javax.annotation.Nullable public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RoutingTable routingTable = (RoutingTable) o; + return Objects.equals(this.createdAt, routingTable.createdAt) + && Objects.equals(this._default, routingTable._default) + && Objects.equals(this.description, routingTable.description) + && Objects.equals(this.id, routingTable.id) + && Objects.equals(this.labels, routingTable.labels) + && Objects.equals(this.name, routingTable.name) + && Objects.equals(this.systemRoutes, routingTable.systemRoutes) + && Objects.equals(this.updatedAt, routingTable.updatedAt); + } + + @Override + public int hashCode() { + return Objects.hash( + createdAt, _default, description, id, labels, name, systemRoutes, updatedAt); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RoutingTable {\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" _default: ").append(toIndentedString(_default)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" systemRoutes: ").append(toIndentedString(systemRoutes)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = + new HashSet( + Arrays.asList( + "createdAt", + "default", + "description", + "id", + "labels", + "name", + "systemRoutes", + "updatedAt")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("name")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to RoutingTable + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!RoutingTable.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in RoutingTable is not found in the empty JSON string", + RoutingTable.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!RoutingTable.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `RoutingTable` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : RoutingTable.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) + && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `description` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("description").toString())); + } + if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) + && !jsonObj.get("id").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); + } + if (!jsonObj.get("name").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `name` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("name").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!RoutingTable.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'RoutingTable' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(RoutingTable.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, RoutingTable value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public RoutingTable read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of RoutingTable given an JSON string + * + * @param jsonString JSON string + * @return An instance of RoutingTable + * @throws IOException if the JSON string is invalid with respect to RoutingTable + */ + public static RoutingTable fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, RoutingTable.class); + } + + /** + * Convert an instance of RoutingTable to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTableListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTableListResponse.java new file mode 100644 index 0000000..da30f3c --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTableListResponse.java @@ -0,0 +1,227 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonArray; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Routing table response. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class RoutingTableListResponse { + public static final String SERIALIZED_NAME_ITEMS = "items"; + + @SerializedName(SERIALIZED_NAME_ITEMS) + @javax.annotation.Nonnull + private List items = new ArrayList<>(); + + public RoutingTableListResponse() {} + + public RoutingTableListResponse items(@javax.annotation.Nonnull List items) { + this.items = items; + return this; + } + + public RoutingTableListResponse addItemsItem(RoutingTable itemsItem) { + if (this.items == null) { + this.items = new ArrayList<>(); + } + this.items.add(itemsItem); + return this; + } + + /** + * A list of routing tables. + * + * @return items + */ + @javax.annotation.Nonnull + public List getItems() { + return items; + } + + public void setItems(@javax.annotation.Nonnull List items) { + this.items = items; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + RoutingTableListResponse routingTableListResponse = (RoutingTableListResponse) o; + return Objects.equals(this.items, routingTableListResponse.items); + } + + @Override + public int hashCode() { + return Objects.hash(items); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class RoutingTableListResponse {\n"); + sb.append(" items: ").append(toIndentedString(items)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("items")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("items")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to RoutingTableListResponse + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!RoutingTableListResponse.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in RoutingTableListResponse is not found in the empty JSON string", + RoutingTableListResponse.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!RoutingTableListResponse.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `RoutingTableListResponse` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : RoutingTableListResponse.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the json data is an array + if (!jsonObj.get("items").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `items` to be an array in the JSON string but got `%s`", + jsonObj.get("items").toString())); + } + + JsonArray jsonArrayitems = jsonObj.getAsJsonArray("items"); + // validate the required field `items` (array) + for (int i = 0; i < jsonArrayitems.size(); i++) { + RoutingTable.validateJsonElement(jsonArrayitems.get(i)); + } + ; + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!RoutingTableListResponse.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'RoutingTableListResponse' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(RoutingTableListResponse.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, RoutingTableListResponse value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public RoutingTableListResponse read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of RoutingTableListResponse given an JSON string + * + * @param jsonString JSON string + * @return An instance of RoutingTableListResponse + * @throws IOException if the JSON string is invalid with respect to RoutingTableListResponse + */ + public static RoutingTableListResponse fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, RoutingTableListResponse.class); + } + + /** + * Convert an instance of RoutingTableListResponse to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroup.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroup.java index 2afb081..05ace2c 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroup.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroup.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -136,9 +136,9 @@ public SecurityGroup labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupListResponse.java index 1092c53..90ab5ea 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRule.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRule.java index 63900cc..e9a2840 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRule.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRule.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -23,6 +23,7 @@ import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import java.io.IOException; +import java.time.OffsetDateTime; import java.util.Arrays; import java.util.HashSet; import java.util.Map; @@ -35,6 +36,11 @@ value = "org.openapitools.codegen.languages.JavaClientCodegen", comments = "Generator version: 7.15.0") public class SecurityGroupRule { + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + + @SerializedName(SERIALIZED_NAME_CREATED_AT) + @javax.annotation.Nullable private OffsetDateTime createdAt; + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; @SerializedName(SERIALIZED_NAME_DESCRIPTION) @@ -81,6 +87,11 @@ public class SecurityGroupRule { @SerializedName(SERIALIZED_NAME_SECURITY_GROUP_ID) @javax.annotation.Nullable private UUID securityGroupId; + public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; + + @SerializedName(SERIALIZED_NAME_UPDATED_AT) + @javax.annotation.Nullable private OffsetDateTime updatedAt; + public static final String SERIALIZED_NAME_PROTOCOL = "protocol"; @SerializedName(SERIALIZED_NAME_PROTOCOL) @@ -88,10 +99,22 @@ public class SecurityGroupRule { public SecurityGroupRule() {} - public SecurityGroupRule(UUID id, UUID securityGroupId) { + public SecurityGroupRule( + OffsetDateTime createdAt, UUID id, UUID securityGroupId, OffsetDateTime updatedAt) { this(); + this.createdAt = createdAt; this.id = id; this.securityGroupId = securityGroupId; + this.updatedAt = updatedAt; + } + + /** + * Date-time when resource was created. + * + * @return createdAt + */ + @javax.annotation.Nullable public OffsetDateTime getCreatedAt() { + return createdAt; } public SecurityGroupRule description(@javax.annotation.Nullable String description) { @@ -243,6 +266,15 @@ public void setRemoteSecurityGroupId(@javax.annotation.Nullable UUID remoteSecur return securityGroupId; } + /** + * Date-time when resource was last updated. + * + * @return updatedAt + */ + @javax.annotation.Nullable public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + public SecurityGroupRule protocol(@javax.annotation.Nullable Protocol protocol) { this.protocol = protocol; return this; @@ -270,7 +302,8 @@ public boolean equals(Object o) { return false; } SecurityGroupRule securityGroupRule = (SecurityGroupRule) o; - return Objects.equals(this.description, securityGroupRule.description) + return Objects.equals(this.createdAt, securityGroupRule.createdAt) + && Objects.equals(this.description, securityGroupRule.description) && Objects.equals(this.direction, securityGroupRule.direction) && Objects.equals(this.ethertype, securityGroupRule.ethertype) && Objects.equals(this.icmpParameters, securityGroupRule.icmpParameters) @@ -280,12 +313,14 @@ public boolean equals(Object o) { && Objects.equals( this.remoteSecurityGroupId, securityGroupRule.remoteSecurityGroupId) && Objects.equals(this.securityGroupId, securityGroupRule.securityGroupId) + && Objects.equals(this.updatedAt, securityGroupRule.updatedAt) && Objects.equals(this.protocol, securityGroupRule.protocol); } @Override public int hashCode() { return Objects.hash( + createdAt, description, direction, ethertype, @@ -295,6 +330,7 @@ public int hashCode() { portRange, remoteSecurityGroupId, securityGroupId, + updatedAt, protocol); } @@ -302,6 +338,7 @@ public int hashCode() { public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class SecurityGroupRule {\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" direction: ").append(toIndentedString(direction)).append("\n"); sb.append(" ethertype: ").append(toIndentedString(ethertype)).append("\n"); @@ -313,6 +350,7 @@ public String toString() { .append(toIndentedString(remoteSecurityGroupId)) .append("\n"); sb.append(" securityGroupId: ").append(toIndentedString(securityGroupId)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); sb.append(" protocol: ").append(toIndentedString(protocol)).append("\n"); sb.append("}"); return sb.toString(); @@ -337,6 +375,7 @@ private String toIndentedString(Object o) { openapiFields = new HashSet( Arrays.asList( + "createdAt", "description", "direction", "ethertype", @@ -346,6 +385,7 @@ private String toIndentedString(Object o) { "portRange", "remoteSecurityGroupId", "securityGroupId", + "updatedAt", "protocol")); // a set of required properties/fields (JSON key names) diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleListResponse.java index 301149f..50bedd7 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleProtocol.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleProtocol.java index 78a3d5b..0063236 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleProtocol.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleProtocol.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Server.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Server.java index 851df3e..26ae2f5 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Server.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Server.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -44,6 +44,11 @@ public class Server { @SerializedName(SERIALIZED_NAME_AFFINITY_GROUP) @javax.annotation.Nullable private UUID affinityGroup; + public static final String SERIALIZED_NAME_AGENT = "agent"; + + @SerializedName(SERIALIZED_NAME_AGENT) + @javax.annotation.Nullable private ServerAgent agent; + public static final String SERIALIZED_NAME_AVAILABILITY_ZONE = "availabilityZone"; @SerializedName(SERIALIZED_NAME_AVAILABILITY_ZONE) @@ -114,7 +119,7 @@ public class Server { public static final String SERIALIZED_NAME_NETWORKING = "networking"; @SerializedName(SERIALIZED_NAME_NETWORKING) - @javax.annotation.Nullable private CreateServerPayloadNetworking networking; + @javax.annotation.Nullable private ServerNetworking networking; public static final String SERIALIZED_NAME_NICS = "nics"; @@ -198,6 +203,24 @@ public void setAffinityGroup(@javax.annotation.Nullable UUID affinityGroup) { this.affinityGroup = affinityGroup; } + public Server agent(@javax.annotation.Nullable ServerAgent agent) { + this.agent = agent; + return this; + } + + /** + * Get agent + * + * @return agent + */ + @javax.annotation.Nullable public ServerAgent getAgent() { + return agent; + } + + public void setAgent(@javax.annotation.Nullable ServerAgent agent) { + this.agent = agent; + } + public Server availabilityZone(@javax.annotation.Nullable String availabilityZone) { this.availabilityZone = availabilityZone; return this; @@ -307,9 +330,9 @@ public Server labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -397,7 +420,7 @@ public void setName(@javax.annotation.Nonnull String name) { this.name = name; } - public Server networking(@javax.annotation.Nullable CreateServerPayloadNetworking networking) { + public Server networking(@javax.annotation.Nullable ServerNetworking networking) { this.networking = networking; return this; } @@ -407,11 +430,11 @@ public Server networking(@javax.annotation.Nullable CreateServerPayloadNetworkin * * @return networking */ - @javax.annotation.Nullable public CreateServerPayloadNetworking getNetworking() { + @javax.annotation.Nullable public ServerNetworking getNetworking() { return networking; } - public void setNetworking(@javax.annotation.Nullable CreateServerPayloadNetworking networking) { + public void setNetworking(@javax.annotation.Nullable ServerNetworking networking) { this.networking = networking; } @@ -567,6 +590,7 @@ public boolean equals(Object o) { } Server server = (Server) o; return Objects.equals(this.affinityGroup, server.affinityGroup) + && Objects.equals(this.agent, server.agent) && Objects.equals(this.availabilityZone, server.availabilityZone) && Objects.equals(this.bootVolume, server.bootVolume) && Objects.equals(this.createdAt, server.createdAt) @@ -595,6 +619,7 @@ public boolean equals(Object o) { public int hashCode() { return Objects.hash( affinityGroup, + agent, availabilityZone, bootVolume, createdAt, @@ -624,6 +649,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class Server {\n"); sb.append(" affinityGroup: ").append(toIndentedString(affinityGroup)).append("\n"); + sb.append(" agent: ").append(toIndentedString(agent)).append("\n"); sb.append(" availabilityZone: ").append(toIndentedString(availabilityZone)).append("\n"); sb.append(" bootVolume: ").append(toIndentedString(bootVolume)).append("\n"); sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); @@ -674,6 +700,7 @@ private String toIndentedString(Object o) { new HashSet( Arrays.asList( "affinityGroup", + "agent", "availabilityZone", "bootVolume", "createdAt", @@ -746,6 +773,10 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti "Expected the field `affinityGroup` to be a primitive type in the JSON string but got `%s`", jsonObj.get("affinityGroup").toString())); } + // validate the optional field `agent` + if (jsonObj.get("agent") != null && !jsonObj.get("agent").isJsonNull()) { + ServerAgent.validateJsonElement(jsonObj.get("agent")); + } if ((jsonObj.get("availabilityZone") != null && !jsonObj.get("availabilityZone").isJsonNull()) && !jsonObj.get("availabilityZone").isJsonPrimitive()) { @@ -805,7 +836,7 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti } // validate the optional field `networking` if (jsonObj.get("networking") != null && !jsonObj.get("networking").isJsonNull()) { - CreateServerPayloadNetworking.validateJsonElement(jsonObj.get("networking")); + ServerNetworking.validateJsonElement(jsonObj.get("networking")); } if (jsonObj.get("nics") != null && !jsonObj.get("nics").isJsonNull()) { JsonArray jsonArraynics = jsonObj.getAsJsonArray("nics"); diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerAgent.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerAgent.java new file mode 100644 index 0000000..96df949 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerAgent.java @@ -0,0 +1,191 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** STACKIT server agent options for a server. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class ServerAgent { + public static final String SERIALIZED_NAME_PROVISIONED = "provisioned"; + + @SerializedName(SERIALIZED_NAME_PROVISIONED) + @javax.annotation.Nullable private Boolean provisioned; + + public ServerAgent() {} + + public ServerAgent provisioned(@javax.annotation.Nullable Boolean provisioned) { + this.provisioned = provisioned; + return this; + } + + /** + * Configure the STACKIT server agent provisioning during the first boot of the server. Only + * works when booting from an images that supports the STACKIT server agent. When + * `false` the agent IS NOT installed. When `true` the agent IS installed. + * When its not set the result depend on the used image and its default provisioning setting. + * + * @return provisioned + */ + @javax.annotation.Nullable public Boolean getProvisioned() { + return provisioned; + } + + public void setProvisioned(@javax.annotation.Nullable Boolean provisioned) { + this.provisioned = provisioned; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + ServerAgent serverAgent = (ServerAgent) o; + return Objects.equals(this.provisioned, serverAgent.provisioned); + } + + @Override + public int hashCode() { + return Objects.hash(provisioned); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class ServerAgent {\n"); + sb.append(" provisioned: ").append(toIndentedString(provisioned)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("provisioned")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to ServerAgent + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!ServerAgent.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in ServerAgent is not found in the empty JSON string", + ServerAgent.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!ServerAgent.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `ServerAgent` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ServerAgent.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ServerAgent' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(ServerAgent.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, ServerAgent value) throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public ServerAgent read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of ServerAgent given an JSON string + * + * @param jsonString JSON string + * @return An instance of ServerAgent + * @throws IOException if the JSON string is invalid with respect to ServerAgent + */ + public static ServerAgent fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ServerAgent.class); + } + + /** + * Convert an instance of ServerAgent to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerConsoleUrl.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerConsoleUrl.java index fcbc473..2d8a8ca 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerConsoleUrl.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerConsoleUrl.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerListResponse.java index 3c59aaa..e384b09 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerMaintenance.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerMaintenance.java index c1136e6..c797048 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerMaintenance.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerMaintenance.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerNetwork.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerNetwork.java index 0a869ee..e3ae067 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerNetwork.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerNetwork.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerNetworking.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerNetworking.java new file mode 100644 index 0000000..11bf8a8 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerNetworking.java @@ -0,0 +1,287 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.Map; +import java.util.logging.Level; +import java.util.logging.Logger; + +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class ServerNetworking extends AbstractOpenApiSchema { + private static final Logger log = Logger.getLogger(ServerNetworking.class.getName()); + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!ServerNetworking.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'ServerNetworking' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter adapterCreateServerNetworking = + gson.getDelegateAdapter(this, TypeToken.get(CreateServerNetworking.class)); + final TypeAdapter + adapterCreateServerNetworkingWithNics = + gson.getDelegateAdapter( + this, TypeToken.get(CreateServerNetworkingWithNics.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, ServerNetworking value) + throws IOException { + if (value == null || value.getActualInstance() == null) { + elementAdapter.write(out, null); + return; + } + + // check if the actual instance is of the type `CreateServerNetworking` + if (value.getActualInstance() instanceof CreateServerNetworking) { + JsonElement element = + adapterCreateServerNetworking.toJsonTree( + (CreateServerNetworking) value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + // check if the actual instance is of the type + // `CreateServerNetworkingWithNics` + if (value.getActualInstance() + instanceof CreateServerNetworkingWithNics) { + JsonElement element = + adapterCreateServerNetworkingWithNics.toJsonTree( + (CreateServerNetworkingWithNics) + value.getActualInstance()); + elementAdapter.write(out, element); + return; + } + throw new IOException( + "Failed to serialize as the type doesn't match oneOf schemas: CreateServerNetworking, CreateServerNetworkingWithNics"); + } + + @Override + public ServerNetworking read(JsonReader in) throws IOException { + Object deserialized = null; + JsonElement jsonElement = elementAdapter.read(in); + + int match = 0; + ArrayList errorMessages = new ArrayList<>(); + TypeAdapter actualAdapter = elementAdapter; + + // deserialize CreateServerNetworking + try { + // validate the JSON object to see if any exception is thrown + CreateServerNetworking.validateJsonElement(jsonElement); + actualAdapter = adapterCreateServerNetworking; + match++; + log.log( + Level.FINER, + "Input data matches schema 'CreateServerNetworking'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for CreateServerNetworking failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'CreateServerNetworking'", + e); + } + // deserialize CreateServerNetworkingWithNics + try { + // validate the JSON object to see if any exception is thrown + CreateServerNetworkingWithNics.validateJsonElement(jsonElement); + actualAdapter = adapterCreateServerNetworkingWithNics; + match++; + log.log( + Level.FINER, + "Input data matches schema 'CreateServerNetworkingWithNics'"); + } catch (Exception e) { + // deserialization failed, continue + errorMessages.add( + String.format( + "Deserialization for CreateServerNetworkingWithNics failed with `%s`.", + e.getMessage())); + log.log( + Level.FINER, + "Input data does not match schema 'CreateServerNetworkingWithNics'", + e); + } + + if (match == 1) { + ServerNetworking ret = new ServerNetworking(); + ret.setActualInstance(actualAdapter.fromJsonTree(jsonElement)); + return ret; + } + + throw new IOException( + String.format( + "Failed deserialization for ServerNetworking: %d classes match result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + match, errorMessages, jsonElement.toString())); + } + }.nullSafe(); + } + } + + // store a list of schema names defined in oneOf + public static final Map> schemas = new HashMap>(); + + public ServerNetworking() { + super("oneOf", Boolean.FALSE); + } + + public ServerNetworking(Object o) { + super("oneOf", Boolean.FALSE); + setActualInstance(o); + } + + static { + schemas.put("CreateServerNetworking", CreateServerNetworking.class); + schemas.put("CreateServerNetworkingWithNics", CreateServerNetworkingWithNics.class); + } + + @Override + public Map> getSchemas() { + return ServerNetworking.schemas; + } + + /** + * Set the instance that matches the oneOf child schema, check the instance parameter is valid + * against the oneOf child schemas: CreateServerNetworking, CreateServerNetworkingWithNics + * + *

It could be an instance of the 'oneOf' schemas. + */ + @Override + public void setActualInstance(Object instance) { + if (instance instanceof CreateServerNetworking) { + super.setActualInstance(instance); + return; + } + + if (instance instanceof CreateServerNetworkingWithNics) { + super.setActualInstance(instance); + return; + } + + throw new RuntimeException( + "Invalid instance type. Must be CreateServerNetworking, CreateServerNetworkingWithNics"); + } + + /** + * Get the actual instance, which can be the following: CreateServerNetworking, + * CreateServerNetworkingWithNics + * + * @return The actual instance (CreateServerNetworking, CreateServerNetworkingWithNics) + */ + @SuppressWarnings("unchecked") + @Override + public Object getActualInstance() { + return super.getActualInstance(); + } + + /** + * Get the actual instance of `CreateServerNetworking`. If the actual instance is not + * `CreateServerNetworking`, the ClassCastException will be thrown. + * + * @return The actual instance of `CreateServerNetworking` + * @throws ClassCastException if the instance is not `CreateServerNetworking` + */ + public CreateServerNetworking getCreateServerNetworking() throws ClassCastException { + return (CreateServerNetworking) super.getActualInstance(); + } + + /** + * Get the actual instance of `CreateServerNetworkingWithNics`. If the actual instance is not + * `CreateServerNetworkingWithNics`, the ClassCastException will be thrown. + * + * @return The actual instance of `CreateServerNetworkingWithNics` + * @throws ClassCastException if the instance is not `CreateServerNetworkingWithNics` + */ + public CreateServerNetworkingWithNics getCreateServerNetworkingWithNics() + throws ClassCastException { + return (CreateServerNetworkingWithNics) super.getActualInstance(); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to ServerNetworking + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + // validate oneOf schemas one by one + int validCount = 0; + ArrayList errorMessages = new ArrayList<>(); + // validate the json string with CreateServerNetworking + try { + CreateServerNetworking.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for CreateServerNetworking failed with `%s`.", + e.getMessage())); + // continue to the next one + } + // validate the json string with CreateServerNetworkingWithNics + try { + CreateServerNetworkingWithNics.validateJsonElement(jsonElement); + validCount++; + } catch (Exception e) { + errorMessages.add( + String.format( + "Deserialization for CreateServerNetworkingWithNics failed with `%s`.", + e.getMessage())); + // continue to the next one + } + if (validCount != 1) { + throw new IOException( + String.format( + "The JSON string is invalid for ServerNetworking with oneOf schemas: CreateServerNetworking, CreateServerNetworkingWithNics. %d class(es) match the result, expected 1. Detailed failure message for oneOf schemas: %s. JSON: %s", + validCount, errorMessages, jsonElement.toString())); + } + } + + /** + * Create an instance of ServerNetworking given an JSON string + * + * @param jsonString JSON string + * @return An instance of ServerNetworking + * @throws IOException if the JSON string is invalid with respect to ServerNetworking + */ + public static ServerNetworking fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, ServerNetworking.class); + } + + /** + * Convert an instance of ServerNetworking to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServiceAccountMailListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServiceAccountMailListResponse.java index c5387b7..7832d05 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServiceAccountMailListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServiceAccountMailListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SetImageSharePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SetImageSharePayload.java index 3664a33..4f29043 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SetImageSharePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SetImageSharePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Snapshot.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Snapshot.java index 76df689..1cdf1e3 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Snapshot.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Snapshot.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -114,9 +114,9 @@ public Snapshot labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SnapshotListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SnapshotListResponse.java index de4ca5e..841175d 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SnapshotListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SnapshotListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/StaticAreaID.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/StaticAreaID.java index 484b8fc..94871e7 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/StaticAreaID.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/StaticAreaID.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateAttachedVolumePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateAttachedVolumePayload.java index a78612f..bf41da3 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateAttachedVolumePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateAttachedVolumePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImagePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImagePayload.java index 58c6d83..4252c8d 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImagePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImagePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -138,9 +138,9 @@ public UpdateImagePayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImageSharePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImageSharePayload.java index 54f1c34..a361598 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImageSharePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImageSharePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateKeyPairPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateKeyPairPayload.java index fbab69c..53679d9 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateKeyPairPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateKeyPairPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -48,9 +48,9 @@ public UpdateKeyPairPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateManagementNetworkRoutePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateManagementNetworkRoutePayload.java new file mode 100644 index 0000000..1a14494 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateManagementNetworkRoutePayload.java @@ -0,0 +1,200 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents the request body for a management route update. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class UpdateManagementNetworkRoutePayload { + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public UpdateManagementNetworkRoutePayload() {} + + public UpdateManagementNetworkRoutePayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateManagementNetworkRoutePayload updateManagementNetworkRoutePayload = + (UpdateManagementNetworkRoutePayload) o; + return Objects.equals(this.labels, updateManagementNetworkRoutePayload.labels); + } + + @Override + public int hashCode() { + return Objects.hash(labels); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateManagementNetworkRoutePayload {\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("labels")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * UpdateManagementNetworkRoutePayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!UpdateManagementNetworkRoutePayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in UpdateManagementNetworkRoutePayload is not found in the empty JSON string", + UpdateManagementNetworkRoutePayload.openapiRequiredFields + .toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!UpdateManagementNetworkRoutePayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `UpdateManagementNetworkRoutePayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!UpdateManagementNetworkRoutePayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'UpdateManagementNetworkRoutePayload' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(UpdateManagementNetworkRoutePayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, UpdateManagementNetworkRoutePayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public UpdateManagementNetworkRoutePayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of UpdateManagementNetworkRoutePayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of UpdateManagementNetworkRoutePayload + * @throws IOException if the JSON string is invalid with respect to + * UpdateManagementNetworkRoutePayload + */ + public static UpdateManagementNetworkRoutePayload fromJson(String jsonString) + throws IOException { + return JSON.getGson().fromJson(jsonString, UpdateManagementNetworkRoutePayload.class); + } + + /** + * Convert an instance of UpdateManagementNetworkRoutePayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNetworkIPv4Body.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNetworkIPv4Body.java index 440f958..d3e8476 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNetworkIPv4Body.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNetworkIPv4Body.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -55,8 +55,8 @@ public UpdateNetworkIPv4Body gateway(@javax.annotation.Nullable String gateway) } /** - * The gateway of a network. If not specified the first IP of the network will be assigned as - * the gateway. If 'null' is sent, then the network doesn't have a gateway. + * The IPv4 gateway of a network. If not specified the first IP of the network will be assigned + * as the gateway. If 'null' is sent, then the network doesn't have a gateway. * * @return gateway */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNetworkIPv6Body.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNetworkIPv6Body.java index 69d2785..6f86bd9 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNetworkIPv6Body.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNetworkIPv6Body.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -55,8 +55,8 @@ public UpdateNetworkIPv6Body gateway(@javax.annotation.Nullable String gateway) } /** - * The gateway of a network. If not specified the first IP of the network will be assigned as - * the gateway. If 'null' is sent, then the network doesn't have a gateway. + * The IPv6 gateway of a network. If not specified the first IP of the network will be assigned + * as the gateway. If 'null' is sent, then the network doesn't have a gateway. * * @return gateway */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNicPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNicPayload.java index a97b192..a9a632f 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNicPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateNicPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -43,6 +43,11 @@ public class UpdateNicPayload { @SerializedName(SERIALIZED_NAME_ALLOWED_ADDRESSES) @javax.annotation.Nullable private List allowedAddresses = new ArrayList<>(); + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + @javax.annotation.Nullable private String description; + public static final String SERIALIZED_NAME_LABELS = "labels"; @SerializedName(SERIALIZED_NAME_LABELS) @@ -93,6 +98,24 @@ public void setAllowedAddresses( this.allowedAddresses = allowedAddresses; } + public UpdateNicPayload description(@javax.annotation.Nullable String description) { + this.description = description; + return this; + } + + /** + * Description Object. Allows string up to 255 Characters. + * + * @return description + */ + @javax.annotation.Nullable public String getDescription() { + return description; + } + + public void setDescription(@javax.annotation.Nullable String description) { + this.description = description; + } + public UpdateNicPayload labels(@javax.annotation.Nullable Object labels) { this.labels = labels; return this; @@ -100,9 +123,9 @@ public UpdateNicPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ @@ -186,6 +209,7 @@ public boolean equals(Object o) { } UpdateNicPayload updateNicPayload = (UpdateNicPayload) o; return Objects.equals(this.allowedAddresses, updateNicPayload.allowedAddresses) + && Objects.equals(this.description, updateNicPayload.description) && Objects.equals(this.labels, updateNicPayload.labels) && Objects.equals(this.name, updateNicPayload.name) && Objects.equals(this.nicSecurity, updateNicPayload.nicSecurity) @@ -194,7 +218,8 @@ public boolean equals(Object o) { @Override public int hashCode() { - return Objects.hash(allowedAddresses, labels, name, nicSecurity, securityGroups); + return Objects.hash( + allowedAddresses, description, labels, name, nicSecurity, securityGroups); } @Override @@ -202,6 +227,7 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class UpdateNicPayload {\n"); sb.append(" allowedAddresses: ").append(toIndentedString(allowedAddresses)).append("\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); sb.append(" name: ").append(toIndentedString(name)).append("\n"); sb.append(" nicSecurity: ").append(toIndentedString(nicSecurity)).append("\n"); @@ -230,6 +256,7 @@ private String toIndentedString(Object o) { new HashSet( Arrays.asList( "allowedAddresses", + "description", "labels", "name", "nicSecurity", @@ -286,6 +313,13 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti ; } } + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) + && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `description` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("description").toString())); + } if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) && !jsonObj.get("name").isJsonPrimitive()) { throw new IllegalArgumentException( diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdatePublicIPPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdatePublicIPPayload.java index 09a4d02..e5564e7 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdatePublicIPPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdatePublicIPPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -74,7 +74,7 @@ public UpdatePublicIPPayload(UUID id, String ip) { } /** - * Object that represents an IP address. + * String that represents an IPv4 address. * * @return ip */ @@ -89,9 +89,9 @@ public UpdatePublicIPPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRegionalAreaIPv4.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRegionalAreaIPv4.java new file mode 100644 index 0000000..4bcb8e3 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRegionalAreaIPv4.java @@ -0,0 +1,295 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.HashSet; +import java.util.List; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** + * Object that represents the request body for a regional network area IPv4 configuration update. + */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class UpdateRegionalAreaIPv4 { + public static final String SERIALIZED_NAME_DEFAULT_NAMESERVERS = "defaultNameservers"; + + @SerializedName(SERIALIZED_NAME_DEFAULT_NAMESERVERS) + @javax.annotation.Nullable private List defaultNameservers = new ArrayList<>(); + + public static final String SERIALIZED_NAME_DEFAULT_PREFIX_LEN = "defaultPrefixLen"; + + @SerializedName(SERIALIZED_NAME_DEFAULT_PREFIX_LEN) + @javax.annotation.Nullable private Long defaultPrefixLen; + + public static final String SERIALIZED_NAME_MAX_PREFIX_LEN = "maxPrefixLen"; + + @SerializedName(SERIALIZED_NAME_MAX_PREFIX_LEN) + @javax.annotation.Nullable private Long maxPrefixLen; + + public static final String SERIALIZED_NAME_MIN_PREFIX_LEN = "minPrefixLen"; + + @SerializedName(SERIALIZED_NAME_MIN_PREFIX_LEN) + @javax.annotation.Nullable private Long minPrefixLen; + + public UpdateRegionalAreaIPv4() {} + + public UpdateRegionalAreaIPv4 defaultNameservers( + @javax.annotation.Nullable List defaultNameservers) { + this.defaultNameservers = defaultNameservers; + return this; + } + + public UpdateRegionalAreaIPv4 addDefaultNameserversItem(String defaultNameserversItem) { + if (this.defaultNameservers == null) { + this.defaultNameservers = new ArrayList<>(); + } + this.defaultNameservers.add(defaultNameserversItem); + return this; + } + + /** + * Get defaultNameservers + * + * @return defaultNameservers + */ + @javax.annotation.Nullable public List getDefaultNameservers() { + return defaultNameservers; + } + + public void setDefaultNameservers(@javax.annotation.Nullable List defaultNameservers) { + this.defaultNameservers = defaultNameservers; + } + + public UpdateRegionalAreaIPv4 defaultPrefixLen( + @javax.annotation.Nullable Long defaultPrefixLen) { + this.defaultPrefixLen = defaultPrefixLen; + return this; + } + + /** + * The default prefix length for networks in the network area. minimum: 24 maximum: 29 + * + * @return defaultPrefixLen + */ + @javax.annotation.Nullable public Long getDefaultPrefixLen() { + return defaultPrefixLen; + } + + public void setDefaultPrefixLen(@javax.annotation.Nullable Long defaultPrefixLen) { + this.defaultPrefixLen = defaultPrefixLen; + } + + public UpdateRegionalAreaIPv4 maxPrefixLen(@javax.annotation.Nullable Long maxPrefixLen) { + this.maxPrefixLen = maxPrefixLen; + return this; + } + + /** + * The maximal prefix length for networks in the network area. minimum: 24 maximum: 29 + * + * @return maxPrefixLen + */ + @javax.annotation.Nullable public Long getMaxPrefixLen() { + return maxPrefixLen; + } + + public void setMaxPrefixLen(@javax.annotation.Nullable Long maxPrefixLen) { + this.maxPrefixLen = maxPrefixLen; + } + + public UpdateRegionalAreaIPv4 minPrefixLen(@javax.annotation.Nullable Long minPrefixLen) { + this.minPrefixLen = minPrefixLen; + return this; + } + + /** + * The minimal prefix length for networks in the network area. minimum: 8 maximum: 29 + * + * @return minPrefixLen + */ + @javax.annotation.Nullable public Long getMinPrefixLen() { + return minPrefixLen; + } + + public void setMinPrefixLen(@javax.annotation.Nullable Long minPrefixLen) { + this.minPrefixLen = minPrefixLen; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateRegionalAreaIPv4 updateRegionalAreaIPv4 = (UpdateRegionalAreaIPv4) o; + return Objects.equals(this.defaultNameservers, updateRegionalAreaIPv4.defaultNameservers) + && Objects.equals(this.defaultPrefixLen, updateRegionalAreaIPv4.defaultPrefixLen) + && Objects.equals(this.maxPrefixLen, updateRegionalAreaIPv4.maxPrefixLen) + && Objects.equals(this.minPrefixLen, updateRegionalAreaIPv4.minPrefixLen); + } + + @Override + public int hashCode() { + return Objects.hash(defaultNameservers, defaultPrefixLen, maxPrefixLen, minPrefixLen); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateRegionalAreaIPv4 {\n"); + sb.append(" defaultNameservers: ") + .append(toIndentedString(defaultNameservers)) + .append("\n"); + sb.append(" defaultPrefixLen: ").append(toIndentedString(defaultPrefixLen)).append("\n"); + sb.append(" maxPrefixLen: ").append(toIndentedString(maxPrefixLen)).append("\n"); + sb.append(" minPrefixLen: ").append(toIndentedString(minPrefixLen)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = + new HashSet( + Arrays.asList( + "defaultNameservers", + "defaultPrefixLen", + "maxPrefixLen", + "minPrefixLen")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to UpdateRegionalAreaIPv4 + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!UpdateRegionalAreaIPv4.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in UpdateRegionalAreaIPv4 is not found in the empty JSON string", + UpdateRegionalAreaIPv4.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!UpdateRegionalAreaIPv4.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `UpdateRegionalAreaIPv4` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // ensure the optional json data is an array if present + if (jsonObj.get("defaultNameservers") != null + && !jsonObj.get("defaultNameservers").isJsonNull() + && !jsonObj.get("defaultNameservers").isJsonArray()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `defaultNameservers` to be an array in the JSON string but got `%s`", + jsonObj.get("defaultNameservers").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!UpdateRegionalAreaIPv4.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'UpdateRegionalAreaIPv4' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(UpdateRegionalAreaIPv4.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, UpdateRegionalAreaIPv4 value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public UpdateRegionalAreaIPv4 read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of UpdateRegionalAreaIPv4 given an JSON string + * + * @param jsonString JSON string + * @return An instance of UpdateRegionalAreaIPv4 + * @throws IOException if the JSON string is invalid with respect to UpdateRegionalAreaIPv4 + */ + public static UpdateRegionalAreaIPv4 fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, UpdateRegionalAreaIPv4.class); + } + + /** + * Convert an instance of UpdateRegionalAreaIPv4 to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRouteOfRoutingTablePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRouteOfRoutingTablePayload.java new file mode 100644 index 0000000..a774ef9 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRouteOfRoutingTablePayload.java @@ -0,0 +1,198 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents the request body for a route update. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class UpdateRouteOfRoutingTablePayload { + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public UpdateRouteOfRoutingTablePayload() {} + + public UpdateRouteOfRoutingTablePayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateRouteOfRoutingTablePayload updateRouteOfRoutingTablePayload = + (UpdateRouteOfRoutingTablePayload) o; + return Objects.equals(this.labels, updateRouteOfRoutingTablePayload.labels); + } + + @Override + public int hashCode() { + return Objects.hash(labels); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateRouteOfRoutingTablePayload {\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("labels")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * UpdateRouteOfRoutingTablePayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!UpdateRouteOfRoutingTablePayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in UpdateRouteOfRoutingTablePayload is not found in the empty JSON string", + UpdateRouteOfRoutingTablePayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!UpdateRouteOfRoutingTablePayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `UpdateRouteOfRoutingTablePayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!UpdateRouteOfRoutingTablePayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'UpdateRouteOfRoutingTablePayload' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(UpdateRouteOfRoutingTablePayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, UpdateRouteOfRoutingTablePayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public UpdateRouteOfRoutingTablePayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of UpdateRouteOfRoutingTablePayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of UpdateRouteOfRoutingTablePayload + * @throws IOException if the JSON string is invalid with respect to + * UpdateRouteOfRoutingTablePayload + */ + public static UpdateRouteOfRoutingTablePayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, UpdateRouteOfRoutingTablePayload.class); + } + + /** + * Convert an instance of UpdateRouteOfRoutingTablePayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRoutingTableOfAreaPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRoutingTableOfAreaPayload.java new file mode 100644 index 0000000..717dbe0 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRoutingTableOfAreaPayload.java @@ -0,0 +1,263 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents the request body for a routing table update. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class UpdateRoutingTableOfAreaPayload { + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + @javax.annotation.Nullable private String description; + + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public static final String SERIALIZED_NAME_NAME = "name"; + + @SerializedName(SERIALIZED_NAME_NAME) + @javax.annotation.Nullable private String name; + + public UpdateRoutingTableOfAreaPayload() {} + + public UpdateRoutingTableOfAreaPayload description( + @javax.annotation.Nullable String description) { + this.description = description; + return this; + } + + /** + * Description Object. Allows string up to 255 Characters. + * + * @return description + */ + @javax.annotation.Nullable public String getDescription() { + return description; + } + + public void setDescription(@javax.annotation.Nullable String description) { + this.description = description; + } + + public UpdateRoutingTableOfAreaPayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + public UpdateRoutingTableOfAreaPayload name(@javax.annotation.Nullable String name) { + this.name = name; + return this; + } + + /** + * The name for a General Object. Matches Names and also UUIDs. + * + * @return name + */ + @javax.annotation.Nullable public String getName() { + return name; + } + + public void setName(@javax.annotation.Nullable String name) { + this.name = name; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + UpdateRoutingTableOfAreaPayload updateRoutingTableOfAreaPayload = + (UpdateRoutingTableOfAreaPayload) o; + return Objects.equals(this.description, updateRoutingTableOfAreaPayload.description) + && Objects.equals(this.labels, updateRoutingTableOfAreaPayload.labels) + && Objects.equals(this.name, updateRoutingTableOfAreaPayload.name); + } + + @Override + public int hashCode() { + return Objects.hash(description, labels, name); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class UpdateRoutingTableOfAreaPayload {\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("description", "labels", "name")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * UpdateRoutingTableOfAreaPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!UpdateRoutingTableOfAreaPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in UpdateRoutingTableOfAreaPayload is not found in the empty JSON string", + UpdateRoutingTableOfAreaPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!UpdateRoutingTableOfAreaPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `UpdateRoutingTableOfAreaPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) + && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `description` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("description").toString())); + } + if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) + && !jsonObj.get("name").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `name` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("name").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!UpdateRoutingTableOfAreaPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'UpdateRoutingTableOfAreaPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(UpdateRoutingTableOfAreaPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, UpdateRoutingTableOfAreaPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public UpdateRoutingTableOfAreaPayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of UpdateRoutingTableOfAreaPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of UpdateRoutingTableOfAreaPayload + * @throws IOException if the JSON string is invalid with respect to + * UpdateRoutingTableOfAreaPayload + */ + public static UpdateRoutingTableOfAreaPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, UpdateRoutingTableOfAreaPayload.class); + } + + /** + * Convert an instance of UpdateRoutingTableOfAreaPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateServerPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateServerPayload.java index a6eeeb7..653ec7c 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateServerPayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateServerPayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -58,9 +58,9 @@ public UpdateServerPayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateVolumePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateVolumePayload.java index 55a937f..b3145b0 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateVolumePayload.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateVolumePayload.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -122,9 +122,9 @@ public UpdateVolumePayload labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1ConfigureNetworkAreaRegionPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1ConfigureNetworkAreaRegionPayload.java new file mode 100644 index 0000000..2c98634 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1ConfigureNetworkAreaRegionPayload.java @@ -0,0 +1,234 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** The basic properties of a regional network area. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class V2beta1ConfigureNetworkAreaRegionPayload { + public static final String SERIALIZED_NAME_IPV4 = "ipv4"; + + @SerializedName(SERIALIZED_NAME_IPV4) + @javax.annotation.Nullable private RegionalAreaIPv4 ipv4; + + public static final String SERIALIZED_NAME_STATUS = "status"; + + @SerializedName(SERIALIZED_NAME_STATUS) + @javax.annotation.Nullable private String status; + + public V2beta1ConfigureNetworkAreaRegionPayload() {} + + public V2beta1ConfigureNetworkAreaRegionPayload(String status) { + this(); + this.status = status; + } + + public V2beta1ConfigureNetworkAreaRegionPayload ipv4( + @javax.annotation.Nullable RegionalAreaIPv4 ipv4) { + this.ipv4 = ipv4; + return this; + } + + /** + * Get ipv4 + * + * @return ipv4 + */ + @javax.annotation.Nullable public RegionalAreaIPv4 getIpv4() { + return ipv4; + } + + public void setIpv4(@javax.annotation.Nullable RegionalAreaIPv4 ipv4) { + this.ipv4 = ipv4; + } + + /** + * The state of a resource object. Possible values: `CREATING`, `CREATED`, + * `DELETING`, `DELETED`, `FAILED`, `UPDATED`, + * `UPDATING`. + * + * @return status + */ + @javax.annotation.Nullable public String getStatus() { + return status; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + V2beta1ConfigureNetworkAreaRegionPayload v2beta1ConfigureNetworkAreaRegionPayload = + (V2beta1ConfigureNetworkAreaRegionPayload) o; + return Objects.equals(this.ipv4, v2beta1ConfigureNetworkAreaRegionPayload.ipv4) + && Objects.equals(this.status, v2beta1ConfigureNetworkAreaRegionPayload.status); + } + + @Override + public int hashCode() { + return Objects.hash(ipv4, status); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2beta1ConfigureNetworkAreaRegionPayload {\n"); + sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("ipv4", "status")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * V2beta1ConfigureNetworkAreaRegionPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2beta1ConfigureNetworkAreaRegionPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2beta1ConfigureNetworkAreaRegionPayload is not found in the empty JSON string", + V2beta1ConfigureNetworkAreaRegionPayload.openapiRequiredFields + .toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2beta1ConfigureNetworkAreaRegionPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2beta1ConfigureNetworkAreaRegionPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // validate the optional field `ipv4` + if (jsonObj.get("ipv4") != null && !jsonObj.get("ipv4").isJsonNull()) { + RegionalAreaIPv4.validateJsonElement(jsonObj.get("ipv4")); + } + if ((jsonObj.get("status") != null && !jsonObj.get("status").isJsonNull()) + && !jsonObj.get("status").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `status` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("status").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!V2beta1ConfigureNetworkAreaRegionPayload.class.isAssignableFrom( + type.getRawType())) { + return null; // this class only serializes + // 'V2beta1ConfigureNetworkAreaRegionPayload' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2beta1ConfigureNetworkAreaRegionPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write( + JsonWriter out, V2beta1ConfigureNetworkAreaRegionPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2beta1ConfigureNetworkAreaRegionPayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2beta1ConfigureNetworkAreaRegionPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2beta1ConfigureNetworkAreaRegionPayload + * @throws IOException if the JSON string is invalid with respect to + * V2beta1ConfigureNetworkAreaRegionPayload + */ + public static V2beta1ConfigureNetworkAreaRegionPayload fromJson(String jsonString) + throws IOException { + return JSON.getGson().fromJson(jsonString, V2beta1ConfigureNetworkAreaRegionPayload.class); + } + + /** + * Convert an instance of V2beta1ConfigureNetworkAreaRegionPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1CreateSnapshotPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1CreateSnapshotPayload.java new file mode 100644 index 0000000..b90df9f --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1CreateSnapshotPayload.java @@ -0,0 +1,390 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.time.OffsetDateTime; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import java.util.UUID; + +/** Object that represents a snapshot. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class V2beta1CreateSnapshotPayload { + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + + @SerializedName(SERIALIZED_NAME_CREATED_AT) + @javax.annotation.Nullable private OffsetDateTime createdAt; + + public static final String SERIALIZED_NAME_ID = "id"; + + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nullable private UUID id; + + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public static final String SERIALIZED_NAME_NAME = "name"; + + @SerializedName(SERIALIZED_NAME_NAME) + @javax.annotation.Nullable private String name; + + public static final String SERIALIZED_NAME_SIZE = "size"; + + @SerializedName(SERIALIZED_NAME_SIZE) + @javax.annotation.Nullable private Long size; + + public static final String SERIALIZED_NAME_STATUS = "status"; + + @SerializedName(SERIALIZED_NAME_STATUS) + @javax.annotation.Nullable private String status; + + public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; + + @SerializedName(SERIALIZED_NAME_UPDATED_AT) + @javax.annotation.Nullable private OffsetDateTime updatedAt; + + public static final String SERIALIZED_NAME_VOLUME_ID = "volumeId"; + + @SerializedName(SERIALIZED_NAME_VOLUME_ID) + @javax.annotation.Nonnull + private UUID volumeId; + + public V2beta1CreateSnapshotPayload() {} + + public V2beta1CreateSnapshotPayload( + OffsetDateTime createdAt, UUID id, Long size, String status, OffsetDateTime updatedAt) { + this(); + this.createdAt = createdAt; + this.id = id; + this.size = size; + this.status = status; + this.updatedAt = updatedAt; + } + + /** + * Date-time when resource was created. + * + * @return createdAt + */ + @javax.annotation.Nullable public OffsetDateTime getCreatedAt() { + return createdAt; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return id + */ + @javax.annotation.Nullable public UUID getId() { + return id; + } + + public V2beta1CreateSnapshotPayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + public V2beta1CreateSnapshotPayload name(@javax.annotation.Nullable String name) { + this.name = name; + return this; + } + + /** + * The name for a General Object. Matches Names and also UUIDs. + * + * @return name + */ + @javax.annotation.Nullable public String getName() { + return name; + } + + public void setName(@javax.annotation.Nullable String name) { + this.name = name; + } + + /** + * Size in Gigabyte. + * + * @return size + */ + @javax.annotation.Nullable public Long getSize() { + return size; + } + + /** + * The status of a snapshot object. Possible values: `AVAILABLE`, + * `BACKING-UP`, `CREATING`, `DELETED`, `DELETING`, + * `ERROR`, `RESTORING`, `UNMANAGING`, `UPDATING`. + * + * @return status + */ + @javax.annotation.Nullable public String getStatus() { + return status; + } + + /** + * Date-time when resource was last updated. + * + * @return updatedAt + */ + @javax.annotation.Nullable public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + + public V2beta1CreateSnapshotPayload volumeId(@javax.annotation.Nonnull UUID volumeId) { + this.volumeId = volumeId; + return this; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return volumeId + */ + @javax.annotation.Nonnull + public UUID getVolumeId() { + return volumeId; + } + + public void setVolumeId(@javax.annotation.Nonnull UUID volumeId) { + this.volumeId = volumeId; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + V2beta1CreateSnapshotPayload v2beta1CreateSnapshotPayload = + (V2beta1CreateSnapshotPayload) o; + return Objects.equals(this.createdAt, v2beta1CreateSnapshotPayload.createdAt) + && Objects.equals(this.id, v2beta1CreateSnapshotPayload.id) + && Objects.equals(this.labels, v2beta1CreateSnapshotPayload.labels) + && Objects.equals(this.name, v2beta1CreateSnapshotPayload.name) + && Objects.equals(this.size, v2beta1CreateSnapshotPayload.size) + && Objects.equals(this.status, v2beta1CreateSnapshotPayload.status) + && Objects.equals(this.updatedAt, v2beta1CreateSnapshotPayload.updatedAt) + && Objects.equals(this.volumeId, v2beta1CreateSnapshotPayload.volumeId); + } + + @Override + public int hashCode() { + return Objects.hash(createdAt, id, labels, name, size, status, updatedAt, volumeId); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2beta1CreateSnapshotPayload {\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" size: ").append(toIndentedString(size)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); + sb.append(" volumeId: ").append(toIndentedString(volumeId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = + new HashSet( + Arrays.asList( + "createdAt", + "id", + "labels", + "name", + "size", + "status", + "updatedAt", + "volumeId")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(Arrays.asList("volumeId")); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * V2beta1CreateSnapshotPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2beta1CreateSnapshotPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2beta1CreateSnapshotPayload is not found in the empty JSON string", + V2beta1CreateSnapshotPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2beta1CreateSnapshotPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2beta1CreateSnapshotPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : V2beta1CreateSnapshotPayload.openapiRequiredFields) { + if (jsonElement.getAsJsonObject().get(requiredField) == null) { + throw new IllegalArgumentException( + String.format( + "The required field `%s` is not found in the JSON string: %s", + requiredField, jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) + && !jsonObj.get("id").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); + } + if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) + && !jsonObj.get("name").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `name` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("name").toString())); + } + if ((jsonObj.get("status") != null && !jsonObj.get("status").isJsonNull()) + && !jsonObj.get("status").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `status` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("status").toString())); + } + if (!jsonObj.get("volumeId").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `volumeId` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("volumeId").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!V2beta1CreateSnapshotPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2beta1CreateSnapshotPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2beta1CreateSnapshotPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2beta1CreateSnapshotPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2beta1CreateSnapshotPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2beta1CreateSnapshotPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2beta1CreateSnapshotPayload + * @throws IOException if the JSON string is invalid with respect to + * V2beta1CreateSnapshotPayload + */ + public static V2beta1CreateSnapshotPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2beta1CreateSnapshotPayload.class); + } + + /** + * Convert an instance of V2beta1CreateSnapshotPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateBackupPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateBackupPayload.java new file mode 100644 index 0000000..d576b58 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateBackupPayload.java @@ -0,0 +1,434 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.time.OffsetDateTime; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; +import java.util.UUID; + +/** Object that represents a backup. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class V2beta1UpdateBackupPayload { + public static final String SERIALIZED_NAME_AVAILABILITY_ZONE = "availabilityZone"; + + @SerializedName(SERIALIZED_NAME_AVAILABILITY_ZONE) + @javax.annotation.Nullable private String availabilityZone; + + public static final String SERIALIZED_NAME_CREATED_AT = "createdAt"; + + @SerializedName(SERIALIZED_NAME_CREATED_AT) + @javax.annotation.Nullable private OffsetDateTime createdAt; + + public static final String SERIALIZED_NAME_ID = "id"; + + @SerializedName(SERIALIZED_NAME_ID) + @javax.annotation.Nullable private UUID id; + + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public static final String SERIALIZED_NAME_NAME = "name"; + + @SerializedName(SERIALIZED_NAME_NAME) + @javax.annotation.Nullable private String name; + + public static final String SERIALIZED_NAME_SIZE = "size"; + + @SerializedName(SERIALIZED_NAME_SIZE) + @javax.annotation.Nullable private Long size; + + public static final String SERIALIZED_NAME_SNAPSHOT_ID = "snapshotId"; + + @SerializedName(SERIALIZED_NAME_SNAPSHOT_ID) + @javax.annotation.Nullable private UUID snapshotId; + + public static final String SERIALIZED_NAME_STATUS = "status"; + + @SerializedName(SERIALIZED_NAME_STATUS) + @javax.annotation.Nullable private String status; + + public static final String SERIALIZED_NAME_UPDATED_AT = "updatedAt"; + + @SerializedName(SERIALIZED_NAME_UPDATED_AT) + @javax.annotation.Nullable private OffsetDateTime updatedAt; + + public static final String SERIALIZED_NAME_VOLUME_ID = "volumeId"; + + @SerializedName(SERIALIZED_NAME_VOLUME_ID) + @javax.annotation.Nullable private UUID volumeId; + + public V2beta1UpdateBackupPayload() {} + + public V2beta1UpdateBackupPayload( + String availabilityZone, + OffsetDateTime createdAt, + UUID id, + Long size, + UUID snapshotId, + String status, + OffsetDateTime updatedAt, + UUID volumeId) { + this(); + this.availabilityZone = availabilityZone; + this.createdAt = createdAt; + this.id = id; + this.size = size; + this.snapshotId = snapshotId; + this.status = status; + this.updatedAt = updatedAt; + this.volumeId = volumeId; + } + + /** + * Object that represents an availability zone. + * + * @return availabilityZone + */ + @javax.annotation.Nullable public String getAvailabilityZone() { + return availabilityZone; + } + + /** + * Date-time when resource was created. + * + * @return createdAt + */ + @javax.annotation.Nullable public OffsetDateTime getCreatedAt() { + return createdAt; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return id + */ + @javax.annotation.Nullable public UUID getId() { + return id; + } + + public V2beta1UpdateBackupPayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + public V2beta1UpdateBackupPayload name(@javax.annotation.Nullable String name) { + this.name = name; + return this; + } + + /** + * The name for a General Object. Matches Names and also UUIDs. + * + * @return name + */ + @javax.annotation.Nullable public String getName() { + return name; + } + + public void setName(@javax.annotation.Nullable String name) { + this.name = name; + } + + /** + * Size in Gigabyte. + * + * @return size + */ + @javax.annotation.Nullable public Long getSize() { + return size; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return snapshotId + */ + @javax.annotation.Nullable public UUID getSnapshotId() { + return snapshotId; + } + + /** + * The status of a backup object. Possible values: `AVAILABLE`, `CREATING`, + * `DELETED`, `DELETING`, `ERROR`, `RESTORING`. + * + * @return status + */ + @javax.annotation.Nullable public String getStatus() { + return status; + } + + /** + * Date-time when resource was last updated. + * + * @return updatedAt + */ + @javax.annotation.Nullable public OffsetDateTime getUpdatedAt() { + return updatedAt; + } + + /** + * Universally Unique Identifier (UUID). + * + * @return volumeId + */ + @javax.annotation.Nullable public UUID getVolumeId() { + return volumeId; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + V2beta1UpdateBackupPayload v2beta1UpdateBackupPayload = (V2beta1UpdateBackupPayload) o; + return Objects.equals(this.availabilityZone, v2beta1UpdateBackupPayload.availabilityZone) + && Objects.equals(this.createdAt, v2beta1UpdateBackupPayload.createdAt) + && Objects.equals(this.id, v2beta1UpdateBackupPayload.id) + && Objects.equals(this.labels, v2beta1UpdateBackupPayload.labels) + && Objects.equals(this.name, v2beta1UpdateBackupPayload.name) + && Objects.equals(this.size, v2beta1UpdateBackupPayload.size) + && Objects.equals(this.snapshotId, v2beta1UpdateBackupPayload.snapshotId) + && Objects.equals(this.status, v2beta1UpdateBackupPayload.status) + && Objects.equals(this.updatedAt, v2beta1UpdateBackupPayload.updatedAt) + && Objects.equals(this.volumeId, v2beta1UpdateBackupPayload.volumeId); + } + + @Override + public int hashCode() { + return Objects.hash( + availabilityZone, + createdAt, + id, + labels, + name, + size, + snapshotId, + status, + updatedAt, + volumeId); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2beta1UpdateBackupPayload {\n"); + sb.append(" availabilityZone: ").append(toIndentedString(availabilityZone)).append("\n"); + sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n"); + sb.append(" id: ").append(toIndentedString(id)).append("\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append(" size: ").append(toIndentedString(size)).append("\n"); + sb.append(" snapshotId: ").append(toIndentedString(snapshotId)).append("\n"); + sb.append(" status: ").append(toIndentedString(status)).append("\n"); + sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n"); + sb.append(" volumeId: ").append(toIndentedString(volumeId)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = + new HashSet( + Arrays.asList( + "availabilityZone", + "createdAt", + "id", + "labels", + "name", + "size", + "snapshotId", + "status", + "updatedAt", + "volumeId")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to V2beta1UpdateBackupPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2beta1UpdateBackupPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2beta1UpdateBackupPayload is not found in the empty JSON string", + V2beta1UpdateBackupPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2beta1UpdateBackupPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2beta1UpdateBackupPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("availabilityZone") != null + && !jsonObj.get("availabilityZone").isJsonNull()) + && !jsonObj.get("availabilityZone").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `availabilityZone` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("availabilityZone").toString())); + } + if ((jsonObj.get("id") != null && !jsonObj.get("id").isJsonNull()) + && !jsonObj.get("id").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `id` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("id").toString())); + } + if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) + && !jsonObj.get("name").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `name` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("name").toString())); + } + if ((jsonObj.get("snapshotId") != null && !jsonObj.get("snapshotId").isJsonNull()) + && !jsonObj.get("snapshotId").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `snapshotId` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("snapshotId").toString())); + } + if ((jsonObj.get("status") != null && !jsonObj.get("status").isJsonNull()) + && !jsonObj.get("status").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `status` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("status").toString())); + } + if ((jsonObj.get("volumeId") != null && !jsonObj.get("volumeId").isJsonNull()) + && !jsonObj.get("volumeId").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `volumeId` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("volumeId").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!V2beta1UpdateBackupPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2beta1UpdateBackupPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(V2beta1UpdateBackupPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2beta1UpdateBackupPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2beta1UpdateBackupPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2beta1UpdateBackupPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2beta1UpdateBackupPayload + * @throws IOException if the JSON string is invalid with respect to V2beta1UpdateBackupPayload + */ + public static V2beta1UpdateBackupPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2beta1UpdateBackupPayload.class); + } + + /** + * Convert an instance of V2beta1UpdateBackupPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateNetworkAreaRegionPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateNetworkAreaRegionPayload.java new file mode 100644 index 0000000..e46596c --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateNetworkAreaRegionPayload.java @@ -0,0 +1,203 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents the request body for a regional network area update. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class V2beta1UpdateNetworkAreaRegionPayload { + public static final String SERIALIZED_NAME_IPV4 = "ipv4"; + + @SerializedName(SERIALIZED_NAME_IPV4) + @javax.annotation.Nullable private UpdateRegionalAreaIPv4 ipv4; + + public V2beta1UpdateNetworkAreaRegionPayload() {} + + public V2beta1UpdateNetworkAreaRegionPayload ipv4( + @javax.annotation.Nullable UpdateRegionalAreaIPv4 ipv4) { + this.ipv4 = ipv4; + return this; + } + + /** + * Get ipv4 + * + * @return ipv4 + */ + @javax.annotation.Nullable public UpdateRegionalAreaIPv4 getIpv4() { + return ipv4; + } + + public void setIpv4(@javax.annotation.Nullable UpdateRegionalAreaIPv4 ipv4) { + this.ipv4 = ipv4; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + V2beta1UpdateNetworkAreaRegionPayload v2beta1UpdateNetworkAreaRegionPayload = + (V2beta1UpdateNetworkAreaRegionPayload) o; + return Objects.equals(this.ipv4, v2beta1UpdateNetworkAreaRegionPayload.ipv4); + } + + @Override + public int hashCode() { + return Objects.hash(ipv4); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2beta1UpdateNetworkAreaRegionPayload {\n"); + sb.append(" ipv4: ").append(toIndentedString(ipv4)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("ipv4")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * V2beta1UpdateNetworkAreaRegionPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2beta1UpdateNetworkAreaRegionPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2beta1UpdateNetworkAreaRegionPayload is not found in the empty JSON string", + V2beta1UpdateNetworkAreaRegionPayload.openapiRequiredFields + .toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2beta1UpdateNetworkAreaRegionPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2beta1UpdateNetworkAreaRegionPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + // validate the optional field `ipv4` + if (jsonObj.get("ipv4") != null && !jsonObj.get("ipv4").isJsonNull()) { + UpdateRegionalAreaIPv4.validateJsonElement(jsonObj.get("ipv4")); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!V2beta1UpdateNetworkAreaRegionPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2beta1UpdateNetworkAreaRegionPayload' + // and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2beta1UpdateNetworkAreaRegionPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write( + JsonWriter out, V2beta1UpdateNetworkAreaRegionPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2beta1UpdateNetworkAreaRegionPayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2beta1UpdateNetworkAreaRegionPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2beta1UpdateNetworkAreaRegionPayload + * @throws IOException if the JSON string is invalid with respect to + * V2beta1UpdateNetworkAreaRegionPayload + */ + public static V2beta1UpdateNetworkAreaRegionPayload fromJson(String jsonString) + throws IOException { + return JSON.getGson().fromJson(jsonString, V2beta1UpdateNetworkAreaRegionPayload.class); + } + + /** + * Convert an instance of V2beta1UpdateNetworkAreaRegionPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateRouteOfAreaPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateRouteOfAreaPayload.java new file mode 100644 index 0000000..b0b7b8e --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateRouteOfAreaPayload.java @@ -0,0 +1,198 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents the request body for a route update. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class V2beta1UpdateRouteOfAreaPayload { + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public V2beta1UpdateRouteOfAreaPayload() {} + + public V2beta1UpdateRouteOfAreaPayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + V2beta1UpdateRouteOfAreaPayload v2beta1UpdateRouteOfAreaPayload = + (V2beta1UpdateRouteOfAreaPayload) o; + return Objects.equals(this.labels, v2beta1UpdateRouteOfAreaPayload.labels); + } + + @Override + public int hashCode() { + return Objects.hash(labels); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2beta1UpdateRouteOfAreaPayload {\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("labels")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * V2beta1UpdateRouteOfAreaPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2beta1UpdateRouteOfAreaPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2beta1UpdateRouteOfAreaPayload is not found in the empty JSON string", + V2beta1UpdateRouteOfAreaPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2beta1UpdateRouteOfAreaPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2beta1UpdateRouteOfAreaPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!V2beta1UpdateRouteOfAreaPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2beta1UpdateRouteOfAreaPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2beta1UpdateRouteOfAreaPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2beta1UpdateRouteOfAreaPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2beta1UpdateRouteOfAreaPayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2beta1UpdateRouteOfAreaPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2beta1UpdateRouteOfAreaPayload + * @throws IOException if the JSON string is invalid with respect to + * V2beta1UpdateRouteOfAreaPayload + */ + public static V2beta1UpdateRouteOfAreaPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2beta1UpdateRouteOfAreaPayload.class); + } + + /** + * Convert an instance of V2beta1UpdateRouteOfAreaPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateSecurityGroupPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateSecurityGroupPayload.java new file mode 100644 index 0000000..5a6f8f6 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateSecurityGroupPayload.java @@ -0,0 +1,264 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents an update request body of a security group. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class V2beta1UpdateSecurityGroupPayload { + public static final String SERIALIZED_NAME_DESCRIPTION = "description"; + + @SerializedName(SERIALIZED_NAME_DESCRIPTION) + @javax.annotation.Nullable private String description; + + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public static final String SERIALIZED_NAME_NAME = "name"; + + @SerializedName(SERIALIZED_NAME_NAME) + @javax.annotation.Nullable private String name; + + public V2beta1UpdateSecurityGroupPayload() {} + + public V2beta1UpdateSecurityGroupPayload description( + @javax.annotation.Nullable String description) { + this.description = description; + return this; + } + + /** + * Description Object. Allows string up to 255 Characters. + * + * @return description + */ + @javax.annotation.Nullable public String getDescription() { + return description; + } + + public void setDescription(@javax.annotation.Nullable String description) { + this.description = description; + } + + public V2beta1UpdateSecurityGroupPayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + public V2beta1UpdateSecurityGroupPayload name(@javax.annotation.Nullable String name) { + this.name = name; + return this; + } + + /** + * The name for a General Object. Matches Names and also UUIDs. + * + * @return name + */ + @javax.annotation.Nullable public String getName() { + return name; + } + + public void setName(@javax.annotation.Nullable String name) { + this.name = name; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + V2beta1UpdateSecurityGroupPayload v2beta1UpdateSecurityGroupPayload = + (V2beta1UpdateSecurityGroupPayload) o; + return Objects.equals(this.description, v2beta1UpdateSecurityGroupPayload.description) + && Objects.equals(this.labels, v2beta1UpdateSecurityGroupPayload.labels) + && Objects.equals(this.name, v2beta1UpdateSecurityGroupPayload.name); + } + + @Override + public int hashCode() { + return Objects.hash(description, labels, name); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2beta1UpdateSecurityGroupPayload {\n"); + sb.append(" description: ").append(toIndentedString(description)).append("\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("description", "labels", "name")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * V2beta1UpdateSecurityGroupPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2beta1UpdateSecurityGroupPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2beta1UpdateSecurityGroupPayload is not found in the empty JSON string", + V2beta1UpdateSecurityGroupPayload.openapiRequiredFields + .toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2beta1UpdateSecurityGroupPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2beta1UpdateSecurityGroupPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("description") != null && !jsonObj.get("description").isJsonNull()) + && !jsonObj.get("description").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `description` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("description").toString())); + } + if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) + && !jsonObj.get("name").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `name` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("name").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!V2beta1UpdateSecurityGroupPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2beta1UpdateSecurityGroupPayload' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2beta1UpdateSecurityGroupPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2beta1UpdateSecurityGroupPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2beta1UpdateSecurityGroupPayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2beta1UpdateSecurityGroupPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2beta1UpdateSecurityGroupPayload + * @throws IOException if the JSON string is invalid with respect to + * V2beta1UpdateSecurityGroupPayload + */ + public static V2beta1UpdateSecurityGroupPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2beta1UpdateSecurityGroupPayload.class); + } + + /** + * Convert an instance of V2beta1UpdateSecurityGroupPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateSnapshotPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateSnapshotPayload.java new file mode 100644 index 0000000..62956ac --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2beta1UpdateSnapshotPayload.java @@ -0,0 +1,229 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2beta1 + * Contact: stackit-iaas@mail.schwarz + * + * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). + * https://openapi-generator.tech + * Do not edit the class manually. + */ + +package cloud.stackit.sdk.iaas.model; + +import cloud.stackit.sdk.iaas.JSON; +import com.google.gson.Gson; +import com.google.gson.JsonElement; +import com.google.gson.JsonObject; +import com.google.gson.TypeAdapter; +import com.google.gson.TypeAdapterFactory; +import com.google.gson.annotations.SerializedName; +import com.google.gson.reflect.TypeToken; +import com.google.gson.stream.JsonReader; +import com.google.gson.stream.JsonWriter; +import java.io.IOException; +import java.util.Arrays; +import java.util.HashSet; +import java.util.Map; +import java.util.Objects; +import java.util.Set; + +/** Object that represents an update request body of a snapshot. */ +@javax.annotation.Generated( + value = "org.openapitools.codegen.languages.JavaClientCodegen", + comments = "Generator version: 7.15.0") +public class V2beta1UpdateSnapshotPayload { + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public static final String SERIALIZED_NAME_NAME = "name"; + + @SerializedName(SERIALIZED_NAME_NAME) + @javax.annotation.Nullable private String name; + + public V2beta1UpdateSnapshotPayload() {} + + public V2beta1UpdateSnapshotPayload labels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + return this; + } + + /** + * Object that represents the labels of an object. Regex for keys: + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. + * + * @return labels + */ + @javax.annotation.Nullable public Object getLabels() { + return labels; + } + + public void setLabels(@javax.annotation.Nullable Object labels) { + this.labels = labels; + } + + public V2beta1UpdateSnapshotPayload name(@javax.annotation.Nullable String name) { + this.name = name; + return this; + } + + /** + * The name for a General Object. Matches Names and also UUIDs. + * + * @return name + */ + @javax.annotation.Nullable public String getName() { + return name; + } + + public void setName(@javax.annotation.Nullable String name) { + this.name = name; + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || getClass() != o.getClass()) { + return false; + } + V2beta1UpdateSnapshotPayload v2beta1UpdateSnapshotPayload = + (V2beta1UpdateSnapshotPayload) o; + return Objects.equals(this.labels, v2beta1UpdateSnapshotPayload.labels) + && Objects.equals(this.name, v2beta1UpdateSnapshotPayload.name); + } + + @Override + public int hashCode() { + return Objects.hash(labels, name); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2beta1UpdateSnapshotPayload {\n"); + sb.append(" labels: ").append(toIndentedString(labels)).append("\n"); + sb.append(" name: ").append(toIndentedString(name)).append("\n"); + sb.append("}"); + return sb.toString(); + } + + /** + * Convert the given object to string with each line indented by 4 spaces (except the first + * line). + */ + private String toIndentedString(Object o) { + if (o == null) { + return "null"; + } + return o.toString().replace("\n", "\n "); + } + + public static HashSet openapiFields; + public static HashSet openapiRequiredFields; + + static { + // a set of all properties/fields (JSON key names) + openapiFields = new HashSet(Arrays.asList("labels", "name")); + + // a set of required properties/fields (JSON key names) + openapiRequiredFields = new HashSet(0); + } + + /** + * Validates the JSON Element and throws an exception if issues found + * + * @param jsonElement JSON Element + * @throws IOException if the JSON Element is invalid with respect to + * V2beta1UpdateSnapshotPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2beta1UpdateSnapshotPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2beta1UpdateSnapshotPayload is not found in the empty JSON string", + V2beta1UpdateSnapshotPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2beta1UpdateSnapshotPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2beta1UpdateSnapshotPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + JsonObject jsonObj = jsonElement.getAsJsonObject(); + if ((jsonObj.get("name") != null && !jsonObj.get("name").isJsonNull()) + && !jsonObj.get("name").isJsonPrimitive()) { + throw new IllegalArgumentException( + String.format( + "Expected the field `name` to be a primitive type in the JSON string but got `%s`", + jsonObj.get("name").toString())); + } + } + + public static class CustomTypeAdapterFactory implements TypeAdapterFactory { + @SuppressWarnings("unchecked") + @Override + public TypeAdapter create(Gson gson, TypeToken type) { + if (!V2beta1UpdateSnapshotPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2beta1UpdateSnapshotPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2beta1UpdateSnapshotPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2beta1UpdateSnapshotPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2beta1UpdateSnapshotPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2beta1UpdateSnapshotPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2beta1UpdateSnapshotPayload + * @throws IOException if the JSON string is invalid with respect to + * V2beta1UpdateSnapshotPayload + */ + public static V2beta1UpdateSnapshotPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2beta1UpdateSnapshotPayload.class); + } + + /** + * Convert an instance of V2beta1UpdateSnapshotPayload to an JSON string + * + * @return JSON string + */ + public String toJson() { + return JSON.getGson().toJson(this); + } +} diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Volume.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Volume.java index 019bda9..d01753b 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Volume.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/Volume.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -257,9 +257,9 @@ public Volume labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachment.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachment.java index 7e36ed7..4df9d83 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachment.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachment.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachmentListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachmentListResponse.java index 5c0a836..d849926 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachmentListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachmentListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeEncryptionParameter.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeEncryptionParameter.java index 55e3854..5cddecf 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeEncryptionParameter.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeEncryptionParameter.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeListResponse.java index 8325f0b..1f96a33 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClass.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClass.java index 4ca998b..0d1496f 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClass.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClass.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -105,9 +105,9 @@ public VolumePerformanceClass labels(@javax.annotation.Nullable Object labels) { /** * Object that represents the labels of an object. Regex for keys: - * `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: - * `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove - * that key. + * `^(?=.{1,63}$)([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9]$`. Regex for values: + * `^(?=.{0,63}$)(([A-Za-z0-9][-A-Za-z0-9_.]*)?[A-Za-z0-9])*$`. Providing a + * `null` value for a key will remove that key. * * @return labels */ diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClassListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClassListResponse.java index 7edf8c3..c72b66b 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClassListResponse.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClassListResponse.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeSource.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeSource.java index 2193609..9c4457a 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeSource.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeSource.java @@ -2,7 +2,7 @@ * IaaS-API * This API allows you to create and modify IaaS resources. * - * The version of the OpenAPI document: 1 + * The version of the OpenAPI document: 2beta1 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).