Skip to content

Commit 5064b39

Browse files
Generator: Update SDK /services/iaas (#2093)
* Generate iaas v0.28.0 - **Docs:** Improved descriptions of properties in structs with their possible values - **Feature:** Add `Agent` field to `CreateImagePayload`, `UpdateImagePayload` and `Image` model - **Feature:** Add `Encrypted` and `EncryptionsParameters` fields to `CreateVolumePayload` model --------- Co-authored-by: Marcel Jacek <Marcel.Jacek@stackit.cloud>
1 parent 1b98dda commit 5064b39

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+454
-69
lines changed

CHANGELOG.md

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,13 @@
1818
- **Version**: Minimal version is now python 3.9
1919
- `git`: [v0.4.0](services/git/CHANGELOG.md#v040)
2020
- **Version**: Minimal version is now python 3.9
21-
- `iaas`: [v0.6.0](services/iaas/CHANGELOG.md#v060)
22-
- **Version**: Minimal version is now python 3.9
21+
- `iaas`:
22+
- [v0.7.0](services/iaas/CHANGELOG.md#v070)
23+
- **Docs:** Improved descriptions of properties in structs with their possible values
24+
- **Feature:** Add `Agent` field to `CreateImagePayload`, `UpdateImagePayload` and `Image` model
25+
- **Feature:** Add `Encrypted` and `EncryptionsParameters` fields to `CreateVolumePayload` model
26+
- [v0.6.0](services/iaas/CHANGELOG.md#v060)
27+
- **Version**: Minimal version is now python 3.9
2328
- `intake`: [v0.1.0](services/intake/CHANGELOG.md#v010)
2429
- **New**: STACKIT Intake module can be used to manage the STACKIT Intake. Manage your `IntakeRunners`, `Intakes` and `IntakeUsers`
2530
- `kms`: [v0.1.0](services/kms/CHANGELOG.md#v010)

services/iaas/CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## v0.7.0
2+
- **Docs:** Improved descriptions of properties in structs with their possible values
3+
- **Feature:** Add `Agent` field to `CreateImagePayload`, `UpdateImagePayload` and `Image` model
4+
- **Feature:** Add `Encrypted` and `EncryptionsParameters` fields to `CreateVolumePayload` model
5+
16
## v0.6.0
27
- **Version**: Minimal version is now python 3.9
38

services/iaas/pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ name = "stackit-iaas"
33

44
[tool.poetry]
55
name = "stackit-iaas"
6-
version = "v0.6.0"
6+
version = "v0.7.0"
77
authors = [
88
"STACKIT Developer Tools <developer-tools@stackit.cloud>",
99
]

services/iaas/src/stackit/iaas/__init__.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@
7272
"GetServerLog200Response",
7373
"ICMPParameters",
7474
"Image",
75+
"ImageAgent",
7576
"ImageChecksum",
7677
"ImageConfig",
7778
"ImageCreateResponse",
@@ -144,6 +145,7 @@
144145
"Volume",
145146
"VolumeAttachment",
146147
"VolumeAttachmentListResponse",
148+
"VolumeEncryptionParameter",
147149
"VolumeListResponse",
148150
"VolumePerformanceClass",
149151
"VolumePerformanceClassListResponse",
@@ -268,6 +270,7 @@
268270
)
269271
from stackit.iaas.models.icmp_parameters import ICMPParameters as ICMPParameters
270272
from stackit.iaas.models.image import Image as Image
273+
from stackit.iaas.models.image_agent import ImageAgent as ImageAgent
271274
from stackit.iaas.models.image_checksum import ImageChecksum as ImageChecksum
272275
from stackit.iaas.models.image_config import ImageConfig as ImageConfig
273276
from stackit.iaas.models.image_create_response import (
@@ -426,6 +429,9 @@
426429
from stackit.iaas.models.volume_attachment_list_response import (
427430
VolumeAttachmentListResponse as VolumeAttachmentListResponse,
428431
)
432+
from stackit.iaas.models.volume_encryption_parameter import (
433+
VolumeEncryptionParameter as VolumeEncryptionParameter,
434+
)
429435
from stackit.iaas.models.volume_list_response import (
430436
VolumeListResponse as VolumeListResponse,
431437
)

services/iaas/src/stackit/iaas/models/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,7 @@
7272
from stackit.iaas.models.get_server_log200_response import GetServerLog200Response
7373
from stackit.iaas.models.icmp_parameters import ICMPParameters
7474
from stackit.iaas.models.image import Image
75+
from stackit.iaas.models.image_agent import ImageAgent
7576
from stackit.iaas.models.image_checksum import ImageChecksum
7677
from stackit.iaas.models.image_config import ImageConfig
7778
from stackit.iaas.models.image_create_response import ImageCreateResponse
@@ -158,6 +159,7 @@
158159
from stackit.iaas.models.volume_attachment_list_response import (
159160
VolumeAttachmentListResponse,
160161
)
162+
from stackit.iaas.models.volume_encryption_parameter import VolumeEncryptionParameter
161163
from stackit.iaas.models.volume_list_response import VolumeListResponse
162164
from stackit.iaas.models.volume_performance_class import VolumePerformanceClass
163165
from stackit.iaas.models.volume_performance_class_list_response import (

services/iaas/src/stackit/iaas/models/backup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class Backup(BaseModel):
4040
)
4141
labels: Optional[Dict[str, Any]] = Field(
4242
default=None,
43-
description="Object that represents the labels of an object. Regex for keys: `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: `^(-|_|[a-z0-9]){0,63}$`.",
43+
description="Object that represents the labels of an object. Regex for keys: `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove that key.",
4444
)
4545
name: Optional[Annotated[str, Field(strict=True, max_length=127)]] = Field(
4646
default=None, description="The name for a General Object. Matches Names and also UUIDs."

services/iaas/src/stackit/iaas/models/base_security_group_rule.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,12 @@ class BaseSecurityGroupRule(BaseModel):
3434
description: Optional[Annotated[str, Field(strict=True, max_length=255)]] = Field(
3535
default=None, description="Description Object. Allows string up to 255 Characters."
3636
)
37-
direction: StrictStr = Field(description="The direction of the traffic which the rule should match.")
38-
ethertype: Optional[StrictStr] = Field(default="IPv4", description="The ethertype which the rule should match.")
37+
direction: StrictStr = Field(
38+
description="The direction of the traffic which the rule should match. Possible values: `ingress`, `egress`."
39+
)
40+
ethertype: Optional[StrictStr] = Field(
41+
default="IPv4", description="The ethertype which the rule should match. Possible values: `IPv4`, `IPv6`."
42+
)
3943
icmp_parameters: Optional[ICMPParameters] = Field(default=None, alias="icmpParameters")
4044
id: Optional[Annotated[str, Field(min_length=36, strict=True, max_length=36)]] = Field(
4145
default=None, description="Universally Unique Identifier (UUID)."

services/iaas/src/stackit/iaas/models/create_backup_payload.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class CreateBackupPayload(BaseModel):
3232

3333
labels: Optional[Dict[str, Any]] = Field(
3434
default=None,
35-
description="Object that represents the labels of an object. Regex for keys: `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: `^(-|_|[a-z0-9]){0,63}$`.",
35+
description="Object that represents the labels of an object. Regex for keys: `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove that key.",
3636
)
3737
name: Optional[Annotated[str, Field(strict=True, max_length=127)]] = Field(
3838
default=None, description="The name for a General Object. Matches Names and also UUIDs."

services/iaas/src/stackit/iaas/models/create_image_payload.py

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
)
3232
from typing_extensions import Annotated, Self
3333

34+
from stackit.iaas.models.image_agent import ImageAgent
3435
from stackit.iaas.models.image_checksum import ImageChecksum
3536
from stackit.iaas.models.image_config import ImageConfig
3637

@@ -40,6 +41,7 @@ class CreateImagePayload(BaseModel):
4041
Object that represents an Image and its parameters. Used for Creating and returning (get/list).
4142
""" # noqa: E501
4243

44+
agent: Optional[ImageAgent] = None
4345
checksum: Optional[ImageChecksum] = None
4446
config: Optional[ImageConfig] = None
4547
created_at: Optional[datetime] = Field(
@@ -53,7 +55,7 @@ class CreateImagePayload(BaseModel):
5355
)
5456
labels: Optional[Dict[str, Any]] = Field(
5557
default=None,
56-
description="Object that represents the labels of an object. Regex for keys: `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: `^(-|_|[a-z0-9]){0,63}$`.",
58+
description="Object that represents the labels of an object. Regex for keys: `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove that key.",
5759
)
5860
min_disk_size: Optional[StrictInt] = Field(default=None, description="Size in Gigabyte.", alias="minDiskSize")
5961
min_ram: Optional[StrictInt] = Field(default=None, description="Size in Megabyte.", alias="minRam")
@@ -63,7 +65,9 @@ class CreateImagePayload(BaseModel):
6365
owner: Optional[Annotated[str, Field(min_length=36, strict=True, max_length=36)]] = Field(
6466
default=None, description="Universally Unique Identifier (UUID)."
6567
)
66-
protected: Optional[StrictBool] = None
68+
protected: Optional[StrictBool] = Field(
69+
default=None, description="When true the image is prevented from being deleted."
70+
)
6771
scope: Optional[StrictStr] = Field(
6872
default=None, description="Scope of an Image. Possible values: `public`, `local`, `projects`, `organization`."
6973
)
@@ -76,6 +80,7 @@ class CreateImagePayload(BaseModel):
7680
default=None, description="Date-time when resource was last updated.", alias="updatedAt"
7781
)
7882
__properties: ClassVar[List[str]] = [
83+
"agent",
7984
"checksum",
8085
"config",
8186
"createdAt",
@@ -180,6 +185,9 @@ def to_dict(self) -> Dict[str, Any]:
180185
exclude=excluded_fields,
181186
exclude_none=True,
182187
)
188+
# override the default output from pydantic by calling `to_dict()` of agent
189+
if self.agent:
190+
_dict["agent"] = self.agent.to_dict()
183191
# override the default output from pydantic by calling `to_dict()` of checksum
184192
if self.checksum:
185193
_dict["checksum"] = self.checksum.to_dict()
@@ -199,6 +207,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]:
199207

200208
_obj = cls.model_validate(
201209
{
210+
"agent": ImageAgent.from_dict(obj["agent"]) if obj.get("agent") is not None else None,
202211
"checksum": ImageChecksum.from_dict(obj["checksum"]) if obj.get("checksum") is not None else None,
203212
"config": ImageConfig.from_dict(obj["config"]) if obj.get("config") is not None else None,
204213
"createdAt": obj.get("createdAt"),

services/iaas/src/stackit/iaas/models/create_key_pair_payload.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class CreateKeyPairPayload(BaseModel):
3737
)
3838
labels: Optional[Dict[str, Any]] = Field(
3939
default=None,
40-
description="Object that represents the labels of an object. Regex for keys: `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: `^(-|_|[a-z0-9]){0,63}$`.",
40+
description="Object that represents the labels of an object. Regex for keys: `^[a-z]((-|_|[a-z0-9])){0,62}$`. Regex for values: `^(-|_|[a-z0-9]){0,63}$`. Providing a `null` value for a key will remove that key.",
4141
)
4242
name: Optional[Annotated[str, Field(strict=True, max_length=127)]] = Field(
4343
default=None,

0 commit comments

Comments
 (0)