From 8b3b72c1fef9ad6752d304e069156691c499cb54 Mon Sep 17 00:00:00 2001 From: SDK Generator Bot Date: Wed, 8 Oct 2025 09:40:41 +0000 Subject: [PATCH] Generate iaas --- services/iaas/README.md | 2 +- .../cloud/stackit/sdk/iaas/ApiCallback.java | 2 +- .../cloud/stackit/sdk/iaas/ApiClient.java | 13 +- .../cloud/stackit/sdk/iaas/ApiResponse.java | 2 +- .../sdk/iaas/GzipRequestInterceptor.java | 2 +- .../java/cloud/stackit/sdk/iaas/JSON.java | 238 +- .../java/cloud/stackit/sdk/iaas/Pair.java | 2 +- .../stackit/sdk/iaas/ProgressRequestBody.java | 2 +- .../sdk/iaas/ProgressResponseBody.java | 2 +- .../stackit/sdk/iaas/ServerConfiguration.java | 2 +- .../stackit/sdk/iaas/ServerVariable.java | 2 +- .../cloud/stackit/sdk/iaas/StringUtil.java | 2 +- .../stackit/sdk/iaas/api/DefaultApi.java | 18985 +++++++++++----- .../cloud/stackit/sdk/iaas/api/IaasApi.java | 2 +- .../sdk/iaas/model/AbstractOpenApiSchema.java | 2 +- .../model/AddRoutesToRoutingTablePayload.java | 232 + .../model/AddRoutingTableToAreaPayload.java | 428 + .../iaas/model/AddVolumeToServerPayload.java | 2 +- .../stackit/sdk/iaas/model/AffinityGroup.java | 2 +- .../iaas/model/AffinityGroupListResponse.java | 2 +- .../sdk/iaas/model/AllowedAddressesInner.java | 2 +- .../cloud/stackit/sdk/iaas/model/AreaId.java | 2 +- .../model/AvailabilityZoneListResponse.java | 2 +- .../cloud/stackit/sdk/iaas/model/Backup.java | 2 +- .../sdk/iaas/model/BackupListResponse.java | 2 +- .../stackit/sdk/iaas/model/BackupSource.java | 2 +- .../sdk/iaas/model/BaseSecurityGroupRule.java | 2 +- .../stackit/sdk/iaas/model/BootVolume.java | 2 +- .../sdk/iaas/model/BootVolumeSource.java | 2 +- .../model/CreateAffinityGroupPayload.java | 2 +- .../sdk/iaas/model/CreateBackupPayload.java | 2 +- .../sdk/iaas/model/CreateImagePayload.java | 2 +- .../sdk/iaas/model/CreateKeyPairPayload.java | 2 +- .../model/CreateManagementNetworkPayload.java | 247 + .../CreateManagementNetworkRoutePayload.java | 235 + .../iaas/model/CreateNetworkAreaPayload.java | 44 +- .../model/CreateNetworkAreaRangePayload.java | 2 +- .../model/CreateNetworkAreaRoutePayload.java | 84 +- .../sdk/iaas/model/CreateNetworkIPv4.java | 290 + .../model/CreateNetworkIPv4WithPrefix.java | 304 + .../CreateNetworkIPv4WithPrefixLength.java | 255 + .../sdk/iaas/model/CreateNetworkIPv6.java | 290 + .../model/CreateNetworkIPv6WithPrefix.java | 304 + .../CreateNetworkIPv6WithPrefixLength.java | 255 + .../sdk/iaas/model/CreateNetworkPayload.java | 133 +- .../sdk/iaas/model/CreateNicPayload.java | 2 +- .../sdk/iaas/model/CreateProtocol.java | 2 +- .../sdk/iaas/model/CreatePublicIPPayload.java | 4 +- .../model/CreateSecurityGroupPayload.java | 2 +- .../model/CreateSecurityGroupRulePayload.java | 2 +- .../CreateSecurityGroupRuleProtocol.java | 2 +- .../iaas/model/CreateServerNetworking.java | 2 +- .../model/CreateServerNetworkingWithNics.java | 2 +- .../sdk/iaas/model/CreateServerPayload.java | 24 +- .../CreateServerPayloadAllOfNetworking.java | 294 + .../sdk/iaas/model/CreateVolumePayload.java | 2 +- .../sdk/iaas/model/DestinationCIDRv4.java | 240 + .../sdk/iaas/model/DestinationCIDRv6.java | 240 + .../cloud/stackit/sdk/iaas/model/Error.java | 2 +- .../iaas/model/GetServerLog200Response.java | 2 +- .../sdk/iaas/model/ICMPParameters.java | 2 +- .../cloud/stackit/sdk/iaas/model/Image.java | 2 +- .../stackit/sdk/iaas/model/ImageAgent.java | 2 +- .../stackit/sdk/iaas/model/ImageChecksum.java | 2 +- .../stackit/sdk/iaas/model/ImageConfig.java | 2 +- .../sdk/iaas/model/ImageCreateResponse.java | 2 +- .../sdk/iaas/model/ImageListResponse.java | 2 +- .../stackit/sdk/iaas/model/ImageShare.java | 2 +- .../sdk/iaas/model/ImageShareConsumer.java | 2 +- .../sdk/iaas/model/KeyPairListResponse.java | 2 +- .../cloud/stackit/sdk/iaas/model/Keypair.java | 2 +- .../stackit/sdk/iaas/model/MachineType.java | 2 +- .../iaas/model/MachineTypeListResponse.java | 2 +- .../sdk/iaas/model/ManagementRoute.java | 333 + .../model/ManagementRouteDestination.java | 230 + .../model/ManagementRouteListResponse.java | 229 + .../iaas/model/ManagementRouteNexthop.java | 229 + .../cloud/stackit/sdk/iaas/model/NIC.java | 2 +- .../sdk/iaas/model/NICListResponse.java | 2 +- .../cloud/stackit/sdk/iaas/model/Network.java | 440 +- .../stackit/sdk/iaas/model/NetworkArea.java | 138 +- .../iaas/model/NetworkAreaListResponse.java | 2 +- .../stackit/sdk/iaas/model/NetworkIPv4.java | 342 + .../stackit/sdk/iaas/model/NetworkIPv6.java | 312 + .../sdk/iaas/model/NetworkListResponse.java | 2 +- .../stackit/sdk/iaas/model/NetworkRange.java | 35 +- .../iaas/model/NetworkRangeListResponse.java | 2 +- .../sdk/iaas/model/NexthopBlackhole.java | 207 + .../stackit/sdk/iaas/model/NexthopIPv4.java | 239 + .../stackit/sdk/iaas/model/NexthopIPv6.java | 239 + .../sdk/iaas/model/NexthopInternet.java | 207 + .../PartialUpdateNetworkAreaPayload.java | 42 +- .../model/PartialUpdateNetworkPayload.java | 134 +- .../stackit/sdk/iaas/model/PortRange.java | 2 +- .../cloud/stackit/sdk/iaas/model/Project.java | 127 +- .../sdk/iaas/model/ProjectListResponse.java | 2 +- .../stackit/sdk/iaas/model/Protocol.java | 2 +- .../stackit/sdk/iaas/model/PublicIp.java | 4 +- .../sdk/iaas/model/PublicIpListResponse.java | 2 +- .../stackit/sdk/iaas/model/PublicNetwork.java | 43 +- .../iaas/model/PublicNetworkListResponse.java | 2 +- .../cloud/stackit/sdk/iaas/model/Quota.java | 2 +- .../stackit/sdk/iaas/model/QuotaList.java | 2 +- .../sdk/iaas/model/QuotaListResponse.java | 2 +- .../stackit/sdk/iaas/model/RegionalArea.java | 222 + .../sdk/iaas/model/RegionalAreaIPv4.java | 407 + .../iaas/model/RegionalAreaListResponse.java | 212 + .../cloud/stackit/sdk/iaas/model/Request.java | 2 +- .../sdk/iaas/model/RequestResource.java | 2 +- .../sdk/iaas/model/RescueServerPayload.java | 2 +- .../sdk/iaas/model/ResizeServerPayload.java | 2 +- .../sdk/iaas/model/ResizeVolumePayload.java | 2 +- .../cloud/stackit/sdk/iaas/model/Route.java | 134 +- .../sdk/iaas/model/RouteDestination.java | 280 + .../sdk/iaas/model/RouteListResponse.java | 2 +- .../stackit/sdk/iaas/model/RouteNexthop.java | 388 + .../stackit/sdk/iaas/model/RoutingTable.java | 420 + .../iaas/model/RoutingTableListResponse.java | 227 + .../stackit/sdk/iaas/model/SecurityGroup.java | 2 +- .../iaas/model/SecurityGroupListResponse.java | 2 +- .../sdk/iaas/model/SecurityGroupRule.java | 2 +- .../model/SecurityGroupRuleListResponse.java | 2 +- .../iaas/model/SecurityGroupRuleProtocol.java | 2 +- .../cloud/stackit/sdk/iaas/model/Server.java | 12 +- .../stackit/sdk/iaas/model/ServerAgent.java | 2 +- .../sdk/iaas/model/ServerConsoleUrl.java | 2 +- .../sdk/iaas/model/ServerListResponse.java | 2 +- .../sdk/iaas/model/ServerMaintenance.java | 2 +- .../stackit/sdk/iaas/model/ServerNetwork.java | 2 +- .../sdk/iaas/model/ServerNetworking.java | 287 + .../model/ServiceAccountMailListResponse.java | 2 +- .../sdk/iaas/model/SetImageSharePayload.java | 2 +- .../stackit/sdk/iaas/model/Snapshot.java | 2 +- .../sdk/iaas/model/SnapshotListResponse.java | 2 +- .../stackit/sdk/iaas/model/StaticAreaID.java | 2 +- .../model/UpdateAttachedVolumePayload.java | 2 +- .../sdk/iaas/model/UpdateImagePayload.java | 2 +- .../iaas/model/UpdateImageSharePayload.java | 2 +- .../sdk/iaas/model/UpdateKeyPairPayload.java | 2 +- .../UpdateManagementNetworkRoutePayload.java | 200 + .../sdk/iaas/model/UpdateNetworkIPv4Body.java | 6 +- .../sdk/iaas/model/UpdateNetworkIPv6Body.java | 6 +- .../sdk/iaas/model/UpdateNicPayload.java | 2 +- .../sdk/iaas/model/UpdatePublicIPPayload.java | 4 +- .../iaas/model/UpdateRegionalAreaIPv4.java | 295 + .../UpdateRouteOfRoutingTablePayload.java | 198 + .../UpdateRoutingTableOfAreaPayload.java | 292 + .../sdk/iaas/model/UpdateServerPayload.java | 2 +- .../sdk/iaas/model/UpdateVolumePayload.java | 2 +- .../V2ConfigureNetworkAreaRegionPayload.java | 232 + .../iaas/model/V2CreateSnapshotPayload.java | 386 + .../sdk/iaas/model/V2UpdateBackupPayload.java | 433 + .../V2UpdateNetworkAreaRegionPayload.java | 200 + .../model/V2UpdateRouteOfAreaPayload.java | 193 + .../model/V2UpdateSecurityGroupPayload.java | 261 + .../iaas/model/V2UpdateSnapshotPayload.java | 225 + .../cloud/stackit/sdk/iaas/model/Volume.java | 2 +- .../sdk/iaas/model/VolumeAttachment.java | 2 +- .../model/VolumeAttachmentListResponse.java | 2 +- .../iaas/model/VolumeEncryptionParameter.java | 2 +- .../sdk/iaas/model/VolumeListResponse.java | 2 +- .../iaas/model/VolumePerformanceClass.java | 2 +- .../VolumePerformanceClassListResponse.java | 2 +- .../stackit/sdk/iaas/model/VolumeSource.java | 2 +- .../stackit/sdk/iaas/api/DefaultApiTest.java | 2 +- .../stackit/sdk/iaas/api/IaasApiTest.java | 2 +- 166 files changed, 25314 insertions(+), 7081 deletions(-) create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutesToRoutingTablePayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutingTableToAreaPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkRoutePayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4WithPrefix.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv4WithPrefixLength.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6WithPrefix.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateNetworkIPv6WithPrefixLength.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateServerPayloadAllOfNetworking.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv4.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv6.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRoute.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteDestination.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteListResponse.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ManagementRouteNexthop.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkIPv4.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NetworkIPv6.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopBlackhole.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopIPv4.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopIPv6.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NexthopInternet.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalArea.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalAreaIPv4.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RegionalAreaListResponse.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteDestination.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RouteNexthop.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTable.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTableListResponse.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerNetworking.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateManagementNetworkRoutePayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRegionalAreaIPv4.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRouteOfRoutingTablePayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRoutingTableOfAreaPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2ConfigureNetworkAreaRegionPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2CreateSnapshotPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateBackupPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateNetworkAreaRegionPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateRouteOfAreaPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateSecurityGroupPayload.java create mode 100644 services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateSnapshotPayload.java diff --git a/services/iaas/README.md b/services/iaas/README.md index 2c1410b..64d56a7 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: 2 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..b48b19b 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: 2 * 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 a724f2b..dda3d06 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: 2 * 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; @@ -190,7 +189,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..64c848f 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: 2 * 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..06cf4f2 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: 2 * 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 5d780a5..12916a7 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: 2 * 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.CreateNetworkIPv6Body.CustomTypeAdapterFactory()); + 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.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( @@ -309,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()); @@ -318,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( @@ -336,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()); @@ -350,14 +495,37 @@ 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.V2ConfigureNetworkAreaRegionPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2CreateSnapshotPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2UpdateBackupPayload.CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2UpdateNetworkAreaRegionPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2UpdateRouteOfAreaPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2UpdateSecurityGroupPayload + .CustomTypeAdapterFactory()); + gsonBuilder.registerTypeAdapterFactory( + new cloud.stackit.sdk.iaas.model.V2UpdateSnapshotPayload + .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..7435ca1 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: 2 * 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..48c428e 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: 2 * 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..7bdf7f1 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: 2 * 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..c7cc866 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: 2 * 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..78825b6 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: 2 * 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..e6ce284 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: 2 * 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 44de926..3c7b7fb 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: 2 * 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.V2ConfigureNetworkAreaRegionPayload; +import cloud.stackit.sdk.iaas.model.V2CreateSnapshotPayload; +import cloud.stackit.sdk.iaas.model.V2UpdateBackupPayload; +import cloud.stackit.sdk.iaas.model.V2UpdateNetworkAreaRegionPayload; +import cloud.stackit.sdk.iaas.model.V2UpdateRouteOfAreaPayload; +import cloud.stackit.sdk.iaas.model.V2UpdateSecurityGroupPayload; +import cloud.stackit.sdk.iaas.model.V2UpdateSnapshotPayload; import cloud.stackit.sdk.iaas.model.Volume; import cloud.stackit.sdk.iaas.model.VolumeAttachment; import cloud.stackit.sdk.iaas.model.VolumeAttachmentListResponse; @@ -191,6 +206,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 @@ -210,6 +226,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) @@ -231,10 +248,13 @@ public okhttp3.Call addNetworkToServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/networks/{networkId}" + "/v2/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())) @@ -279,6 +299,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) @@ -289,6 +310,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( @@ -301,7 +328,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); } /** @@ -309,6 +336,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 @@ -327,10 +355,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); } /** @@ -338,6 +367,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> @@ -357,11 +387,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); } @@ -370,6 +401,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 @@ -390,13 +422,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; } @@ -405,6 +439,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 @@ -425,6 +460,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) @@ -446,10 +482,13 @@ public okhttp3.Call addNicToServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/nics/{nicId}" + "/v2/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())) @@ -494,6 +533,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) @@ -504,6 +544,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( @@ -516,13 +562,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 @@ -542,16 +589,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> @@ -572,11 +621,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); } @@ -585,6 +635,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 @@ -606,13 +657,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; } @@ -621,6 +673,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 @@ -641,6 +694,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) @@ -662,10 +716,13 @@ public okhttp3.Call addPublicIpToServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/public-ips/{publicIpId}" + "/v2/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())) @@ -710,6 +767,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) @@ -720,6 +778,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( @@ -732,13 +796,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 @@ -758,16 +823,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> @@ -788,11 +855,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); } @@ -800,6 +869,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 @@ -821,23 +891,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 @@ -845,7 +920,7 @@ public okhttp3.Call addPublicIpToServerAsync( * * * - * + * * * * @@ -854,10 +929,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; @@ -873,20 +950,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}" + "/v2/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(); @@ -900,7 +980,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) { @@ -911,7 +991,7 @@ public okhttp3.Call addSecurityGroupToServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PUT", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -923,46 +1003,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 * * * - * + * * * * @@ -971,28 +1075,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 * * * - * + * * * * @@ -1001,24 +1117,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 @@ -1027,7 +1154,7 @@ public ApiResponse addSecurityGroupToServerWithHttpInfo( * * * - * + * * * * @@ -1036,26 +1163,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 @@ -1063,7 +1200,7 @@ public okhttp3.Call addSecurityGroupToServerAsync( * * * - * + * * * * @@ -1072,10 +1209,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; @@ -1091,20 +1229,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}" + "/v2/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(); @@ -1118,7 +1256,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) { @@ -1129,7 +1267,7 @@ public okhttp3.Call addServiceAccountToServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PUT", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -1141,47 +1279,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 * * * - * + * * * * @@ -1190,30 +1339,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 * * * - * + * * * * @@ -1222,25 +1376,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 @@ -1249,7 +1406,7 @@ public ApiResponse addServiceAccountToServerWith * * * - * + * * * * @@ -1258,28 +1415,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 @@ -1287,7 +1445,7 @@ public okhttp3.Call addServiceAccountToServerAsync( * * * - * + * * * * @@ -1296,11 +1454,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; @@ -1316,20 +1474,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}" + "/v2/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(); @@ -1343,7 +1504,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) { @@ -1366,50 +1527,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 * * * - * + * * * * @@ -1418,33 +1584,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 * * * - * + * * * * @@ -1453,27 +1616,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 @@ -1482,7 +1644,7 @@ public ApiResponse addVolumeToServerWithHttpInfo( * * * - * + * * * * @@ -1491,27 +1653,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 @@ -1519,17 +1682,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; @@ -1545,14 +1711,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" + "/v2/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(); @@ -1566,7 +1741,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) { @@ -1577,7 +1752,7 @@ public okhttp3.Call createAffinityGroupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -1589,93 +1764,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 @@ -1684,33 +1886,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 @@ -1718,17 +1926,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; @@ -1744,14 +1956,23 @@ public okhttp3.Call createBackupCall( basePath = null; } - Object localVarPostBody = createBackupPayload; + Object localVarPostBody = addVolumeToServerPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups" + "/v2/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(); @@ -1776,7 +1997,7 @@ public okhttp3.Call createBackupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -1788,92 +2009,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 @@ -1882,32 +2137,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 @@ -1915,18 +2176,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; @@ -1942,14 +2203,17 @@ public okhttp3.Call createImageCall( basePath = null; } - Object localVarPostBody = createImagePayload; + Object localVarPostBody = createAffinityGroupPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images" + "/v2/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(); @@ -1986,95 +2250,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 @@ -2083,32 +2358,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 @@ -2116,17 +2394,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; @@ -2142,10 +2421,17 @@ public okhttp3.Call createKeyPairCall( basePath = null; } - Object localVarPostBody = createKeyPairPayload; + Object localVarPostBody = createBackupPayload; // create path and map variables - String localVarPath = "/v1/keypairs"; + String localVarPath = + "/v2/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(); @@ -2182,91 +2468,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 @@ -2275,32 +2575,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 @@ -2308,18 +2610,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; @@ -2335,14 +2638,17 @@ public okhttp3.Call createNetworkCall( basePath = null; } - Object localVarPostBody = createNetworkPayload; + Object localVarPostBody = createImagePayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks" + "/v2/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(); @@ -2379,101 +2685,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 @@ -2482,33 +2794,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 @@ -2516,17 +2828,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; @@ -2542,14 +2854,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 = "/v2/keypairs"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -2586,91 +2894,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 @@ -2679,35 +2986,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 @@ -2715,19 +3020,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; @@ -2743,17 +3047,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" + "/v2/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(); @@ -2790,113 +3094,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 @@ -2905,36 +3204,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 @@ -2942,7 +3241,7 @@ public okhttp3.Call createNetworkAreaRangeAsync( * * * - * + * * * * @@ -2951,10 +3250,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; @@ -2970,17 +3270,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" + "/v2/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(); @@ -3017,48 +3317,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 * * * - * + * * * * @@ -3067,31 +3370,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 * * * - * + * * * * @@ -3100,25 +3406,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 @@ -3127,7 +3435,7 @@ public ApiResponse createNetworkAreaRouteWithHttpInfo( * * * - * + * * * * @@ -3136,27 +3444,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 @@ -3164,20 +3473,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; @@ -3193,17 +3501,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" + "/v2/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(); @@ -3240,106 +3548,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 @@ -3348,35 +3663,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 @@ -3384,18 +3698,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; @@ -3411,14 +3724,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" + "/v2/organizations/{organizationId}/network-areas" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -3455,92 +3768,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 @@ -3549,33 +3861,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 @@ -3583,17 +3898,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; @@ -3609,14 +3927,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" + "/v2/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(); @@ -3653,90 +3977,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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 = + "/v2/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 @@ -3745,7 +8267,7 @@ public ApiResponse createSecurityGroupWithHttpInfo( * * * - * + * * * * @@ -3753,26 +8275,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 @@ -3780,7 +8304,7 @@ public okhttp3.Call createSecurityGroupAsync( * * * - * + * * * * @@ -3788,10 +8312,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; @@ -3807,17 +8332,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" + "/v2/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(); @@ -3831,7 +8362,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) { @@ -3842,7 +8373,7 @@ public okhttp3.Call createSecurityGroupRuleCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -3854,48 +8385,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 * * * - * + * * * * @@ -3903,31 +8440,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 * * * - * + * * * * @@ -3935,25 +8471,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 @@ -3962,7 +8498,7 @@ public ApiResponse createSecurityGroupRuleWithHttpInfo( * * * - * + * * * * @@ -3970,26 +8506,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 @@ -3997,7 +8533,7 @@ public okhttp3.Call createSecurityGroupRuleAsync( * * * - * + * * * * @@ -4005,9 +8541,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; @@ -4023,14 +8560,20 @@ public okhttp3.Call createServerCall( basePath = null; } - Object localVarPostBody = createServerPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers" + "/v2/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(); @@ -4044,7 +8587,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) { @@ -4055,7 +8598,7 @@ public okhttp3.Call createServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -4067,39 +8610,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 * * * - * + * * * * @@ -4107,27 +8657,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 * * * - * + * * * * @@ -4135,21 +8686,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 @@ -4158,7 +8710,7 @@ public ApiResponse createServerWithHttpInfo( * * * - * + * * * * @@ -4166,24 +8718,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 @@ -4191,7 +8746,7 @@ public okhttp3.Call createServerAsync( * * * - * + * * * * @@ -4199,9 +8754,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; @@ -4217,14 +8775,26 @@ public okhttp3.Call createSnapshotCall( basePath = null; } - Object localVarPostBody = createSnapshotPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots" + "/v2/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(); @@ -4238,7 +8808,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) { @@ -4249,7 +8819,7 @@ public okhttp3.Call createSnapshotCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -4261,39 +8831,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 * * * - * + * * * * @@ -4301,28 +8895,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 * * * - * + * * * * @@ -4330,21 +8929,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 @@ -4353,7 +8959,7 @@ public ApiResponse createSnapshotWithHttpInfo( * * * - * + * * * * @@ -4361,24 +8967,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 @@ -4386,7 +8997,7 @@ public okhttp3.Call createSnapshotAsync( * * * - * + * * * * @@ -4394,9 +9005,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; @@ -4412,14 +9025,23 @@ public okhttp3.Call createVolumeCall( basePath = null; } - Object localVarPostBody = createVolumePayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes" + "/v2/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(); @@ -4433,7 +9055,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) { @@ -4444,7 +9066,7 @@ public okhttp3.Call createVolumeCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -4456,41 +9078,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 * * * - * + * * * * @@ -4498,29 +9134,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 * * * - * + * * * * @@ -4528,23 +9165,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 @@ -4553,7 +9192,7 @@ public ApiResponse createVolumeWithHttpInfo( * * * - * + * * * * @@ -4561,24 +9200,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 @@ -4586,7 +9228,7 @@ public okhttp3.Call createVolumeAsync( * * * - * + * * * * @@ -4595,9 +9237,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; @@ -4617,13 +9260,16 @@ public okhttp3.Call deallocateServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/deallocate" + "/v2/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(); @@ -4648,7 +9294,7 @@ public okhttp3.Call deallocateServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -4660,39 +9306,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 * * * - * + * * * * @@ -4701,18 +9354,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 @@ -4720,7 +9375,7 @@ public void deallocateServer( * * * - * + * * * * @@ -4729,19 +9384,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 @@ -4750,7 +9408,7 @@ public ApiResponse deallocateServerWithHttpInfo( * * * - * + * * * * @@ -4759,23 +9417,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 @@ -4783,7 +9445,7 @@ public okhttp3.Call deallocateServerAsync( * * * - * + * * * * @@ -4791,9 +9453,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; @@ -4813,13 +9477,19 @@ public okhttp3.Call deleteAffinityGroupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/affinity-groups/{affinityGroupId}" + "/v2/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(); @@ -4856,38 +9526,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 * * * - * + * * * * @@ -4895,18 +9582,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 @@ -4914,7 +9606,7 @@ public void deleteAffinityGroup( * * * - * + * * * * @@ -4922,21 +9614,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 @@ -4945,7 +9641,7 @@ public ApiResponse deleteAffinityGroupWithHttpInfo( * * * - * + * * * * @@ -4953,24 +9649,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 @@ -4978,7 +9677,7 @@ public okhttp3.Call deleteAffinityGroupAsync( * * * - * + * * * * @@ -4986,10 +9685,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; @@ -5009,13 +9708,16 @@ public okhttp3.Call deleteBackupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups/{backupId}" + "/v2/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(); @@ -5023,10 +9725,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) { @@ -5056,40 +9754,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 * * * - * + * * * * @@ -5097,20 +9801,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 @@ -5118,7 +9822,7 @@ public void deleteBackup( * * * - * + * * * * @@ -5126,22 +9830,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 @@ -5150,7 +9854,7 @@ public ApiResponse deleteBackupWithHttpInfo( * * * - * + * * * * @@ -5158,24 +9862,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 @@ -5183,17 +9888,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; @@ -5213,13 +9920,16 @@ public okhttp3.Call deleteImageCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}" + "/v2/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(); @@ -5256,56 +9966,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 @@ -5313,26 +10037,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 @@ -5341,30 +10071,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 @@ -5372,7 +10106,7 @@ public okhttp3.Call deleteImageAsync( * * * - * + * * * * @@ -5380,9 +10114,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; @@ -5402,13 +10137,16 @@ public okhttp3.Call deleteImageShareCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share" + "/v2/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(); @@ -5433,7 +10171,7 @@ public okhttp3.Call deleteImageShareCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -5445,38 +10183,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 * * * - * + * * * * @@ -5484,25 +10231,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 * * * - * + * * * * @@ -5510,18 +10262,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 @@ -5530,7 +10287,7 @@ public ApiResponse deleteImageShareWithHttpInfo( * * * - * + * * * * @@ -5538,25 +10295,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 @@ -5564,7 +10323,7 @@ public okhttp3.Call deleteImageShareAsync( * * * - * + * * * * @@ -5572,10 +10331,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; @@ -5595,16 +10355,19 @@ public okhttp3.Call deleteImageShareConsumerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share/{consumerProjectId}" + "/v2/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(); @@ -5629,7 +10392,7 @@ public okhttp3.Call deleteImageShareConsumerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -5641,47 +10404,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 * * * - * + * * * * @@ -5689,29 +10460,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 * * * - * + * * * * @@ -5719,24 +10493,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 @@ -5745,7 +10521,7 @@ public ApiResponse deleteImageShareConsumerWithHttpInfo( * * * - * + * * * * @@ -5753,24 +10529,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 @@ -5778,7 +10558,7 @@ public okhttp3.Call deleteImageShareConsumerAsync( * * * - * + * * * * @@ -5786,8 +10566,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 @@ -5806,10 +10589,16 @@ public okhttp3.Call deleteKeyPairCall( // create path and map variables String localVarPath = - "/v1/keypairs/{keypairName}" + "/v2/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(); @@ -5834,7 +10623,7 @@ public okhttp3.Call deleteKeyPairCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -5846,29 +10635,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 * * * - * + * * * * @@ -5876,22 +10683,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 * * * - * + * * * * @@ -5899,16 +10713,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 @@ -5917,7 +10737,7 @@ public ApiResponse deleteKeyPairWithHttpInfo(@javax.annotation.Nonnull Str * * * - * + * * * * @@ -5925,20 +10745,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 @@ -5946,18 +10772,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; @@ -5977,13 +10803,16 @@ public okhttp3.Call deleteNetworkCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}" + "/v2/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(); @@ -6008,7 +10837,7 @@ public okhttp3.Call deleteNetworkCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6020,86 +10849,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 @@ -6108,32 +10952,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 @@ -6141,18 +10987,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; @@ -6172,13 +11018,16 @@ public okhttp3.Call deleteNetworkAreaCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}" + "/v2/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(); @@ -6203,7 +11052,7 @@ public okhttp3.Call deleteNetworkAreaCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6215,89 +11064,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 @@ -6306,33 +11168,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 @@ -6340,19 +11205,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; @@ -6372,16 +11237,19 @@ public okhttp3.Call deleteNetworkAreaRangeCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/network-ranges/{networkRangeId}" + "/v2/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(); @@ -6406,7 +11274,7 @@ public okhttp3.Call deleteNetworkAreaRangeCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6418,104 +11286,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 @@ -6524,35 +11406,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 @@ -6560,7 +11441,7 @@ public okhttp3.Call deleteNetworkAreaRangeAsync( * * * - * + * * * * @@ -6568,11 +11449,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 @@ -6591,16 +11469,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())) + "/v2/keypairs/{keypairName}" .replace( - "{" + "routeId" + "}", - localVarApiClient.escapeString(routeId.toString())); + "{" + "keypairName" + "}", + localVarApiClient.escapeString(keypairName.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -6625,7 +11497,7 @@ public okhttp3.Call deleteNetworkAreaRouteCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6637,46 +11509,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 * * * - * + * * * * @@ -6684,28 +11540,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 * * * - * + * * * * @@ -6713,22 +11564,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 @@ -6737,7 +11583,7 @@ public ApiResponse deleteNetworkAreaRouteWithHttpInfo( * * * - * + * * * * @@ -6745,26 +11591,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 @@ -6772,7 +11614,7 @@ public okhttp3.Call deleteNetworkAreaRouteAsync( * * * - * + * * * * @@ -6780,10 +11622,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; @@ -6803,16 +11645,16 @@ public okhttp3.Call deleteNicCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}/nics/{nicId}" + "/v2/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(); @@ -6837,7 +11679,7 @@ public okhttp3.Call deleteNicCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -6849,46 +11691,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 * * * - * + * * * * @@ -6896,28 +11739,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 * * * - * + * * * * @@ -6925,22 +11770,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 @@ -6949,7 +11795,7 @@ public ApiResponse deleteNicWithHttpInfo( * * * - * + * * * * @@ -6957,24 +11803,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 @@ -6982,7 +11830,7 @@ public okhttp3.Call deleteNicAsync( * * * - * + * * * * @@ -6990,9 +11838,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; @@ -7012,13 +11861,16 @@ public okhttp3.Call deletePublicIPCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/public-ips/{publicIpId}" + "/v2/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(); @@ -7043,7 +11895,7 @@ public okhttp3.Call deletePublicIPCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7055,38 +11907,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 * * * - * + * * * * @@ -7094,25 +11955,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 * * * - * + * * * * @@ -7120,18 +11986,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 @@ -7140,7 +12012,7 @@ public ApiResponse deletePublicIPWithHttpInfo( * * * - * + * * * * @@ -7148,23 +12020,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 @@ -7172,18 +12047,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; @@ -7203,13 +12078,16 @@ public okhttp3.Call deleteSecurityGroupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}" + "/v2/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(); @@ -7234,7 +12112,7 @@ public okhttp3.Call deleteSecurityGroupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7246,88 +12124,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 @@ -7336,33 +12227,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 @@ -7370,7 +12261,7 @@ public okhttp3.Call deleteSecurityGroupAsync( * * * - * + * * * * @@ -7378,10 +12269,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; @@ -7401,16 +12291,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())) + "/v2/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(); @@ -7435,7 +12322,7 @@ public okhttp3.Call deleteSecurityGroupRuleCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7447,47 +12334,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 * * * - * + * * * * @@ -7495,28 +12374,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 * * * - * + * * * * @@ -7524,23 +12401,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 @@ -7549,7 +12423,7 @@ public ApiResponse deleteSecurityGroupRuleWithHttpInfo( * * * - * + * * * * @@ -7557,25 +12431,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 @@ -7583,7 +12458,7 @@ public okhttp3.Call deleteSecurityGroupRuleAsync( * * * - * + * * * * @@ -7591,9 +12466,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; @@ -7613,13 +12490,19 @@ public okhttp3.Call deleteServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}" + "/v2/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(); @@ -7644,7 +12527,7 @@ public okhttp3.Call deleteServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7656,38 +12539,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 * * * - * + * * * * @@ -7695,25 +12595,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 * * * - * + * * * * @@ -7721,18 +12628,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 @@ -7741,7 +12657,7 @@ public ApiResponse deleteServerWithHttpInfo( * * * - * + * * * * @@ -7749,22 +12665,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 @@ -7772,7 +12695,7 @@ public okhttp3.Call deleteServerAsync( * * * - * + * * * * @@ -7780,9 +12703,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; @@ -7802,13 +12727,19 @@ public okhttp3.Call deleteSnapshotCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots/{snapshotId}" + "/v2/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(); @@ -7833,7 +12764,7 @@ public okhttp3.Call deleteSnapshotCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -7845,38 +12776,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 * * * - * + * * * * @@ -7884,25 +12833,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 * * * - * + * * * * @@ -7910,18 +12867,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 @@ -7930,7 +12896,7 @@ public ApiResponse deleteSnapshotWithHttpInfo( * * * - * + * * * * @@ -7938,23 +12904,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 @@ -7962,18 +12934,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; @@ -7993,13 +12966,19 @@ public okhttp3.Call deleteVolumeCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes/{volumeId}" + "/v2/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(); @@ -8024,7 +13003,7 @@ public okhttp3.Call deleteVolumeCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -8036,88 +13015,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 @@ -8126,31 +13133,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 @@ -8158,7 +13168,7 @@ public okhttp3.Call deleteVolumeAsync( * * * - * + * * * * @@ -8166,9 +13176,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; @@ -8188,13 +13198,13 @@ public okhttp3.Call getAffinityGroupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/affinity-groups/{affinityGroupId}" + "/v2/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(); @@ -8231,39 +13241,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 * * * - * + * * * * @@ -8271,28 +13282,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 * * * - * + * * * * @@ -8300,21 +13312,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 @@ -8323,7 +13337,7 @@ public ApiResponse getAffinityGroupWithHttpInfo( * * * - * + * * * * @@ -8331,25 +13345,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 @@ -8357,7 +13369,7 @@ public okhttp3.Call getAffinityGroupAsync( * * * - * + * * * * @@ -8365,11 +13377,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 @@ -8388,16 +13397,10 @@ public okhttp3.Call getAttachedVolumeCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/volume-attachments/{volumeId}" + "/v2/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(); @@ -8434,47 +13437,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 * * * - * + * * * * @@ -8482,30 +13468,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 * * * - * + * * * * @@ -8513,24 +13492,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 @@ -8539,7 +13511,7 @@ public ApiResponse getAttachedVolumeWithHttpInfo( * * * - * + * * * * @@ -8547,25 +13519,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 @@ -8573,7 +13542,7 @@ public okhttp3.Call getAttachedVolumeAsync( * * * - * + * * * * @@ -8581,9 +13550,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; @@ -8603,13 +13573,16 @@ public okhttp3.Call getBackupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups/{backupId}" + "/v2/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(); @@ -8646,39 +13619,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 * * * - * + * * * * @@ -8686,26 +13668,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 * * * - * + * * * * @@ -8713,19 +13699,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 @@ -8734,7 +13724,7 @@ public ApiResponse getBackupWithHttpInfo( * * * - * + * * * * @@ -8742,23 +13732,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 @@ -8766,7 +13759,7 @@ public okhttp3.Call getBackupAsync( * * * - * + * * * * @@ -8774,9 +13767,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; @@ -8796,13 +13790,16 @@ public okhttp3.Call getImageCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}" + "/v2/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(); @@ -8839,39 +13836,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 * * * - * + * * * * @@ -8879,26 +13885,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 * * * - * + * * * * @@ -8906,20 +13917,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 @@ -8928,7 +13943,7 @@ public ApiResponse getImageWithHttpInfo( * * * - * + * * * * @@ -8936,23 +13951,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 @@ -8960,7 +13978,7 @@ public okhttp3.Call getImageAsync( * * * - * + * * * * @@ -8968,9 +13986,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; @@ -8990,13 +14009,16 @@ public okhttp3.Call getImageShareCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share" + "/v2/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(); @@ -9033,39 +14055,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 * * * - * + * * * * @@ -9073,26 +14103,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 * * * - * + * * * * @@ -9100,19 +14133,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 @@ -9121,7 +14159,7 @@ public ApiResponse getImageShareWithHttpInfo( * * * - * + * * * * @@ -9129,25 +14167,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 @@ -9155,7 +14196,7 @@ public okhttp3.Call getImageShareAsync( * * * - * + * * * * @@ -9163,10 +14204,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; @@ -9186,16 +14229,22 @@ public okhttp3.Call getImageShareConsumerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/share/{consumerProjectId}" + "/v2/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(); @@ -9232,48 +14281,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 * * * - * + * * * * @@ -9281,31 +14347,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 * * * - * + * * * * @@ -9313,25 +14384,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 @@ -9340,7 +14415,7 @@ public ApiResponse getImageShareConsumerWithHttpInfo( * * * - * + * * * * @@ -9348,25 +14423,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 @@ -9374,7 +14454,7 @@ public okhttp3.Call getImageShareConsumerAsync( * * * - * + * * * * @@ -9382,8 +14462,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 @@ -9402,10 +14486,19 @@ public okhttp3.Call getKeyPairCall( // create path and map variables String localVarPath = - "/v1/keypairs/{keypairName}" + "/v2/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(); @@ -9442,30 +14535,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 * * * - * + * * * * @@ -9473,23 +14592,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 * * * - * + * * * * @@ -9497,17 +14626,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 @@ -9516,7 +14655,7 @@ public ApiResponse getKeyPairWithHttpInfo(@javax.annotation.Nonnull Str * * * - * + * * * * @@ -9524,21 +14663,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 @@ -9546,7 +14692,7 @@ public okhttp3.Call getKeyPairAsync( * * * - * + * * * * @@ -9554,9 +14700,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; @@ -9576,13 +14723,16 @@ public okhttp3.Call getMachineTypeCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/machine-types/{machineType}" + "/v2/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(); @@ -9619,39 +14769,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 * * * - * + * * * * @@ -9659,26 +14817,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 * * * - * + * * * * @@ -9686,19 +14848,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 @@ -9707,7 +14873,7 @@ public ApiResponse getMachineTypeWithHttpInfo( * * * - * + * * * * @@ -9715,24 +14881,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 @@ -9740,7 +14909,7 @@ public okhttp3.Call getMachineTypeAsync( * * * - * + * * * * @@ -9748,9 +14917,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; @@ -9770,13 +14941,19 @@ public okhttp3.Call getNetworkCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}" + "/v2/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(); @@ -9813,39 +14990,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 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 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 * * * - * + * * * * @@ -9853,26 +15047,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 * * * - * + * * * * @@ -9880,19 +15081,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 @@ -9901,7 +15110,7 @@ public ApiResponse getNetworkWithHttpInfo( * * * - * + * * * * @@ -9909,23 +15118,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 @@ -9933,7 +15148,7 @@ public okhttp3.Call getNetworkAsync( * * * - * + * * * * @@ -9941,9 +15156,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; @@ -9963,13 +15180,16 @@ public okhttp3.Call getNetworkAreaCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}" + "/v2/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(); @@ -9977,6 +15197,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) { @@ -10006,39 +15230,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 * * * - * + * * * * @@ -10046,26 +15280,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 * * * - * + * * * * @@ -10073,20 +15313,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 @@ -10095,7 +15340,7 @@ public ApiResponse getNetworkAreaWithHttpInfo( * * * - * + * * * * @@ -10103,25 +15348,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 @@ -10129,7 +15376,7 @@ public okhttp3.Call getNetworkAreaAsync( * * * - * + * * * * @@ -10137,10 +15384,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; @@ -10160,16 +15407,16 @@ public okhttp3.Call getNetworkAreaRangeCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/network-ranges/{networkRangeId}" + "/v2/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(); @@ -10206,47 +15453,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 * * * - * + * * * * @@ -10254,30 +15501,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 * * * - * + * * * * @@ -10285,24 +15532,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. - * - * @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) + * Get server console. (asynchronously) Get a URL for server remote console. + * + * @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 @@ -10311,7 +15557,7 @@ public ApiResponse getNetworkAreaRangeWithHttpInfo( * * * - * + * * * * @@ -10319,27 +15565,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 @@ -10347,7 +15594,7 @@ public okhttp3.Call getNetworkAreaRangeAsync( * * * - * + * * * * @@ -10355,10 +15602,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; @@ -10378,16 +15626,16 @@ public okhttp3.Call getNetworkAreaRouteCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/routes/{routeId}" + "/v2/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(); @@ -10395,6 +15643,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) { @@ -10424,48 +15676,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 * * * - * + * * * * @@ -10473,31 +15727,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 * * * - * + * * * * @@ -10505,24 +15761,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 @@ -10531,7 +15789,7 @@ public ApiResponse getNetworkAreaRouteWithHttpInfo( * * * - * + * * * * @@ -10539,26 +15797,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 @@ -10566,7 +15825,7 @@ public okhttp3.Call getNetworkAreaRouteAsync( * * * - * + * * * * @@ -10574,10 +15833,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; @@ -10597,16 +15856,16 @@ public okhttp3.Call getNicCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}/nics/{nicId}" + "/v2/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(); @@ -10643,48 +15902,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 * * * - * + * * * * @@ -10692,30 +15950,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 * * * - * + * * * * @@ -10723,23 +15980,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 @@ -10748,7 +16004,7 @@ public ApiResponse getNicWithHttpInfo( * * * - * + * * * * @@ -10756,25 +16012,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 @@ -10782,7 +16039,7 @@ public okhttp3.Call getNicAsync( * * * - * + * * * * @@ -10790,9 +16047,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; @@ -10812,13 +16070,16 @@ public okhttp3.Call getOrganizationRequestCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/requests/{requestId}" + "/v2/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(); @@ -10855,40 +16116,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 'organizationId' when calling getOrganizationRequest(Async)"); + "Missing the required parameter 'projectId' when calling getVolumePerformanceClass(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 getOrganizationRequest(Async)"); + "Missing the required parameter 'region' when calling getVolumePerformanceClass(Async)"); } - return getOrganizationRequestCall(organizationId, requestId, _callback); + // verify the required parameter 'volumePerformanceClass' is set + if (volumePerformanceClass == null) { + throw new ApiException( + "Missing the required parameter 'volumePerformanceClass' when calling getVolumePerformanceClass(Async)"); + } + + 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 * * * - * + * * * * @@ -10896,29 +16165,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 * * * - * + * * * * @@ -10926,23 +16197,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 @@ -10951,7 +16224,7 @@ public ApiResponse getOrganizationRequestWithHttpInfo( * * * - * + * * * * @@ -10959,23 +16232,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 @@ -10983,16 +16259,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 @@ -11011,10 +16290,13 @@ public okhttp3.Call getProjectDetailsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}" + "/v2/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(); @@ -11051,72 +16333,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 @@ -11125,29 +16433,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 @@ -11155,7 +16468,7 @@ public okhttp3.Call getProjectDetailsAsync( * * * - * + * * * * @@ -11163,9 +16476,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; @@ -11185,13 +16499,16 @@ public okhttp3.Call getProjectNICCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/nics/{nicId}" + "/v2/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(); @@ -11228,40 +16545,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 * * * - * + * * * * @@ -11269,27 +16593,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 * * * - * + * * * * @@ -11297,20 +16624,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 @@ -11319,7 +16650,7 @@ public ApiResponse getProjectNICWithHttpInfo( * * * - * + * * * * @@ -11327,23 +16658,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 @@ -11351,7 +16683,7 @@ public okhttp3.Call getProjectNICAsync( * * * - * + * * * * @@ -11359,10 +16691,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 @@ -11381,13 +16711,10 @@ public okhttp3.Call getProjectRequestCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/requests/{requestId}" + "/v2/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(); @@ -11419,45 +16746,35 @@ public okhttp3.Call getProjectRequestCall( localVarHeaderParams, localVarCookieParams, localVarFormParams, - localVarAuthNames, - _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getProjectRequestValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @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 getProjectRequest(Async)"); - } + localVarAuthNames, + _callback); + } - // verify the required parameter 'requestId' is set - if (requestId == null) { + @SuppressWarnings("rawtypes") + private okhttp3.Call listAvailabilityZonesValidateBeforeCall( + @javax.annotation.Nonnull String region, final ApiCallback _callback) + throws ApiException { + // 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 * * * - * + * * * * @@ -11465,27 +16782,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 * * * - * + * * * * @@ -11493,20 +16808,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 @@ -11515,7 +16827,7 @@ public ApiResponse getProjectRequestWithHttpInfo( * * * - * + * * * * @@ -11523,24 +16835,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 @@ -11548,7 +16859,7 @@ public okhttp3.Call getProjectRequestAsync( * * * - * + * * * * @@ -11556,9 +16867,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; @@ -11578,13 +16890,13 @@ public okhttp3.Call getPublicIPCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/public-ips/{publicIpId}" + "/v2/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(); @@ -11592,6 +16904,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) { @@ -11621,39 +16938,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 * * * - * + * * * * @@ -11661,26 +16980,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 * * * - * + * * * * @@ -11688,20 +17011,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 @@ -11710,7 +17037,7 @@ public ApiResponse getPublicIPWithHttpInfo( * * * - * + * * * * @@ -11718,23 +17045,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 @@ -11742,7 +17073,7 @@ public okhttp3.Call getPublicIPAsync( * * * - * + * * * * @@ -11750,9 +17081,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; @@ -11772,13 +17105,13 @@ public okhttp3.Call getSecurityGroupCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}" + "/v2/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(); @@ -11786,6 +17119,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) { @@ -11815,39 +17157,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 * * * - * + * * * * @@ -11855,28 +17201,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 * * * - * + * * * * @@ -11884,21 +17234,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 @@ -11907,7 +17261,7 @@ public ApiResponse getSecurityGroupWithHttpInfo( * * * - * + * * * * @@ -11915,25 +17269,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 @@ -11941,7 +17295,7 @@ public okhttp3.Call getSecurityGroupAsync( * * * - * + * * * * @@ -11949,11 +17303,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 @@ -11971,17 +17322,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 = "/v2/keypairs"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -11989,6 +17330,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) { @@ -12013,52 +17359,30 @@ public okhttp3.Call getSecurityGroupRuleCall( localVarHeaderParams, localVarCookieParams, localVarFormParams, - localVarAuthNames, - _callback); - } - - @SuppressWarnings("rawtypes") - private okhttp3.Call getSecurityGroupRuleValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @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 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)"); - } + localVarAuthNames, + _callback); + } - return getSecurityGroupRuleCall(projectId, securityGroupId, securityGroupRuleId, _callback); + @SuppressWarnings("rawtypes") + private okhttp3.Call listKeyPairsValidateBeforeCall( + @javax.annotation.Nullable String labelSelector, final ApiCallback _callback) + throws ApiException { + 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 * * * - * + * * * * @@ -12066,30 +17390,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 * * * - * + * * * * @@ -12097,25 +17416,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 @@ -12124,7 +17436,7 @@ public ApiResponse getSecurityGroupRuleWithHttpInfo( * * * - * + * * * * @@ -12132,27 +17444,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 @@ -12160,7 +17469,7 @@ public okhttp3.Call getSecurityGroupRuleAsync( * * * - * + * * * * @@ -12168,10 +17477,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; @@ -12191,13 +17500,13 @@ public okhttp3.Call getServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}" + "/v2/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(); @@ -12205,8 +17514,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"}; @@ -12238,41 +17547,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 * * * - * + * * * * @@ -12280,29 +17591,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 * * * - * + * * * * @@ -12310,22 +17624,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 @@ -12334,7 +17651,7 @@ public ApiResponse getServerWithHttpInfo( * * * - * + * * * * @@ -12342,25 +17659,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 @@ -12368,7 +17685,7 @@ public okhttp3.Call getServerAsync( * * * - * + * * * * @@ -12376,9 +17693,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; @@ -12398,13 +17715,13 @@ public okhttp3.Call getServerConsoleCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/console" + "/v2/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(); @@ -12441,39 +17758,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 * * * - * + * * * * @@ -12481,27 +17798,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 * * * - * + * * * * @@ -12509,19 +17826,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 @@ -12530,7 +17849,7 @@ public ApiResponse getServerConsoleWithHttpInfo( * * * - * + * * * * @@ -12538,26 +17857,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 @@ -12565,7 +17883,7 @@ public okhttp3.Call getServerConsoleAsync( * * * - * + * * * * @@ -12573,10 +17891,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; @@ -12596,13 +17914,16 @@ public okhttp3.Call getServerLogCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/log" + "/v2/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(); @@ -12610,10 +17931,6 @@ public okhttp3.Call getServerLogCall( 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) { @@ -12643,42 +17960,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)"); } - return getServerLogCall(projectId, serverId, length, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listNetworkAreaRanges(Async)"); + } + + 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 * * * - * + * * * * @@ -12686,31 +18009,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 * * * - * + * * * * @@ -12718,24 +18041,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 @@ -12744,7 +18067,7 @@ public ApiResponse getServerLogWithHttpInfo( * * * - * + * * * * @@ -12752,25 +18075,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 @@ -12778,7 +18103,7 @@ public okhttp3.Call getServerLogAsync( * * * - * + * * * * @@ -12786,9 +18111,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; @@ -12808,13 +18135,16 @@ public okhttp3.Call getSnapshotCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots/{snapshotId}" + "/v2/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(); @@ -12822,6 +18152,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) { @@ -12851,39 +18186,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 'snapshotId' when calling getSnapshot(Async)"); + "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 '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 * * * - * + * * * * @@ -12891,26 +18237,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 * * * - * + * * * * @@ -12918,19 +18271,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 @@ -12939,7 +18300,7 @@ public ApiResponse getSnapshotWithHttpInfo( * * * - * + * * * * @@ -12947,23 +18308,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 @@ -12971,7 +18336,7 @@ public okhttp3.Call getSnapshotAsync( * * * - * + * * * * @@ -12979,9 +18344,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; @@ -13001,13 +18366,10 @@ public okhttp3.Call getVolumeCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes/{volumeId}" - .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) + "/v2/organizations/{organizationId}/network-areas" .replace( - "{" + "volumeId" + "}", - localVarApiClient.escapeString(volumeId.toString())); + "{" + "organizationId" + "}", + localVarApiClient.escapeString(organizationId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -13015,6 +18377,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) { @@ -13044,39 +18411,34 @@ public okhttp3.Call getVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call getVolumeValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @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 getVolume(Async)"); - } - - // verify the required parameter 'volumeId' is set - if (volumeId == null) { + private okhttp3.Call listNetworkAreasValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @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 '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 * * * - * + * * * * @@ -13084,26 +18446,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 * * * - * + * * * * @@ -13111,19 +18476,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 @@ -13132,7 +18500,7 @@ public ApiResponse getVolumeWithHttpInfo( * * * - * + * * * * @@ -13140,23 +18508,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 @@ -13164,7 +18534,7 @@ public okhttp3.Call getVolumeAsync( * * * - * + * * * * @@ -13172,9 +18542,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; @@ -13194,13 +18565,13 @@ public okhttp3.Call getVolumePerformanceClassCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volume-performance-classes/{volumePerformanceClass}" + "/v2/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(); @@ -13208,6 +18579,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) { @@ -13237,40 +18613,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 * * * - * + * * * * @@ -13278,29 +18655,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 * * * - * + * * * * @@ -13308,23 +18686,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 @@ -13333,7 +18712,7 @@ public ApiResponse getVolumePerformanceClassWithHttpInfo * * * - * + * * * * @@ -13341,24 +18720,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 @@ -13366,17 +18748,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 @@ -13395,10 +18780,16 @@ public okhttp3.Call listAffinityGroupsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/affinity-groups" + "/v2/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(); @@ -13406,6 +18797,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) { @@ -13435,85 +18831,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 @@ -13522,31 +18944,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 @@ -13554,7 +18980,7 @@ public okhttp3.Call listAffinityGroupsAsync( * * * - * + * * * * @@ -13562,9 +18988,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; @@ -13584,13 +19011,13 @@ public okhttp3.Call listAttachedVolumesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/volume-attachments" + "/v2/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(); @@ -13598,6 +19025,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) { @@ -13627,39 +19059,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 * * * - * + * * * * @@ -13667,27 +19102,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 * * * - * + * * * * @@ -13695,21 +19134,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 @@ -13718,7 +19160,7 @@ public ApiResponse listAttachedVolumesWithHttpInfo * * * - * + * * * * @@ -13726,21 +19168,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 @@ -13749,7 +19192,7 @@ public okhttp3.Call listAttachedVolumesAsync( * * * - * + * * * * @@ -13757,7 +19200,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[] {}; @@ -13774,7 +19217,7 @@ public okhttp3.Call listAvailabilityZonesCall(final ApiCallback _callback) throw Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/availability-zones"; + String localVarPath = "/v2/networks/public-ip-ranges"; List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -13811,22 +19254,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 * * * - * + * * * * @@ -13834,23 +19277,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 * * * - * + * * * * @@ -13858,15 +19300,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 @@ -13876,7 +19319,7 @@ public ApiResponse listAvailabilityZonesWithHttpIn * * * - * + * * * * @@ -13884,19 +19327,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 @@ -13905,7 +19349,7 @@ public okhttp3.Call listAvailabilityZonesAsync( * * * - * + * * * * @@ -13913,8 +19357,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 { @@ -13935,10 +19380,13 @@ public okhttp3.Call listBackupsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups" + "/v2/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(); @@ -13980,33 +19428,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)"); + } + + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listPublicIPs(Async)"); } - return listBackupsCall(projectId, labelSelector, _callback); + 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 * * * - * + * * * * @@ -14014,28 +19470,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 * * * - * + * * * * @@ -14043,20 +19501,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 @@ -14066,7 +19527,7 @@ public ApiResponse listBackupsWithHttpInfo( * * * - * + * * * * @@ -14074,25 +19535,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 @@ -14100,7 +19561,7 @@ public okhttp3.Call listBackupsAsync( * * * - * + * * * * @@ -14108,10 +19569,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; @@ -14131,10 +19591,13 @@ public okhttp3.Call listImagesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images" + "/v2/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(); @@ -14142,15 +19605,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) { @@ -14180,35 +19634,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)"); } - return listImagesCall(projectId, all, labelSelector, _callback); + // verify the required parameter 'region' is set + if (region == null) { + throw new ApiException( + "Missing the required parameter 'region' when calling listQuotas(Async)"); + } + + 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 * * * - * + * * * * @@ -14216,30 +19674,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 * * * - * + * * * * @@ -14247,23 +19701,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 @@ -14272,7 +19722,7 @@ public ApiResponse listImagesWithHttpInfo( * * * - * + * * * * @@ -14280,24 +19730,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 @@ -14305,7 +19754,7 @@ public okhttp3.Call listImagesAsync( * * * - * + * * * * @@ -14313,8 +19762,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 @@ -14332,7 +19783,14 @@ public okhttp3.Call listKeyPairsCall( Object localVarPostBody = null; // create path and map variables - String localVarPath = "/v1/keypairs"; + String localVarPath = + "/v2/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(); @@ -14340,11 +19798,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) { @@ -14374,25 +19827,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 * * * - * + * * * * @@ -14400,25 +19868,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 * * * - * + * * * * @@ -14426,18 +19897,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 @@ -14446,7 +19920,7 @@ public ApiResponse listKeyPairsWithHttpInfo( * * * - * + * * * * @@ -14454,23 +19928,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 @@ -14478,7 +19956,7 @@ public okhttp3.Call listKeyPairsAsync( * * * - * + * * * * @@ -14486,9 +19964,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; @@ -14508,10 +19989,19 @@ public okhttp3.Call listMachineTypesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/machine-types" + "/v2/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(); @@ -14519,8 +20009,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"}; @@ -14552,35 +20043,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 * * * - * + * * * * @@ -14588,29 +20102,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 * * * - * + * * * * @@ -14618,21 +20138,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 @@ -14641,7 +20169,7 @@ public ApiResponse listMachineTypesWithHttpInfo( * * * - * + * * * * @@ -14649,24 +20177,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 @@ -14674,7 +20208,7 @@ public okhttp3.Call listMachineTypesAsync( * * * - * + * * * * @@ -14682,9 +20216,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; @@ -14704,13 +20240,16 @@ public okhttp3.Call listNetworkAreaProjectsCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/projects" + "/v2/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(); @@ -14718,6 +20257,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) { @@ -14747,39 +20291,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 * * * - * + * * * * @@ -14787,27 +20343,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 * * * - * + * * * * @@ -14815,21 +20377,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 @@ -14838,7 +20406,7 @@ public ApiResponse listNetworkAreaProjectsWithHttpInfo( * * * - * + * * * * @@ -14846,24 +20414,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 @@ -14871,7 +20443,7 @@ public okhttp3.Call listNetworkAreaProjectsAsync( * * * - * + * * * * @@ -14879,9 +20451,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; @@ -14901,13 +20474,16 @@ public okhttp3.Call listNetworkAreaRangesCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/network-ranges" + "/v2/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(); @@ -14944,40 +20520,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 * * * - * + * * * * @@ -14985,28 +20568,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 * * * - * + * * * * @@ -15014,21 +20599,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 @@ -15037,7 +20625,7 @@ public ApiResponse listNetworkAreaRangesWithHttpInfo( * * * - * + * * * * @@ -15045,24 +20633,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 @@ -15071,7 +20661,7 @@ public okhttp3.Call listNetworkAreaRangesAsync( * * * - * + * * * * @@ -15079,9 +20669,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 { @@ -15102,13 +20692,13 @@ public okhttp3.Call listNetworkAreaRoutesCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas/{areaId}/routes" + "/v2/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(); @@ -15150,42 +20740,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 * * * - * + * * * * @@ -15193,31 +20783,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 * * * - * + * * * * @@ -15225,24 +20815,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 @@ -15252,7 +20841,7 @@ public ApiResponse listNetworkAreaRoutesWithHttpInfo( * * * - * + * * * * @@ -15260,26 +20849,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 @@ -15287,7 +20876,7 @@ public okhttp3.Call listNetworkAreaRoutesAsync( * * * - * + * * * * @@ -15295,9 +20884,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; @@ -15317,10 +20907,16 @@ public okhttp3.Call listNetworkAreasCall( // create path and map variables String localVarPath = - "/v1/organizations/{organizationId}/network-areas" + "/v2/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(); @@ -15328,11 +20924,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) { @@ -15362,34 +20953,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 * * * - * + * * * * @@ -15397,29 +21001,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 * * * - * + * * * * @@ -15427,22 +21032,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 @@ -15451,7 +21058,7 @@ public ApiResponse listNetworkAreasWithHttpInfo( * * * - * + * * * * @@ -15459,24 +21066,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 @@ -15484,7 +21093,7 @@ public okhttp3.Call listNetworkAreasAsync( * * * - * + * * * * @@ -15492,9 +21101,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; @@ -15514,10 +21124,16 @@ public okhttp3.Call listNetworksCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks" + "/v2/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(); @@ -15525,11 +21141,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) { @@ -15559,33 +21170,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)"); } - return listNetworksCall(projectId, labelSelector, _callback); + // 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 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 * * * - * + * * * * @@ -15593,28 +21218,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 * * * - * + * * * * @@ -15622,21 +21249,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 @@ -15645,7 +21275,7 @@ public ApiResponse listNetworksWithHttpInfo( * * * - * + * * * * @@ -15653,24 +21283,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 @@ -15679,7 +21311,7 @@ public okhttp3.Call listNetworksAsync( * * * - * + * * * * @@ -15687,9 +21319,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 { @@ -15710,13 +21343,13 @@ public okhttp3.Call listNicsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/networks/{networkId}/nics" + "/v2/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(); @@ -15724,6 +21357,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)); @@ -15758,42 +21395,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 * * * - * + * * * * @@ -15801,31 +21439,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 * * * - * + * * * * @@ -15833,23 +21472,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 @@ -15859,7 +21500,7 @@ public ApiResponse listNicsWithHttpInfo( * * * - * + * * * * @@ -15867,24 +21508,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 @@ -15893,7 +21536,7 @@ public okhttp3.Call listNicsAsync( * * * - * + * * * * @@ -15901,8 +21544,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 { @@ -15923,10 +21567,13 @@ public okhttp3.Call listProjectNICsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/nics" + "/v2/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(); @@ -15968,34 +21615,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 * * * - * + * * * * @@ -16003,29 +21658,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 * * * - * + * * * * @@ -16033,21 +21690,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 @@ -16057,7 +21717,7 @@ public ApiResponse listProjectNICsWithHttpInfo( * * * - * + * * * * @@ -16065,22 +21725,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 @@ -16088,7 +21753,7 @@ public okhttp3.Call listProjectNICsAsync( * * * - * + * * * * @@ -16096,7 +21761,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[] {}; @@ -16113,7 +21783,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 = + "/v2/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(); @@ -16121,6 +21798,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) { @@ -16150,22 +21832,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 * * * - * + * * * * @@ -16173,22 +21874,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 * * * - * + * * * * @@ -16196,17 +21905,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 @@ -16215,7 +21931,7 @@ public ApiResponse listPublicIPRangesWithHttpInfo() * * * - * + * * * * @@ -16223,20 +21939,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 @@ -16244,7 +21967,7 @@ public okhttp3.Call listPublicIPRangesAsync( * * * - * + * * * * @@ -16252,9 +21975,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; @@ -16270,14 +21995,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" + "/v2/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(); @@ -16285,18 +22016,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) { @@ -16307,7 +22033,7 @@ public okhttp3.Call listPublicIPsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -16319,33 +22045,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 * * * - * + * * * * @@ -16353,28 +22101,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 * * * - * + * * * * @@ -16382,21 +22132,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 @@ -16405,7 +22159,7 @@ public ApiResponse listPublicIPsWithHttpInfo( * * * - * + * * * * @@ -16413,23 +22167,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 @@ -16437,7 +22195,7 @@ public okhttp3.Call listPublicIPsAsync( * * * - * + * * * * @@ -16445,8 +22203,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 @@ -16461,14 +22223,17 @@ public okhttp3.Call listQuotasCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = partialUpdateNetworkAreaPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/quotas" + "/v2/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(); @@ -16482,7 +22247,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) { @@ -16493,7 +22258,7 @@ public okhttp3.Call listQuotasCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -16505,30 +22270,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 * * * - * + * * * * @@ -16536,24 +22320,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 * * * - * + * * * * @@ -16561,17 +22353,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 @@ -16580,7 +22381,7 @@ public ApiResponse listQuotasWithHttpInfo( * * * - * + * * * * @@ -16588,22 +22389,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 @@ -16611,17 +22419,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; @@ -16641,13 +22452,16 @@ public okhttp3.Call listSecurityGroupRulesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}/rules" + "/v2/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(); @@ -16655,6 +22469,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) { @@ -16672,7 +22490,7 @@ public okhttp3.Call listSecurityGroupRulesCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -16684,91 +22502,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 @@ -16777,32 +22616,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 @@ -16810,7 +22653,7 @@ public okhttp3.Call listSecurityGroupRulesAsync( * * * - * + * * * * @@ -16818,9 +22661,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; @@ -16840,10 +22685,19 @@ public okhttp3.Call listSecurityGroupsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups" + "/v2/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(); @@ -16851,11 +22705,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) { @@ -16873,7 +22722,7 @@ public okhttp3.Call listSecurityGroupsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -16885,34 +22734,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 * * * - * + * * * * @@ -16920,29 +22790,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 * * * - * + * * * * @@ -16950,22 +22822,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 @@ -16974,7 +22851,7 @@ public ApiResponse listSecurityGroupsWithHttpInfo( * * * - * + * * * * @@ -16982,24 +22859,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 @@ -17007,7 +22888,7 @@ public okhttp3.Call listSecurityGroupsAsync( * * * - * + * * * * @@ -17015,9 +22896,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; @@ -17037,13 +22920,19 @@ public okhttp3.Call listServerNicsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/nics" + "/v2/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(); @@ -17068,7 +22957,7 @@ public okhttp3.Call listServerNicsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17080,39 +22969,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 * * * - * + * * * * @@ -17120,26 +23024,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 * * * - * + * * * * @@ -17147,20 +23055,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 @@ -17169,7 +23081,7 @@ public ApiResponse listServerNicsWithHttpInfo( * * * - * + * * * * @@ -17177,24 +23089,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 @@ -17202,17 +23118,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; @@ -17232,13 +23151,19 @@ public okhttp3.Call listServerServiceAccountsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/service-accounts" + "/v2/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(); @@ -17263,7 +23188,7 @@ public okhttp3.Call listServerServiceAccountsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17275,89 +23200,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 @@ -17366,33 +23316,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 @@ -17400,18 +23354,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; @@ -17431,10 +23387,19 @@ public okhttp3.Call listServersCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers" + "/v2/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(); @@ -17442,15 +23407,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) { @@ -17468,7 +23424,7 @@ public okhttp3.Call listServersCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17480,91 +23436,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 @@ -17573,33 +23553,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 @@ -17607,17 +23591,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; @@ -17637,10 +23624,19 @@ public okhttp3.Call listSnapshotsCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots" + "/v2/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(); @@ -17648,11 +23644,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) { @@ -17670,7 +23661,7 @@ public okhttp3.Call listSnapshotsCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17682,84 +23673,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 @@ -17768,32 +23795,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 @@ -17801,17 +23834,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; @@ -17831,10 +23867,19 @@ public okhttp3.Call listVolumePerformanceClassesCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volume-performance-classes" + "/v2/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(); @@ -17842,11 +23887,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) { @@ -17864,7 +23904,7 @@ public okhttp3.Call listVolumePerformanceClassesCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -17876,87 +23916,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)"); + } + + // verify the required parameter 'volumeId' is set + if (volumeId == null) { + throw new ApiException( + "Missing the required parameter 'volumeId' when calling removeVolumeFromServer(Async)"); } - return listVolumePerformanceClassesCall(projectId, labelSelector, _callback); + 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 @@ -17965,32 +24032,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 @@ -17998,17 +24070,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; @@ -18024,14 +24099,20 @@ public okhttp3.Call listVolumesCall( basePath = null; } - Object localVarPostBody = null; + Object localVarPostBody = rescueServerPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes" + "/v2/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(); @@ -18039,18 +24120,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) { @@ -18061,7 +24137,7 @@ public okhttp3.Call listVolumesCall( return localVarApiClient.buildCall( basePath, localVarPath, - "GET", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -18073,84 +24149,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)"); } - return listVolumesCall(projectId, labelSelector, _callback); + // verify the required parameter 'rescueServerPayload' is set + if (rescueServerPayload == null) { + throw new ApiException( + "Missing the required parameter 'rescueServerPayload' when calling rescueServer(Async)"); + } + + 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 @@ -18159,33 +24270,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 @@ -18193,18 +24308,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( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID networkId, - @javax.annotation.Nonnull PartialUpdateNetworkPayload partialUpdateNetworkPayload, + public okhttp3.Call resizeServerCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID serverId, + @javax.annotation.Nonnull ResizeServerPayload resizeServerPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -18220,17 +24337,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}" + "/v2/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(); @@ -18255,7 +24375,7 @@ public okhttp3.Call partialUpdateNetworkCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -18267,68 +24387,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 '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 partialUpdateNetwork(Async)"); + "Missing the required parameter 'region' when calling resizeServer(Async)"); } - // verify the required parameter 'partialUpdateNetworkPayload' is set - if (partialUpdateNetworkPayload == null) { + // verify the required parameter 'serverId' is set + if (serverId == null) { throw new ApiException( - "Missing the required parameter 'partialUpdateNetworkPayload' when calling partialUpdateNetwork(Async)"); + "Missing the required parameter 'serverId' when calling resizeServer(Async)"); } - return partialUpdateNetworkCall( - projectId, networkId, partialUpdateNetworkPayload, _callback); + // verify the required parameter 'resizeServerPayload' is set + if (resizeServerPayload == null) { + throw new ApiException( + "Missing the required parameter 'resizeServerPayload' when calling resizeServer(Async)"); + } + + 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 @@ -18336,31 +24466,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 @@ -18369,34 +24502,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 @@ -18404,19 +24540,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; @@ -18432,17 +24569,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}" + "/v2/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(); @@ -18467,7 +24607,7 @@ public okhttp3.Call partialUpdateNetworkAreaCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -18479,109 +24619,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 @@ -18590,36 +24731,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 @@ -18627,19 +24768,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; @@ -18659,13 +24799,16 @@ public okhttp3.Call rebootServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/reboot" + "/v2/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(); @@ -18673,10 +24816,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) { @@ -18706,66 +24845,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 'region' when calling restoreBackup(Async)"); + } + + // verify the required parameter 'backupId' is set + if (backupId == null) { throw new ApiException( - "Missing the required parameter 'serverId' when calling rebootServer(Async)"); + "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 @@ -18773,33 +24917,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 @@ -18808,34 +24952,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 @@ -18843,7 +24987,7 @@ public okhttp3.Call rebootServerAsync( * * * - * + * * * * @@ -18851,10 +24995,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; @@ -18870,20 +25015,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}" + "/v2/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(); @@ -18897,7 +25042,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) { @@ -18908,7 +25053,7 @@ public okhttp3.Call removeNetworkFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -18920,47 +25065,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)"); } - return removeNetworkFromServerCall(projectId, serverId, networkId, _callback); + // verify the required parameter 'setImageSharePayload' is set + if (setImageSharePayload == null) { + throw new ApiException( + "Missing the required parameter 'setImageSharePayload' when calling setImageShare(Async)"); + } + + 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 * * * - * + * * * * @@ -18968,29 +25121,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 * * * - * + * * * * @@ -18998,24 +25154,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 @@ -19024,7 +25183,7 @@ public ApiResponse removeNetworkFromServerWithHttpInfo( * * * - * + * * * * @@ -19032,26 +25191,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 @@ -19059,18 +25220,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; @@ -19090,16 +25252,16 @@ public okhttp3.Call removeNicFromServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/nics/{nicId}" + "/v2/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(); @@ -19124,7 +25286,7 @@ public okhttp3.Call removeNicFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19136,67 +25298,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 @@ -19204,30 +25367,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 @@ -19236,33 +25401,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 @@ -19270,19 +25436,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; @@ -19302,16 +25468,16 @@ public okhttp3.Call removePublicIpFromServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/public-ips/{publicIpId}" + "/v2/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(); @@ -19336,7 +25502,7 @@ public okhttp3.Call removePublicIpFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19348,68 +25514,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 @@ -19417,32 +25587,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 @@ -19451,35 +25621,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 @@ -19487,7 +25656,7 @@ public okhttp3.Call removePublicIpFromServerAsync( * * * - * + * * * * @@ -19496,10 +25665,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; @@ -19519,16 +25688,16 @@ public okhttp3.Call removeSecurityGroupFromServerCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}/security-groups/{securityGroupId}" + "/v2/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(); @@ -19553,7 +25722,7 @@ public okhttp3.Call removeSecurityGroupFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19565,46 +25734,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 * * * - * + * * * * @@ -19613,20 +25783,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 @@ -19634,7 +25805,7 @@ public void removeSecurityGroupFromServer( * * * - * + * * * * @@ -19643,24 +25814,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 @@ -19669,7 +25839,7 @@ public ApiResponse removeSecurityGroupFromServerWithHttpInfo( * * * - * + * * * * @@ -19678,26 +25848,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 @@ -19705,19 +25876,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; @@ -19733,20 +25905,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}" + "/v2/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(); @@ -19760,7 +25935,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) { @@ -19771,7 +25946,7 @@ public okhttp3.Call removeServiceAccountFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -19783,107 +25958,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 @@ -19892,36 +26090,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 @@ -19929,19 +26134,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; @@ -19957,20 +26162,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}" + "/v2/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(); @@ -19984,7 +26189,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) { @@ -19995,7 +26200,7 @@ public okhttp3.Call removeVolumeFromServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "DELETE", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20007,101 +26212,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 'imageId' is set + if (imageId == null) { + throw new ApiException( + "Missing the required parameter 'imageId' when calling updateImage(Async)"); } - // verify the required parameter 'volumeId' is set - if (volumeId == null) { + // verify the required parameter 'updateImagePayload' is set + if (updateImagePayload == null) { throw new ApiException( - "Missing the required parameter 'volumeId' when calling removeVolumeFromServer(Async)"); + "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 @@ -20110,34 +26329,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 @@ -20145,19 +26367,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; @@ -20173,17 +26395,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" + "/v2/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(); @@ -20208,7 +26433,7 @@ public okhttp3.Call rescueServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20220,106 +26445,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 @@ -20328,34 +26563,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 @@ -20363,19 +26599,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; @@ -20391,17 +26625,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" + "/v2/keypairs/{keypairName}" .replace( - "{" + "projectId" + "}", - localVarApiClient.escapeString(projectId.toString())) - .replace( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "keypairName" + "}", + localVarApiClient.escapeString(keypairName.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -20426,7 +26657,7 @@ public okhttp3.Call resizeServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20438,100 +26669,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 @@ -20540,34 +26761,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 @@ -20575,19 +26797,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; @@ -20603,17 +26826,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" + "/v2/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(); @@ -20638,7 +26864,7 @@ public okhttp3.Call resizeVolumeCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20650,97 +26876,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)"); } - return resizeVolumeCall(projectId, volumeId, resizeVolumePayload, _callback); + // verify the required parameter 'updateManagementNetworkRoutePayload' is set + if (updateManagementNetworkRoutePayload == null) { + throw new ApiException( + "Missing the required parameter 'updateManagementNetworkRoutePayload' when calling updateManagementNetworkRoute(Async)"); + } + + 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 @@ -20749,33 +27002,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 @@ -20783,17 +27042,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; @@ -20809,17 +27072,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" + "/v2/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(); @@ -20833,7 +27102,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) { @@ -20844,7 +27113,7 @@ public okhttp3.Call restoreBackupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -20856,90 +27125,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 @@ -20948,31 +27259,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 @@ -20980,7 +27299,7 @@ public okhttp3.Call restoreBackupAsync( * * * - * + * * * * @@ -20988,10 +27307,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; @@ -21007,17 +27327,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" + "/v2/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(); @@ -21042,7 +27365,7 @@ public okhttp3.Call setImageShareCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PUT", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -21054,47 +27377,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 * * * - * + * * * * @@ -21102,30 +27433,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 * * * - * + * * * * @@ -21133,24 +27466,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 @@ -21159,7 +27495,7 @@ public ApiResponse setImageShareWithHttpInfo( * * * - * + * * * * @@ -21167,26 +27503,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 @@ -21194,18 +27536,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; @@ -21221,17 +27567,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" + "/v2/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(); @@ -21245,7 +27600,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) { @@ -21256,7 +27611,7 @@ public okhttp3.Call startServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -21268,86 +27623,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)"); + } + + // verify the required parameter 'updateRouteOfRoutingTablePayload' is set + if (updateRouteOfRoutingTablePayload == null) { + throw new ApiException( + "Missing the required parameter 'updateRouteOfRoutingTablePayload' when calling updateRouteOfRoutingTable(Async)"); } - return startServerCall(projectId, serverId, _callback); + 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 @@ -21356,31 +27790,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 @@ -21388,18 +27838,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; @@ -21415,17 +27868,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" + "/v2/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( - "{" + "serverId" + "}", - localVarApiClient.escapeString(serverId.toString())); + "{" + "routingTableId" + "}", + localVarApiClient.escapeString(routingTableId.toString())); List localVarQueryParams = new ArrayList(); List localVarCollectionQueryParams = new ArrayList(); @@ -21439,7 +27898,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) { @@ -21450,7 +27909,7 @@ public okhttp3.Call stopServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -21462,91 +27921,146 @@ public okhttp3.Call stopServerCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call stopServerValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID serverId, + 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 '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 stopServer(Async)"); + "Missing the required parameter 'organizationId' when calling updateRoutingTableOfArea(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 stopServer(Async)"); + "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 'region' when calling updateRoutingTableOfArea(Async)"); + } + + // verify the required parameter 'routingTableId' is set + if (routingTableId == null) { + throw new ApiException( + "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 @@ -21555,31 +28069,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 @@ -21587,18 +28114,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; @@ -21614,14 +28142,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" + "/v2/projects/{projectId}/regions/{region}/servers/{serverId}" .replace( "{" + "projectId" + "}", localVarApiClient.escapeString(projectId.toString())) + .replace( + "{" + "region" + "}", + localVarApiClient.escapeString(region.toString())) .replace( "{" + "serverId" + "}", localVarApiClient.escapeString(serverId.toString())); @@ -21638,7 +28169,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) { @@ -21649,7 +28180,7 @@ public okhttp3.Call unrescueServerCall( return localVarApiClient.buildCall( basePath, localVarPath, - "POST", + "PATCH", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -21661,88 +28192,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 @@ -21751,34 +28309,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 @@ -21786,7 +28347,7 @@ public okhttp3.Call unrescueServerAsync( * * * - * + * * * * @@ -21794,11 +28355,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; @@ -21814,17 +28375,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}" + "/v2/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())); @@ -21864,56 +28425,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 * * * - * + * * * * @@ -21921,33 +28481,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 * * * - * + * * * * @@ -21955,27 +28514,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 @@ -21984,7 +28543,7 @@ public ApiResponse updateAttachedVolumeWithHttpInfo( * * * - * + * * * * @@ -21992,28 +28551,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 v2ConfigureNetworkAreaRegion * - * @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 v2ConfigureNetworkAreaRegionPayload 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 @@ -22021,18 +28582,21 @@ 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 v2ConfigureNetworkAreaRegionCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2ConfigureNetworkAreaRegionPayload v2ConfigureNetworkAreaRegionPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22048,17 +28612,20 @@ public okhttp3.Call updateBackupCall( basePath = null; } - Object localVarPostBody = updateBackupPayload; + Object localVarPostBody = v2ConfigureNetworkAreaRegionPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/backups/{backupId}" + "/v2/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(); @@ -22083,7 +28650,7 @@ public okhttp3.Call updateBackupCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "PUT", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -22095,102 +28662,126 @@ 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 v2ConfigureNetworkAreaRegionValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2ConfigureNetworkAreaRegionPayload v2ConfigureNetworkAreaRegionPayload, 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 v2ConfigureNetworkAreaRegion(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 v2ConfigureNetworkAreaRegion(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 v2ConfigureNetworkAreaRegion(Async)"); } - // verify the required parameter 'updateBackupPayload' is set - if (updateBackupPayload == null) { + // verify the required parameter 'v2ConfigureNetworkAreaRegionPayload' is set + if (v2ConfigureNetworkAreaRegionPayload == null) { throw new ApiException( - "Missing the required parameter 'updateBackupPayload' when calling updateBackup(Async)"); + "Missing the required parameter 'v2ConfigureNetworkAreaRegionPayload' when calling v2ConfigureNetworkAreaRegion(Async)"); } - return updateBackupCall(projectId, backupId, updateBackupPayload, _callback); + return v2ConfigureNetworkAreaRegionCall( + organizationId, areaId, region, v2ConfigureNetworkAreaRegionPayload, _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 v2ConfigureNetworkAreaRegionPayload 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 v2ConfigureNetworkAreaRegion( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2ConfigureNetworkAreaRegionPayload v2ConfigureNetworkAreaRegionPayload) throws ApiException { - ApiResponse localVarResp = - updateBackupWithHttpInfo(projectId, backupId, updateBackupPayload); + ApiResponse localVarResp = + v2ConfigureNetworkAreaRegionWithHttpInfo( + organizationId, areaId, region, v2ConfigureNetworkAreaRegionPayload); 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 v2ConfigureNetworkAreaRegionPayload 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 v2ConfigureNetworkAreaRegionWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2ConfigureNetworkAreaRegionPayload v2ConfigureNetworkAreaRegionPayload) throws ApiException { okhttp3.Call localVarCall = - updateBackupValidateBeforeCall(projectId, backupId, updateBackupPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2ConfigureNetworkAreaRegionValidateBeforeCall( + organizationId, areaId, region, v2ConfigureNetworkAreaRegionPayload, 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 v2ConfigureNetworkAreaRegionPayload 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 @@ -22199,34 +28790,42 @@ 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 v2ConfigureNetworkAreaRegionAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2ConfigureNetworkAreaRegionPayload v2ConfigureNetworkAreaRegionPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateBackupValidateBeforeCall(projectId, backupId, updateBackupPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2ConfigureNetworkAreaRegionValidateBeforeCall( + organizationId, + areaId, + region, + v2ConfigureNetworkAreaRegionPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateImage + * Build call for v2CreateSnapshot * * @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 v2CreateSnapshotPayload 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 @@ -22234,7 +28833,7 @@ public okhttp3.Call updateBackupAsync( * * * - * + * * * * @@ -22242,10 +28841,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 v2CreateSnapshotCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2CreateSnapshotPayload v2CreateSnapshotPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22261,17 +28860,17 @@ public okhttp3.Call updateImageCall( basePath = null; } - Object localVarPostBody = updateImagePayload; + Object localVarPostBody = v2CreateSnapshotPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}" + "/v2/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(); @@ -22296,7 +28895,7 @@ public okhttp3.Call updateImageCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "POST", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -22308,47 +28907,47 @@ public okhttp3.Call updateImageCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateImageValidateBeforeCall( + private okhttp3.Call v2CreateSnapshotValidateBeforeCall( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2CreateSnapshotPayload v2CreateSnapshotPayload, 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 v2CreateSnapshot(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 v2CreateSnapshot(Async)"); } - // verify the required parameter 'updateImagePayload' is set - if (updateImagePayload == null) { + // verify the required parameter 'v2CreateSnapshotPayload' is set + if (v2CreateSnapshotPayload == null) { throw new ApiException( - "Missing the required parameter 'updateImagePayload' when calling updateImage(Async)"); + "Missing the required parameter 'v2CreateSnapshotPayload' when calling v2CreateSnapshot(Async)"); } - return updateImageCall(projectId, imageId, updateImagePayload, _callback); + return v2CreateSnapshotCall(projectId, region, v2CreateSnapshotPayload, _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 v2CreateSnapshotPayload 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 * * * - * + * * * * @@ -22356,30 +28955,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 v2CreateSnapshot( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2CreateSnapshotPayload v2CreateSnapshotPayload) throws ApiException { - ApiResponse localVarResp = - updateImageWithHttpInfo(projectId, imageId, updateImagePayload); + ApiResponse localVarResp = + v2CreateSnapshotWithHttpInfo(projectId, region, v2CreateSnapshotPayload); 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 v2CreateSnapshotPayload 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 * * * - * + * * * * @@ -22387,24 +28986,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 v2CreateSnapshotWithHttpInfo( @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, - @javax.annotation.Nonnull UpdateImagePayload updateImagePayload) + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull V2CreateSnapshotPayload v2CreateSnapshotPayload) throws ApiException { okhttp3.Call localVarCall = - updateImageValidateBeforeCall(projectId, imageId, updateImagePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2CreateSnapshotValidateBeforeCall( + projectId, region, v2CreateSnapshotPayload, 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 v2CreateSnapshotPayload 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 @@ -22413,7 +29012,7 @@ public ApiResponse updateImageWithHttpInfo( * * * - * + * * * * @@ -22421,25 +29020,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 v2CreateSnapshotAsync( @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 V2CreateSnapshotPayload v2CreateSnapshotPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateImageValidateBeforeCall(projectId, imageId, updateImagePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2CreateSnapshotValidateBeforeCall( + projectId, region, v2CreateSnapshotPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateImageScopeLocal + * Build call for v2DeleteNetworkAreaRegion * - * @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 @@ -22447,17 +29048,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 v2DeleteNetworkAreaRegionCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22477,13 +29080,16 @@ public okhttp3.Call updateImageScopeLocalCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/publish" + "/v2/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(); @@ -22520,90 +29126,103 @@ public okhttp3.Call updateImageScopeLocalCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateImageScopeLocalValidateBeforeCall( - @javax.annotation.Nonnull UUID projectId, - @javax.annotation.Nonnull UUID imageId, + private okhttp3.Call v2DeleteNetworkAreaRegionValidateBeforeCall( + @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 v2DeleteNetworkAreaRegion(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 v2DeleteNetworkAreaRegion(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 v2DeleteNetworkAreaRegion(Async)"); } - return updateImageScopeLocalCall(projectId, imageId, _callback); + return v2DeleteNetworkAreaRegionCall(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 v2DeleteNetworkAreaRegion( + @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(); + v2DeleteNetworkAreaRegionWithHttpInfo(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 v2DeleteNetworkAreaRegionWithHttpInfo( + @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); + v2DeleteNetworkAreaRegionValidateBeforeCall(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 @@ -22612,32 +29231,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 v2DeleteNetworkAreaRegionAsync( + @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); + v2DeleteNetworkAreaRegionValidateBeforeCall( + organizationId, areaId, region, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for updateImageScopePublic + * Build call for v2DeleteSnapshot * * @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 @@ -22645,7 +29267,7 @@ public okhttp3.Call updateImageScopeLocalAsync( * * * - * + * * * * @@ -22653,9 +29275,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 v2DeleteSnapshotCall( @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; @@ -22675,13 +29298,16 @@ public okhttp3.Call updateImageScopePublicCall( // create path and map variables String localVarPath = - "/v1/projects/{projectId}/images/{imageId}/publish" + "/v2/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(); @@ -22706,7 +29332,7 @@ public okhttp3.Call updateImageScopePublicCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PUT", + "DELETE", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -22718,40 +29344,46 @@ public okhttp3.Call updateImageScopePublicCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateImageScopePublicValidateBeforeCall( + private okhttp3.Call v2DeleteSnapshotValidateBeforeCall( @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 v2DeleteSnapshot(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 'region' when calling v2DeleteSnapshot(Async)"); + } + + // verify the required parameter 'snapshotId' is set + if (snapshotId == null) { throw new ApiException( - "Missing the required parameter 'imageId' when calling updateImageScopePublic(Async)"); + "Missing the required parameter 'snapshotId' when calling v2DeleteSnapshot(Async)"); } - return updateImageScopePublicCall(projectId, imageId, _callback); + return v2DeleteSnapshotCall(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 * * * - * + * * * * @@ -22759,27 +29391,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 v2DeleteSnapshot( + @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(); + v2DeleteSnapshotWithHttpInfo(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 * * * - * + * * * * @@ -22787,21 +29420,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 v2DeleteSnapshotWithHttpInfo( + @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); + v2DeleteSnapshotValidateBeforeCall(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 @@ -22810,7 +29444,7 @@ public ApiResponse updateImageScopePublicWithHttpInfo( * * * - * + * * * * @@ -22818,25 +29452,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 v2DeleteSnapshotAsync( @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); + v2DeleteSnapshotValidateBeforeCall(projectId, region, snapshotId, _callback); + localVarApiClient.executeAsync(localVarCall, _callback); return localVarCall; } /** - * Build call for updateImageShare + * Build call for v2GetAreaRegion * - * @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 @@ -22844,7 +29478,7 @@ public okhttp3.Call updateImageScopePublicAsync( * * * - * + * * * * @@ -22852,10 +29486,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 v2GetAreaRegionCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -22871,17 +29505,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" + "/v2/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(); @@ -22895,7 +29532,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) { @@ -22906,7 +29543,7 @@ public okhttp3.Call updateImageShareCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -22918,47 +29555,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 v2GetAreaRegionValidateBeforeCall( + @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 v2GetAreaRegion(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 v2GetAreaRegion(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 v2GetAreaRegion(Async)"); } - return updateImageShareCall(projectId, imageId, updateImageSharePayload, _callback); + return v2GetAreaRegionCall(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 * * * - * + * * * * @@ -22966,30 +29604,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 v2GetAreaRegion( + @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 = + v2GetAreaRegionWithHttpInfo(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 * * * - * + * * * * @@ -22997,25 +29636,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 v2GetAreaRegionWithHttpInfo( + @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(); + v2GetAreaRegionValidateBeforeCall(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 @@ -23024,7 +29662,7 @@ public ApiResponse updateImageShareWithHttpInfo( * * * - * + * * * * @@ -23032,26 +29670,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 v2GetAreaRegionAsync( + @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(); + v2GetAreaRegionValidateBeforeCall(organizationId, areaId, region, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateKeyPair + * Build call for v2GetSnapshot * - * @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 @@ -23059,7 +29697,7 @@ public okhttp3.Call updateImageShareAsync( * * * - * + * * * * @@ -23067,9 +29705,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 v2GetSnapshotCall( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -23085,14 +29724,20 @@ public okhttp3.Call updateKeyPairCall( basePath = null; } - Object localVarPostBody = updateKeyPairPayload; + Object localVarPostBody = null; // create path and map variables String localVarPath = - "/v1/keypairs/{keypairName}" + "/v2/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(); @@ -23106,7 +29751,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) { @@ -23117,7 +29762,7 @@ public okhttp3.Call updateKeyPairCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -23129,39 +29774,47 @@ public okhttp3.Call updateKeyPairCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateKeyPairValidateBeforeCall( - @javax.annotation.Nonnull String keypairName, - @javax.annotation.Nonnull UpdateKeyPairPayload updateKeyPairPayload, + private okhttp3.Call v2GetSnapshotValidateBeforeCall( + @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 v2GetSnapshot(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 v2GetSnapshot(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 v2GetSnapshot(Async)"); + } + + return v2GetSnapshotCall(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 * * * - * + * * * * @@ -23169,28 +29822,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 v2GetSnapshot( + @javax.annotation.Nonnull UUID projectId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID snapshotId) throws ApiException { - ApiResponse localVarResp = - updateKeyPairWithHttpInfo(keypairName, updateKeyPairPayload); + ApiResponse localVarResp = + v2GetSnapshotWithHttpInfo(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 * * * - * + * * * * @@ -23198,21 +29853,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 v2GetSnapshotWithHttpInfo( + @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(); + v2GetSnapshotValidateBeforeCall(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 @@ -23221,7 +29878,7 @@ public ApiResponse updateKeyPairWithHttpInfo( * * * - * + * * * * @@ -23229,26 +29886,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 v2GetSnapshotAsync( + @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(); + v2GetSnapshotValidateBeforeCall(projectId, region, snapshotId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateNetworkAreaRoute + * Build call for v2ListAreaRegions * * @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 @@ -23256,7 +29912,7 @@ public okhttp3.Call updateKeyPairAsync( * * * - * + * * * * @@ -23264,11 +29920,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 v2ListAreaRegionsCall( @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; @@ -23284,20 +29938,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}" + "/v2/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(); @@ -23311,7 +29962,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) { @@ -23322,7 +29973,7 @@ public okhttp3.Call updateNetworkAreaRouteCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -23334,56 +29985,39 @@ public okhttp3.Call updateNetworkAreaRouteCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateNetworkAreaRouteValidateBeforeCall( + private okhttp3.Call v2ListAreaRegionsValidateBeforeCall( @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 v2ListAreaRegions(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 v2ListAreaRegions(Async)"); } - return updateNetworkAreaRouteCall( - organizationId, areaId, routeId, updateNetworkAreaRoutePayload, _callback); + return v2ListAreaRegionsCall(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 * * * - * + * * * * @@ -23391,33 +30025,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 v2ListAreaRegions( + @javax.annotation.Nonnull UUID organizationId, @javax.annotation.Nonnull UUID areaId) throws ApiException { - ApiResponse localVarResp = - updateNetworkAreaRouteWithHttpInfo( - organizationId, areaId, routeId, updateNetworkAreaRoutePayload); + ApiResponse localVarResp = + v2ListAreaRegionsWithHttpInfo(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 * * * - * + * * * * @@ -23425,26 +30053,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 v2ListAreaRegionsWithHttpInfo( + @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(); + v2ListAreaRegionsValidateBeforeCall(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 @@ -23453,7 +30076,7 @@ public ApiResponse updateNetworkAreaRouteWithHttpInfo( * * * - * + * * * * @@ -23461,29 +30084,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 v2ListAreaRegionsAsync( @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(); + v2ListAreaRegionsValidateBeforeCall(organizationId, areaId, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateNic + * Build call for v2ListSnapshotsInProject * * @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 @@ -23491,20 +30110,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 v2ListSnapshotsInProjectCall( @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; @@ -23520,20 +30137,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}" + "/v2/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(); @@ -23541,13 +30155,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) { @@ -23558,7 +30177,7 @@ public okhttp3.Call updateNicCall( return localVarApiClient.buildCall( basePath, localVarPath, - "PATCH", + "GET", localVarQueryParams, localVarCollectionQueryParams, localVarPostBody, @@ -23570,119 +30189,97 @@ public okhttp3.Call updateNicCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateNicValidateBeforeCall( + private okhttp3.Call v2ListSnapshotsInProjectValidateBeforeCall( @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 v2ListSnapshotsInProject(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 v2ListSnapshotsInProject(Async)"); } - return updateNicCall(projectId, networkId, nicId, updateNicPayload, _callback); + return v2ListSnapshotsInProjectCall(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 v2ListSnapshotsInProject( @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 = + v2ListSnapshotsInProjectWithHttpInfo(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 v2ListSnapshotsInProjectWithHttpInfo( @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(); + v2ListSnapshotsInProjectValidateBeforeCall(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 @@ -23691,37 +30288,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 v2ListSnapshotsInProjectAsync( @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(); + v2ListSnapshotsInProjectValidateBeforeCall( + projectId, region, labelSelector, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updatePublicIP + * Build call for v2UpdateBackup * * @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 v2UpdateBackupPayload 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 @@ -23729,7 +30325,7 @@ public okhttp3.Call updateNicAsync( * * * - * + * * * * @@ -23737,10 +30333,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 v2UpdateBackupCall( @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 V2UpdateBackupPayload v2UpdateBackupPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -23756,17 +30353,20 @@ public okhttp3.Call updatePublicIPCall( basePath = null; } - Object localVarPostBody = updatePublicIPPayload; + Object localVarPostBody = v2UpdateBackupPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/public-ips/{publicIpId}" + "/v2/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(); @@ -23803,47 +30403,55 @@ public okhttp3.Call updatePublicIPCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updatePublicIPValidateBeforeCall( + private okhttp3.Call v2UpdateBackupValidateBeforeCall( @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 V2UpdateBackupPayload v2UpdateBackupPayload, 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 v2UpdateBackup(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 v2UpdateBackup(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 v2UpdateBackup(Async)"); + } + + // verify the required parameter 'v2UpdateBackupPayload' is set + if (v2UpdateBackupPayload == null) { + throw new ApiException( + "Missing the required parameter 'v2UpdateBackupPayload' when calling v2UpdateBackup(Async)"); } - return updatePublicIPCall(projectId, publicIpId, updatePublicIPPayload, _callback); + return v2UpdateBackupCall(projectId, region, backupId, v2UpdateBackupPayload, _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 v2UpdateBackupPayload 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 * * * - * + * * * * @@ -23851,30 +30459,32 @@ 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 v2UpdateBackup( @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 V2UpdateBackupPayload v2UpdateBackupPayload) throws ApiException { - ApiResponse localVarResp = - updatePublicIPWithHttpInfo(projectId, publicIpId, updatePublicIPPayload); + ApiResponse localVarResp = + v2UpdateBackupWithHttpInfo(projectId, region, backupId, v2UpdateBackupPayload); 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 v2UpdateBackupPayload 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 * * * - * + * * * * @@ -23882,25 +30492,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 v2UpdateBackupWithHttpInfo( @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 V2UpdateBackupPayload v2UpdateBackupPayload) throws ApiException { okhttp3.Call localVarCall = - updatePublicIPValidateBeforeCall( - projectId, publicIpId, updatePublicIPPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateBackupValidateBeforeCall( + projectId, region, backupId, v2UpdateBackupPayload, 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 v2UpdateBackupPayload 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 @@ -23909,7 +30520,7 @@ public ApiResponse updatePublicIPWithHttpInfo( * * * - * + * * * * @@ -23917,27 +30528,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 v2UpdateBackupAsync( @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 V2UpdateBackupPayload v2UpdateBackupPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updatePublicIPValidateBeforeCall( - projectId, publicIpId, updatePublicIPPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateBackupValidateBeforeCall( + projectId, region, backupId, v2UpdateBackupPayload, _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateSecurityGroup + * Build call for v2UpdateNetworkAreaRegion * - * @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 v2UpdateNetworkAreaRegionPayload 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 @@ -23945,18 +30559,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 v2UpdateNetworkAreaRegionCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2UpdateNetworkAreaRegionPayload v2UpdateNetworkAreaRegionPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -23972,17 +30589,20 @@ public okhttp3.Call updateSecurityGroupCall( basePath = null; } - Object localVarPostBody = updateSecurityGroupPayload; + Object localVarPostBody = v2UpdateNetworkAreaRegionPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/security-groups/{securityGroupId}" + "/v2/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(); @@ -24019,105 +30639,125 @@ 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 v2UpdateNetworkAreaRegionValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2UpdateNetworkAreaRegionPayload v2UpdateNetworkAreaRegionPayload, 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 v2UpdateNetworkAreaRegion(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 'securityGroupId' when calling updateSecurityGroup(Async)"); + "Missing the required parameter 'areaId' when calling v2UpdateNetworkAreaRegion(Async)"); } - // verify the required parameter 'updateSecurityGroupPayload' is set - if (updateSecurityGroupPayload == null) { + // verify the required parameter 'region' is set + if (region == null) { throw new ApiException( - "Missing the required parameter 'updateSecurityGroupPayload' when calling updateSecurityGroup(Async)"); + "Missing the required parameter 'region' when calling v2UpdateNetworkAreaRegion(Async)"); } - return updateSecurityGroupCall( - projectId, securityGroupId, updateSecurityGroupPayload, _callback); + // verify the required parameter 'v2UpdateNetworkAreaRegionPayload' is set + if (v2UpdateNetworkAreaRegionPayload == null) { + throw new ApiException( + "Missing the required parameter 'v2UpdateNetworkAreaRegionPayload' when calling v2UpdateNetworkAreaRegion(Async)"); + } + + return v2UpdateNetworkAreaRegionCall( + organizationId, areaId, region, v2UpdateNetworkAreaRegionPayload, _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 v2UpdateNetworkAreaRegionPayload 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 v2UpdateNetworkAreaRegion( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2UpdateNetworkAreaRegionPayload v2UpdateNetworkAreaRegionPayload) throws ApiException { - ApiResponse localVarResp = - updateSecurityGroupWithHttpInfo( - projectId, securityGroupId, updateSecurityGroupPayload); + ApiResponse localVarResp = + v2UpdateNetworkAreaRegionWithHttpInfo( + organizationId, areaId, region, v2UpdateNetworkAreaRegionPayload); 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 v2UpdateNetworkAreaRegionPayload 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 v2UpdateNetworkAreaRegionWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2UpdateNetworkAreaRegionPayload v2UpdateNetworkAreaRegionPayload) throws ApiException { okhttp3.Call localVarCall = - updateSecurityGroupValidateBeforeCall( - projectId, securityGroupId, updateSecurityGroupPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateNetworkAreaRegionValidateBeforeCall( + organizationId, areaId, region, v2UpdateNetworkAreaRegionPayload, 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 v2UpdateNetworkAreaRegionPayload 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 @@ -24126,35 +30766,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 v2UpdateNetworkAreaRegionAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull + V2UpdateNetworkAreaRegionPayload v2UpdateNetworkAreaRegionPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateSecurityGroupValidateBeforeCall( - projectId, securityGroupId, updateSecurityGroupPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateNetworkAreaRegionValidateBeforeCall( + organizationId, + areaId, + region, + v2UpdateNetworkAreaRegionPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateServer + * Build call for v2UpdateRouteOfArea * - * @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 v2UpdateRouteOfAreaPayload 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 @@ -24162,7 +30811,7 @@ public okhttp3.Call updateSecurityGroupAsync( * * * - * + * * * * @@ -24170,10 +30819,12 @@ 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. -
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 v2UpdateRouteOfAreaCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull V2UpdateRouteOfAreaPayload v2UpdateRouteOfAreaPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -24189,17 +30840,23 @@ public okhttp3.Call updateServerCall( basePath = null; } - Object localVarPostBody = updateServerPayload; + Object localVarPostBody = v2UpdateRouteOfAreaPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/servers/{serverId}" + "/v2/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(); @@ -24236,47 +30893,64 @@ 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 v2UpdateRouteOfAreaValidateBeforeCall( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull V2UpdateRouteOfAreaPayload v2UpdateRouteOfAreaPayload, 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 v2UpdateRouteOfArea(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 v2UpdateRouteOfArea(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 v2UpdateRouteOfArea(Async)"); + } + + // verify the required parameter 'routeId' is set + if (routeId == null) { + throw new ApiException( + "Missing the required parameter 'routeId' when calling v2UpdateRouteOfArea(Async)"); + } + + // verify the required parameter 'v2UpdateRouteOfAreaPayload' is set + if (v2UpdateRouteOfAreaPayload == null) { + throw new ApiException( + "Missing the required parameter 'v2UpdateRouteOfAreaPayload' when calling v2UpdateRouteOfArea(Async)"); } - return updateServerCall(projectId, serverId, updateServerPayload, _callback); + return v2UpdateRouteOfAreaCall( + organizationId, areaId, region, routeId, v2UpdateRouteOfAreaPayload, _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 v2UpdateRouteOfAreaPayload 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 * * * - * + * * * * @@ -24284,30 +30958,35 @@ 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 v2UpdateRouteOfArea( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull V2UpdateRouteOfAreaPayload v2UpdateRouteOfAreaPayload) throws ApiException { - ApiResponse localVarResp = - updateServerWithHttpInfo(projectId, serverId, updateServerPayload); + ApiResponse localVarResp = + v2UpdateRouteOfAreaWithHttpInfo( + organizationId, areaId, region, routeId, v2UpdateRouteOfAreaPayload); 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 v2UpdateRouteOfAreaPayload 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 * * * - * + * * * * @@ -24315,23 +30994,28 @@ 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 v2UpdateRouteOfAreaWithHttpInfo( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull V2UpdateRouteOfAreaPayload v2UpdateRouteOfAreaPayload) throws ApiException { okhttp3.Call localVarCall = - updateServerValidateBeforeCall(projectId, serverId, updateServerPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateRouteOfAreaValidateBeforeCall( + organizationId, areaId, region, routeId, v2UpdateRouteOfAreaPayload, 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 v2UpdateRouteOfAreaPayload 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 @@ -24340,7 +31024,7 @@ public ApiResponse updateServerWithHttpInfo( * * * - * + * * * * @@ -24348,26 +31032,35 @@ 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 v2UpdateRouteOfAreaAsync( + @javax.annotation.Nonnull UUID organizationId, + @javax.annotation.Nonnull UUID areaId, + @javax.annotation.Nonnull String region, + @javax.annotation.Nonnull UUID routeId, + @javax.annotation.Nonnull V2UpdateRouteOfAreaPayload v2UpdateRouteOfAreaPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateServerValidateBeforeCall(projectId, serverId, updateServerPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateRouteOfAreaValidateBeforeCall( + organizationId, + areaId, + region, + routeId, + v2UpdateRouteOfAreaPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateSnapshot + * Build call for v2UpdateSecurityGroup * * @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 v2UpdateSecurityGroupPayload 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 @@ -24375,7 +31068,7 @@ public okhttp3.Call updateServerAsync( * * * - * + * * * * @@ -24383,10 +31076,11 @@ 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 v2UpdateSecurityGroupCall( @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 V2UpdateSecurityGroupPayload v2UpdateSecurityGroupPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -24402,17 +31096,20 @@ public okhttp3.Call updateSnapshotCall( basePath = null; } - Object localVarPostBody = updateSnapshotPayload; + Object localVarPostBody = v2UpdateSecurityGroupPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/snapshots/{snapshotId}" + "/v2/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(); @@ -24449,47 +31146,56 @@ public okhttp3.Call updateSnapshotCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateSnapshotValidateBeforeCall( + private okhttp3.Call v2UpdateSecurityGroupValidateBeforeCall( @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 V2UpdateSecurityGroupPayload v2UpdateSecurityGroupPayload, 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 v2UpdateSecurityGroup(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 v2UpdateSecurityGroup(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 v2UpdateSecurityGroup(Async)"); } - // verify the required parameter 'updateSnapshotPayload' is set - if (updateSnapshotPayload == null) { + // verify the required parameter 'v2UpdateSecurityGroupPayload' is set + if (v2UpdateSecurityGroupPayload == null) { throw new ApiException( - "Missing the required parameter 'updateSnapshotPayload' when calling updateSnapshot(Async)"); + "Missing the required parameter 'v2UpdateSecurityGroupPayload' when calling v2UpdateSecurityGroup(Async)"); } - return updateSnapshotCall(projectId, snapshotId, updateSnapshotPayload, _callback); + return v2UpdateSecurityGroupCall( + projectId, region, securityGroupId, v2UpdateSecurityGroupPayload, _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 v2UpdateSecurityGroupPayload 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 * * * - * + * * * * @@ -24497,30 +31203,33 @@ 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 v2UpdateSecurityGroup( @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 V2UpdateSecurityGroupPayload v2UpdateSecurityGroupPayload) throws ApiException { - ApiResponse localVarResp = - updateSnapshotWithHttpInfo(projectId, snapshotId, updateSnapshotPayload); + ApiResponse localVarResp = + v2UpdateSecurityGroupWithHttpInfo( + projectId, region, securityGroupId, v2UpdateSecurityGroupPayload); 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 v2UpdateSecurityGroupPayload 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 * * * - * + * * * * @@ -24528,25 +31237,26 @@ 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 v2UpdateSecurityGroupWithHttpInfo( @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 V2UpdateSecurityGroupPayload v2UpdateSecurityGroupPayload) throws ApiException { okhttp3.Call localVarCall = - updateSnapshotValidateBeforeCall( - projectId, snapshotId, updateSnapshotPayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateSecurityGroupValidateBeforeCall( + projectId, region, securityGroupId, v2UpdateSecurityGroupPayload, 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 v2UpdateSecurityGroupPayload 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 @@ -24555,7 +31265,7 @@ public ApiResponse updateSnapshotWithHttpInfo( * * * - * + * * * * @@ -24563,27 +31273,33 @@ 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 v2UpdateSecurityGroupAsync( @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 V2UpdateSecurityGroupPayload v2UpdateSecurityGroupPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateSnapshotValidateBeforeCall( - projectId, snapshotId, updateSnapshotPayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateSecurityGroupValidateBeforeCall( + projectId, + region, + securityGroupId, + v2UpdateSecurityGroupPayload, + _callback); + Type localVarReturnType = new TypeToken() {}.getType(); localVarApiClient.executeAsync(localVarCall, localVarReturnType, _callback); return localVarCall; } /** - * Build call for updateVolume + * Build call for v2UpdateSnapshot * * @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 v2UpdateSnapshotPayload 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 @@ -24591,7 +31307,7 @@ public okhttp3.Call updateSnapshotAsync( * * * - * + * * * * @@ -24599,10 +31315,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 v2UpdateSnapshotCall( @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 V2UpdateSnapshotPayload v2UpdateSnapshotPayload, final ApiCallback _callback) throws ApiException { String basePath = null; @@ -24618,17 +31335,20 @@ public okhttp3.Call updateVolumeCall( basePath = null; } - Object localVarPostBody = updateVolumePayload; + Object localVarPostBody = v2UpdateSnapshotPayload; // create path and map variables String localVarPath = - "/v1/projects/{projectId}/volumes/{volumeId}" + "/v2/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(); @@ -24665,47 +31385,56 @@ public okhttp3.Call updateVolumeCall( } @SuppressWarnings("rawtypes") - private okhttp3.Call updateVolumeValidateBeforeCall( + private okhttp3.Call v2UpdateSnapshotValidateBeforeCall( @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 V2UpdateSnapshotPayload v2UpdateSnapshotPayload, 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 v2UpdateSnapshot(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 v2UpdateSnapshot(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 v2UpdateSnapshot(Async)"); + } + + // verify the required parameter 'v2UpdateSnapshotPayload' is set + if (v2UpdateSnapshotPayload == null) { + throw new ApiException( + "Missing the required parameter 'v2UpdateSnapshotPayload' when calling v2UpdateSnapshot(Async)"); } - return updateVolumeCall(projectId, volumeId, updateVolumePayload, _callback); + return v2UpdateSnapshotCall( + projectId, region, snapshotId, v2UpdateSnapshotPayload, _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 v2UpdateSnapshotPayload 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 * * * - * + * * * * @@ -24713,30 +31442,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 v2UpdateSnapshot( @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 V2UpdateSnapshotPayload v2UpdateSnapshotPayload) throws ApiException { - ApiResponse localVarResp = - updateVolumeWithHttpInfo(projectId, volumeId, updateVolumePayload); + ApiResponse localVarResp = + v2UpdateSnapshotWithHttpInfo( + projectId, region, snapshotId, v2UpdateSnapshotPayload); 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 v2UpdateSnapshotPayload 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 * * * - * + * * * * @@ -24744,24 +31476,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 v2UpdateSnapshotWithHttpInfo( @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 V2UpdateSnapshotPayload v2UpdateSnapshotPayload) throws ApiException { okhttp3.Call localVarCall = - updateVolumeValidateBeforeCall(projectId, volumeId, updateVolumePayload, null); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateSnapshotValidateBeforeCall( + projectId, region, snapshotId, v2UpdateSnapshotPayload, 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 v2UpdateSnapshotPayload 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 @@ -24770,7 +31505,7 @@ public ApiResponse updateVolumeWithHttpInfo( * * * - * + * * * * @@ -24778,16 +31513,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 v2UpdateSnapshotAsync( @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 V2UpdateSnapshotPayload v2UpdateSnapshotPayload, + final ApiCallback _callback) throws ApiException { okhttp3.Call localVarCall = - updateVolumeValidateBeforeCall(projectId, volumeId, updateVolumePayload, _callback); - Type localVarReturnType = new TypeToken() {}.getType(); + v2UpdateSnapshotValidateBeforeCall( + projectId, region, snapshotId, v2UpdateSnapshotPayload, _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/api/IaasApi.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/api/IaasApi.java index c602505..38df4aa 100644 --- a/services/iaas/src/main/java/cloud/stackit/sdk/iaas/api/IaasApi.java +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/api/IaasApi.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: 2 * 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/AbstractOpenApiSchema.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AbstractOpenApiSchema.java index f24c23e..10540a3 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: 2 * 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..7f4458d --- /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: 2 + * 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..7226bd8 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/AddRoutingTableToAreaPayload.java @@ -0,0 +1,428 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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_DYNAMIC_ROUTES = "dynamicRoutes"; + + @SerializedName(SERIALIZED_NAME_DYNAMIC_ROUTES) + @javax.annotation.Nullable private Boolean dynamicRoutes = true; + + 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; + } + + public AddRoutingTableToAreaPayload dynamicRoutes( + @javax.annotation.Nullable Boolean dynamicRoutes) { + this.dynamicRoutes = dynamicRoutes; + return this; + } + + /** + * A config setting for a routing table which allows propagation of dynamic routes to this + * routing table. + * + * @return dynamicRoutes + */ + @javax.annotation.Nullable public Boolean getDynamicRoutes() { + return dynamicRoutes; + } + + public void setDynamicRoutes(@javax.annotation.Nullable Boolean dynamicRoutes) { + this.dynamicRoutes = dynamicRoutes; + } + + /** + * 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.dynamicRoutes, addRoutingTableToAreaPayload.dynamicRoutes) + && 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, + dynamicRoutes, + 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(" dynamicRoutes: ").append(toIndentedString(dynamicRoutes)).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", + "dynamicRoutes", + "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..4ffe3a1 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: 2 * 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..2706b25 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: 2 * 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..efb1f51 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: 2 * 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..9f683b6 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: 2 * 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..30f87e7 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: 2 * 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..bdde7ee 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: 2 * 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 20a1f0f..1b2eba3 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: 2 * 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/BackupListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BackupListResponse.java index 4ec0e37..20d4795 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: 2 * 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..0b52c03 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: 2 * 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 b140f15..92b98c0 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: 2 * 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/BootVolume.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/BootVolume.java index 6da5095..317bc99 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: 2 * 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..56778fe 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: 2 * 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..7c4ca66 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: 2 * 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 519b557..6fb2c5f 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: 2 * 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/CreateImagePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateImagePayload.java index b065977..a4608e3 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: 2 * 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/CreateKeyPairPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateKeyPairPayload.java index d708081..e237baa 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: 2 * 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/CreateManagementNetworkPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateManagementNetworkPayload.java new file mode 100644 index 0000000..ec6fcba --- /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: 2 + * 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..bae176c --- /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: 2 + * 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 532224c..54eb713 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: 2 * 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; @@ -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..06910cb 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: 2 * 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..53fa2b8 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: 2 * 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..f972bb2 --- /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: 2 + * 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..8724a60 --- /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: 2 + * 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..c40f59b --- /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: 2 + * 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..29d4f56 --- /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: 2 + * 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..c70aa5f --- /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: 2 + * 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..b27a144 --- /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: 2 + * 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 101ffb2..07d2120 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: 2 * 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) { @@ -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 f6ad734..526c954 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: 2 * 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/CreateProtocol.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateProtocol.java index 7af293e..7666e07 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: 2 * 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 f22974b..90ee028 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: 2 * 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 */ 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 e90e150..46e2c39 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: 2 * 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/CreateSecurityGroupRulePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRulePayload.java index 2d36b20..2c5262d 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: 2 * 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/CreateSecurityGroupRuleProtocol.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/CreateSecurityGroupRuleProtocol.java index 73ae90b..883fed6 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: 2 * 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..38cee2f 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: 2 * 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..e463e97 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: 2 * 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 f2b2518..99e4b3f 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: 2 * 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") @@ -119,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"; @@ -422,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; } @@ -432,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; } @@ -729,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")); } /** @@ -838,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..5978f1f --- /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: 2 + * 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 0ccef69..c0d72a0 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: 2 * 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/DestinationCIDRv4.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/DestinationCIDRv4.java new file mode 100644 index 0000000..57069a5 --- /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: 2 + * 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..bb33f04 --- /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: 2 + * 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..b4597e8 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: 2 * 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..022532c 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: 2 * 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..97f1aca 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: 2 * 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 f51617d..aff6804 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: 2 * 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/ImageAgent.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ImageAgent.java index 3ae646a..8d42f42 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: 2 * 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..1ba2c2d 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: 2 * 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..ecec396 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: 2 * 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..51f6ed9 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: 2 * 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..d9853f6 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: 2 * 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..57cd369 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: 2 * 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..e18fbf6 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: 2 * 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..9f218f0 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: 2 * 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 f918230..d32c740 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: 2 * 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/MachineType.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/MachineType.java index e0a0a8a..4bd2bb6 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: 2 * 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..25546df 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: 2 * 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..76054e0 --- /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: 2 + * 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..605d6e9 --- /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: 2 + * 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..5dc2e60 --- /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: 2 + * 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..34deb24 --- /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: 2 + * 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 9742df4..9dc6aa2 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: 2 * 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/NICListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/NICListResponse.java index 3210f01..d711ba1 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: 2 * 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 5ce1955..0222cea 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: 2 * 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) { @@ -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 113b83f..4b40d8d 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: 2 * 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) { @@ -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..05bae07 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: 2 * 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..215a961 --- /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: 2 + * 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..f0840b9 --- /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: 2 + * 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..c433046 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: 2 * 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..40a37d2 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: 2 * 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..afc8425 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: 2 * 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..8b23e04 --- /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: 2 + * 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..30868b7 --- /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: 2 + * 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..cef6c61 --- /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: 2 + * 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..3b98775 --- /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: 2 + * 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 914ef5e..14cb231 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: 2 * 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; @@ -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 2f76594..2abc9f6 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: 2 * 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) { @@ -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..04a471a 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: 2 * 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..f1bf5e3 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: 2 * 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..0896d29 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: 2 * 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..3e372c4 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: 2 * 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 f0ab0d1..1fb5940 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: 2 * 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 */ 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..58d0f29 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: 2 * 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..2fdfcbf 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: 2 * 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..7fd16a8 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: 2 * 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..2a17661 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: 2 * 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..c8ea053 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: 2 * 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..fb70de0 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: 2 * 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..2731e2f --- /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: 2 + * 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..38c4ad9 --- /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: 2 + * 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..8bb01d2 --- /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: 2 + * 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..a35b03b 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: 2 * 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..4880c85 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: 2 * 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..f52238d 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: 2 * 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..fce2f64 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: 2 * 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..3a847cc 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: 2 * 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 cbc4d07..51cf07f 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: 2 * 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; @@ -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..9a7f9c6 --- /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: 2 + * 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..470121c 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: 2 * 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..bf801e9 --- /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: 2 + * 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..e6a9870 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/RoutingTable.java @@ -0,0 +1,420 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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_DYNAMIC_ROUTES = "dynamicRoutes"; + + @SerializedName(SERIALIZED_NAME_DYNAMIC_ROUTES) + @javax.annotation.Nullable private Boolean dynamicRoutes = true; + + 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; + } + + public RoutingTable dynamicRoutes(@javax.annotation.Nullable Boolean dynamicRoutes) { + this.dynamicRoutes = dynamicRoutes; + return this; + } + + /** + * A config setting for a routing table which allows propagation of dynamic routes to this + * routing table. + * + * @return dynamicRoutes + */ + @javax.annotation.Nullable public Boolean getDynamicRoutes() { + return dynamicRoutes; + } + + public void setDynamicRoutes(@javax.annotation.Nullable Boolean dynamicRoutes) { + this.dynamicRoutes = dynamicRoutes; + } + + /** + * 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.dynamicRoutes, routingTable.dynamicRoutes) + && 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, + dynamicRoutes, + 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(" dynamicRoutes: ").append(toIndentedString(dynamicRoutes)).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", + "dynamicRoutes", + "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..88fa926 --- /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: 2 + * 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 958ca93..b8e8c21 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: 2 * 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/SecurityGroupListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupListResponse.java index 1092c53..2e6c8cd 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: 2 * 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 562f0dc..92f0fec 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: 2 * 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/SecurityGroupRuleListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SecurityGroupRuleListResponse.java index 301149f..7aa4d9c 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: 2 * 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..c5efe71 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: 2 * 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 dec5cf9..c9222ff 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: 2 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). @@ -119,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"; @@ -420,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; } @@ -430,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; } @@ -836,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 index 37d77c6..908afa4 100644 --- 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 @@ -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: 2 * 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/ServerConsoleUrl.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/ServerConsoleUrl.java index fcbc473..782ae09 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: 2 * 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..936eb90 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: 2 * 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..9c8b400 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: 2 * 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..17494d7 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: 2 * 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..a83c6eb --- /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: 2 + * 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..ae27dd7 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: 2 * 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..0f6fd30 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: 2 * 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 ec58bc1..01a2829 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: 2 * 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/SnapshotListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/SnapshotListResponse.java index de4ca5e..28f0973 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: 2 * 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..89cdf49 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: 2 * 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..3eed8ce 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: 2 * 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 1cd1c2f..e2cef2b 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: 2 * 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/UpdateImageSharePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateImageSharePayload.java index 54f1c34..1cc3dcf 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: 2 * 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 d287e09..402e641 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: 2 * 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/UpdateManagementNetworkRoutePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateManagementNetworkRoutePayload.java new file mode 100644 index 0000000..462ab71 --- /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: 2 + * 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..ec9985e 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: 2 * 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..f88e46d 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: 2 * 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 d0f7ff5..c5469c5 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: 2 * 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/UpdatePublicIPPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdatePublicIPPayload.java index 96523e1..9c13a37 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: 2 * 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 */ 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..ca0cc55 --- /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: 2 + * 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..70808c5 --- /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: 2 + * 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..7b277df --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateRoutingTableOfAreaPayload.java @@ -0,0 +1,292 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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_DYNAMIC_ROUTES = "dynamicRoutes"; + + @SerializedName(SERIALIZED_NAME_DYNAMIC_ROUTES) + @javax.annotation.Nullable private Boolean dynamicRoutes = true; + + 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 dynamicRoutes( + @javax.annotation.Nullable Boolean dynamicRoutes) { + this.dynamicRoutes = dynamicRoutes; + return this; + } + + /** + * A config setting for a routing table which allows propagation of dynamic routes to this + * routing table. + * + * @return dynamicRoutes + */ + @javax.annotation.Nullable public Boolean getDynamicRoutes() { + return dynamicRoutes; + } + + public void setDynamicRoutes(@javax.annotation.Nullable Boolean dynamicRoutes) { + this.dynamicRoutes = dynamicRoutes; + } + + 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.dynamicRoutes, updateRoutingTableOfAreaPayload.dynamicRoutes) + && Objects.equals(this.labels, updateRoutingTableOfAreaPayload.labels) + && Objects.equals(this.name, updateRoutingTableOfAreaPayload.name); + } + + @Override + public int hashCode() { + return Objects.hash(description, dynamicRoutes, 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(" dynamicRoutes: ").append(toIndentedString(dynamicRoutes)).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", "dynamicRoutes", "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 5e519ab..3094e37 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: 2 * 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/UpdateVolumePayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/UpdateVolumePayload.java index ca3ee76..21b64b0 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: 2 * 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/V2ConfigureNetworkAreaRegionPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2ConfigureNetworkAreaRegionPayload.java new file mode 100644 index 0000000..2883970 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2ConfigureNetworkAreaRegionPayload.java @@ -0,0 +1,232 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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 V2ConfigureNetworkAreaRegionPayload { + 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 V2ConfigureNetworkAreaRegionPayload() {} + + public V2ConfigureNetworkAreaRegionPayload(String status) { + this(); + this.status = status; + } + + public V2ConfigureNetworkAreaRegionPayload 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; + } + V2ConfigureNetworkAreaRegionPayload v2ConfigureNetworkAreaRegionPayload = + (V2ConfigureNetworkAreaRegionPayload) o; + return Objects.equals(this.ipv4, v2ConfigureNetworkAreaRegionPayload.ipv4) + && Objects.equals(this.status, v2ConfigureNetworkAreaRegionPayload.status); + } + + @Override + public int hashCode() { + return Objects.hash(ipv4, status); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2ConfigureNetworkAreaRegionPayload {\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 + * V2ConfigureNetworkAreaRegionPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2ConfigureNetworkAreaRegionPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2ConfigureNetworkAreaRegionPayload is not found in the empty JSON string", + V2ConfigureNetworkAreaRegionPayload.openapiRequiredFields + .toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2ConfigureNetworkAreaRegionPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2ConfigureNetworkAreaRegionPayload` 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 (!V2ConfigureNetworkAreaRegionPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2ConfigureNetworkAreaRegionPayload' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2ConfigureNetworkAreaRegionPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2ConfigureNetworkAreaRegionPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2ConfigureNetworkAreaRegionPayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2ConfigureNetworkAreaRegionPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2ConfigureNetworkAreaRegionPayload + * @throws IOException if the JSON string is invalid with respect to + * V2ConfigureNetworkAreaRegionPayload + */ + public static V2ConfigureNetworkAreaRegionPayload fromJson(String jsonString) + throws IOException { + return JSON.getGson().fromJson(jsonString, V2ConfigureNetworkAreaRegionPayload.class); + } + + /** + * Convert an instance of V2ConfigureNetworkAreaRegionPayload 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/V2CreateSnapshotPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2CreateSnapshotPayload.java new file mode 100644 index 0000000..8716aaf --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2CreateSnapshotPayload.java @@ -0,0 +1,386 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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 V2CreateSnapshotPayload { + 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 V2CreateSnapshotPayload() {} + + public V2CreateSnapshotPayload( + 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 V2CreateSnapshotPayload 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 V2CreateSnapshotPayload 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 V2CreateSnapshotPayload 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; + } + V2CreateSnapshotPayload v2CreateSnapshotPayload = (V2CreateSnapshotPayload) o; + return Objects.equals(this.createdAt, v2CreateSnapshotPayload.createdAt) + && Objects.equals(this.id, v2CreateSnapshotPayload.id) + && Objects.equals(this.labels, v2CreateSnapshotPayload.labels) + && Objects.equals(this.name, v2CreateSnapshotPayload.name) + && Objects.equals(this.size, v2CreateSnapshotPayload.size) + && Objects.equals(this.status, v2CreateSnapshotPayload.status) + && Objects.equals(this.updatedAt, v2CreateSnapshotPayload.updatedAt) + && Objects.equals(this.volumeId, v2CreateSnapshotPayload.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 V2CreateSnapshotPayload {\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 V2CreateSnapshotPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2CreateSnapshotPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2CreateSnapshotPayload is not found in the empty JSON string", + V2CreateSnapshotPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2CreateSnapshotPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2CreateSnapshotPayload` properties. JSON: %s", + entry.getKey(), jsonElement.toString())); + } + } + + // check to make sure all required properties/fields are present in the JSON string + for (String requiredField : V2CreateSnapshotPayload.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 (!V2CreateSnapshotPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2CreateSnapshotPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(V2CreateSnapshotPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2CreateSnapshotPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2CreateSnapshotPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2CreateSnapshotPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2CreateSnapshotPayload + * @throws IOException if the JSON string is invalid with respect to V2CreateSnapshotPayload + */ + public static V2CreateSnapshotPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2CreateSnapshotPayload.class); + } + + /** + * Convert an instance of V2CreateSnapshotPayload 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/V2UpdateBackupPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateBackupPayload.java new file mode 100644 index 0000000..b95055e --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateBackupPayload.java @@ -0,0 +1,433 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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 V2UpdateBackupPayload { + 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 V2UpdateBackupPayload() {} + + public V2UpdateBackupPayload( + 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 V2UpdateBackupPayload 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 V2UpdateBackupPayload 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; + } + V2UpdateBackupPayload v2UpdateBackupPayload = (V2UpdateBackupPayload) o; + return Objects.equals(this.availabilityZone, v2UpdateBackupPayload.availabilityZone) + && Objects.equals(this.createdAt, v2UpdateBackupPayload.createdAt) + && Objects.equals(this.id, v2UpdateBackupPayload.id) + && Objects.equals(this.labels, v2UpdateBackupPayload.labels) + && Objects.equals(this.name, v2UpdateBackupPayload.name) + && Objects.equals(this.size, v2UpdateBackupPayload.size) + && Objects.equals(this.snapshotId, v2UpdateBackupPayload.snapshotId) + && Objects.equals(this.status, v2UpdateBackupPayload.status) + && Objects.equals(this.updatedAt, v2UpdateBackupPayload.updatedAt) + && Objects.equals(this.volumeId, v2UpdateBackupPayload.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 V2UpdateBackupPayload {\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 V2UpdateBackupPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2UpdateBackupPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2UpdateBackupPayload is not found in the empty JSON string", + V2UpdateBackupPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2UpdateBackupPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2UpdateBackupPayload` 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 (!V2UpdateBackupPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2UpdateBackupPayload' and its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(V2UpdateBackupPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2UpdateBackupPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2UpdateBackupPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2UpdateBackupPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2UpdateBackupPayload + * @throws IOException if the JSON string is invalid with respect to V2UpdateBackupPayload + */ + public static V2UpdateBackupPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2UpdateBackupPayload.class); + } + + /** + * Convert an instance of V2UpdateBackupPayload 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/V2UpdateNetworkAreaRegionPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateNetworkAreaRegionPayload.java new file mode 100644 index 0000000..54df4f9 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateNetworkAreaRegionPayload.java @@ -0,0 +1,200 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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 V2UpdateNetworkAreaRegionPayload { + public static final String SERIALIZED_NAME_IPV4 = "ipv4"; + + @SerializedName(SERIALIZED_NAME_IPV4) + @javax.annotation.Nullable private UpdateRegionalAreaIPv4 ipv4; + + public V2UpdateNetworkAreaRegionPayload() {} + + public V2UpdateNetworkAreaRegionPayload 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; + } + V2UpdateNetworkAreaRegionPayload v2UpdateNetworkAreaRegionPayload = + (V2UpdateNetworkAreaRegionPayload) o; + return Objects.equals(this.ipv4, v2UpdateNetworkAreaRegionPayload.ipv4); + } + + @Override + public int hashCode() { + return Objects.hash(ipv4); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2UpdateNetworkAreaRegionPayload {\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 + * V2UpdateNetworkAreaRegionPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2UpdateNetworkAreaRegionPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2UpdateNetworkAreaRegionPayload is not found in the empty JSON string", + V2UpdateNetworkAreaRegionPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2UpdateNetworkAreaRegionPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2UpdateNetworkAreaRegionPayload` 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 (!V2UpdateNetworkAreaRegionPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2UpdateNetworkAreaRegionPayload' and + // its subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2UpdateNetworkAreaRegionPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2UpdateNetworkAreaRegionPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2UpdateNetworkAreaRegionPayload read(JsonReader in) + throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2UpdateNetworkAreaRegionPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2UpdateNetworkAreaRegionPayload + * @throws IOException if the JSON string is invalid with respect to + * V2UpdateNetworkAreaRegionPayload + */ + public static V2UpdateNetworkAreaRegionPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2UpdateNetworkAreaRegionPayload.class); + } + + /** + * Convert an instance of V2UpdateNetworkAreaRegionPayload 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/V2UpdateRouteOfAreaPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateRouteOfAreaPayload.java new file mode 100644 index 0000000..9549e0d --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateRouteOfAreaPayload.java @@ -0,0 +1,193 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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 V2UpdateRouteOfAreaPayload { + public static final String SERIALIZED_NAME_LABELS = "labels"; + + @SerializedName(SERIALIZED_NAME_LABELS) + @javax.annotation.Nullable private Object labels; + + public V2UpdateRouteOfAreaPayload() {} + + public V2UpdateRouteOfAreaPayload 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; + } + V2UpdateRouteOfAreaPayload v2UpdateRouteOfAreaPayload = (V2UpdateRouteOfAreaPayload) o; + return Objects.equals(this.labels, v2UpdateRouteOfAreaPayload.labels); + } + + @Override + public int hashCode() { + return Objects.hash(labels); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2UpdateRouteOfAreaPayload {\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 V2UpdateRouteOfAreaPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2UpdateRouteOfAreaPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2UpdateRouteOfAreaPayload is not found in the empty JSON string", + V2UpdateRouteOfAreaPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2UpdateRouteOfAreaPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2UpdateRouteOfAreaPayload` 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 (!V2UpdateRouteOfAreaPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2UpdateRouteOfAreaPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(V2UpdateRouteOfAreaPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2UpdateRouteOfAreaPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2UpdateRouteOfAreaPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2UpdateRouteOfAreaPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2UpdateRouteOfAreaPayload + * @throws IOException if the JSON string is invalid with respect to V2UpdateRouteOfAreaPayload + */ + public static V2UpdateRouteOfAreaPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2UpdateRouteOfAreaPayload.class); + } + + /** + * Convert an instance of V2UpdateRouteOfAreaPayload 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/V2UpdateSecurityGroupPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateSecurityGroupPayload.java new file mode 100644 index 0000000..9ad7682 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateSecurityGroupPayload.java @@ -0,0 +1,261 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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 V2UpdateSecurityGroupPayload { + 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 V2UpdateSecurityGroupPayload() {} + + public V2UpdateSecurityGroupPayload 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 V2UpdateSecurityGroupPayload 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 V2UpdateSecurityGroupPayload 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; + } + V2UpdateSecurityGroupPayload v2UpdateSecurityGroupPayload = + (V2UpdateSecurityGroupPayload) o; + return Objects.equals(this.description, v2UpdateSecurityGroupPayload.description) + && Objects.equals(this.labels, v2UpdateSecurityGroupPayload.labels) + && Objects.equals(this.name, v2UpdateSecurityGroupPayload.name); + } + + @Override + public int hashCode() { + return Objects.hash(description, labels, name); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2UpdateSecurityGroupPayload {\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 + * V2UpdateSecurityGroupPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2UpdateSecurityGroupPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2UpdateSecurityGroupPayload is not found in the empty JSON string", + V2UpdateSecurityGroupPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2UpdateSecurityGroupPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2UpdateSecurityGroupPayload` 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 (!V2UpdateSecurityGroupPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2UpdateSecurityGroupPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter( + this, TypeToken.get(V2UpdateSecurityGroupPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2UpdateSecurityGroupPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2UpdateSecurityGroupPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2UpdateSecurityGroupPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2UpdateSecurityGroupPayload + * @throws IOException if the JSON string is invalid with respect to + * V2UpdateSecurityGroupPayload + */ + public static V2UpdateSecurityGroupPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2UpdateSecurityGroupPayload.class); + } + + /** + * Convert an instance of V2UpdateSecurityGroupPayload 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/V2UpdateSnapshotPayload.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateSnapshotPayload.java new file mode 100644 index 0000000..7576ba7 --- /dev/null +++ b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/V2UpdateSnapshotPayload.java @@ -0,0 +1,225 @@ +/* + * IaaS-API + * This API allows you to create and modify IaaS resources. + * + * The version of the OpenAPI document: 2 + * 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 V2UpdateSnapshotPayload { + 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 V2UpdateSnapshotPayload() {} + + public V2UpdateSnapshotPayload 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 V2UpdateSnapshotPayload 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; + } + V2UpdateSnapshotPayload v2UpdateSnapshotPayload = (V2UpdateSnapshotPayload) o; + return Objects.equals(this.labels, v2UpdateSnapshotPayload.labels) + && Objects.equals(this.name, v2UpdateSnapshotPayload.name); + } + + @Override + public int hashCode() { + return Objects.hash(labels, name); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("class V2UpdateSnapshotPayload {\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 V2UpdateSnapshotPayload + */ + public static void validateJsonElement(JsonElement jsonElement) throws IOException { + if (jsonElement == null) { + if (!V2UpdateSnapshotPayload.openapiRequiredFields + .isEmpty()) { // has required fields but JSON element is null + throw new IllegalArgumentException( + String.format( + "The required field(s) %s in V2UpdateSnapshotPayload is not found in the empty JSON string", + V2UpdateSnapshotPayload.openapiRequiredFields.toString())); + } + } + + Set> entries = jsonElement.getAsJsonObject().entrySet(); + // check to see if the JSON string contains additional fields + for (Map.Entry entry : entries) { + if (!V2UpdateSnapshotPayload.openapiFields.contains(entry.getKey())) { + throw new IllegalArgumentException( + String.format( + "The field `%s` in the JSON string is not defined in the `V2UpdateSnapshotPayload` 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 (!V2UpdateSnapshotPayload.class.isAssignableFrom(type.getRawType())) { + return null; // this class only serializes 'V2UpdateSnapshotPayload' and its + // subtypes + } + final TypeAdapter elementAdapter = gson.getAdapter(JsonElement.class); + final TypeAdapter thisAdapter = + gson.getDelegateAdapter(this, TypeToken.get(V2UpdateSnapshotPayload.class)); + + return (TypeAdapter) + new TypeAdapter() { + @Override + public void write(JsonWriter out, V2UpdateSnapshotPayload value) + throws IOException { + JsonObject obj = thisAdapter.toJsonTree(value).getAsJsonObject(); + elementAdapter.write(out, obj); + } + + @Override + public V2UpdateSnapshotPayload read(JsonReader in) throws IOException { + JsonElement jsonElement = elementAdapter.read(in); + validateJsonElement(jsonElement); + return thisAdapter.fromJsonTree(jsonElement); + } + }.nullSafe(); + } + } + + /** + * Create an instance of V2UpdateSnapshotPayload given an JSON string + * + * @param jsonString JSON string + * @return An instance of V2UpdateSnapshotPayload + * @throws IOException if the JSON string is invalid with respect to V2UpdateSnapshotPayload + */ + public static V2UpdateSnapshotPayload fromJson(String jsonString) throws IOException { + return JSON.getGson().fromJson(jsonString, V2UpdateSnapshotPayload.class); + } + + /** + * Convert an instance of V2UpdateSnapshotPayload 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 64e0865..a8d61ca 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: 2 * 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/VolumeAttachment.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumeAttachment.java index 7e36ed7..060fd15 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: 2 * 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..df49cce 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: 2 * 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..bc938a7 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: 2 * 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..af7dbb2 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: 2 * 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 055e63c..6182ef5 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: 2 * 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/VolumePerformanceClassListResponse.java b/services/iaas/src/main/java/cloud/stackit/sdk/iaas/model/VolumePerformanceClassListResponse.java index 7edf8c3..b1c9106 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: 2 * 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..b87535a 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: 2 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/test/java/cloud/stackit/sdk/iaas/api/DefaultApiTest.java b/services/iaas/src/test/java/cloud/stackit/sdk/iaas/api/DefaultApiTest.java index 7485ca9..31be2a2 100644 --- a/services/iaas/src/test/java/cloud/stackit/sdk/iaas/api/DefaultApiTest.java +++ b/services/iaas/src/test/java/cloud/stackit/sdk/iaas/api/DefaultApiTest.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: 2 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). diff --git a/services/iaas/src/test/java/cloud/stackit/sdk/iaas/api/IaasApiTest.java b/services/iaas/src/test/java/cloud/stackit/sdk/iaas/api/IaasApiTest.java index 6466b93..b3bf065 100644 --- a/services/iaas/src/test/java/cloud/stackit/sdk/iaas/api/IaasApiTest.java +++ b/services/iaas/src/test/java/cloud/stackit/sdk/iaas/api/IaasApiTest.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: 2 * Contact: stackit-iaas@mail.schwarz * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).