waldur-api-client 7.7.5__py3-none-any.whl → 7.7.6__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of waldur-api-client might be problematic. Click here for more details.

Files changed (122) hide show
  1. waldur_api_client/api/marketplace_offering_users/marketplace_offering_users_checklist_retrieve.py +154 -0
  2. waldur_api_client/api/marketplace_offering_users/marketplace_offering_users_checklist_review_retrieve.py +154 -0
  3. waldur_api_client/api/marketplace_offering_users/marketplace_offering_users_completion_review_status_retrieve.py +154 -0
  4. waldur_api_client/api/marketplace_offering_users/marketplace_offering_users_completion_status_retrieve.py +154 -0
  5. waldur_api_client/api/marketplace_offering_users/marketplace_offering_users_submit_answers.py +179 -0
  6. waldur_api_client/api/marketplace_robot_accounts/marketplace_robot_accounts_list.py +23 -0
  7. waldur_api_client/api/marketplace_robot_accounts/marketplace_robot_accounts_retrieve.py +30 -1
  8. waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_project_service_accounts_list.py +276 -0
  9. waldur_api_client/api/marketplace_service_providers/service_provider_compliance_overview.py +189 -0
  10. waldur_api_client/api/marketplace_service_providers/service_provider_offering_users_compliance.py +222 -0
  11. waldur_api_client/api/public_maintenance_announcements/__init__.py +1 -0
  12. waldur_api_client/api/public_maintenance_announcements/public_maintenance_announcements_count.py +325 -0
  13. waldur_api_client/api/public_maintenance_announcements/public_maintenance_announcements_list.py +328 -0
  14. waldur_api_client/api/public_maintenance_announcements/public_maintenance_announcements_retrieve.py +144 -0
  15. waldur_api_client/models/__init__.py +56 -4
  16. waldur_api_client/models/admin_announcement.py +109 -1
  17. waldur_api_client/models/admin_announcement_maintenance_affected_offerings_item.py +103 -0
  18. waldur_api_client/models/admin_announcements_list_field_item.py +8 -0
  19. waldur_api_client/models/admin_announcements_retrieve_field_item.py +8 -0
  20. waldur_api_client/models/azure_sql_server_create_order_attributes.py +80 -0
  21. waldur_api_client/models/azure_virtual_machine_create_order_attributes.py +96 -0
  22. waldur_api_client/models/basic_user.py +30 -21
  23. waldur_api_client/models/booking_offerings_list_field_item.py +1 -0
  24. waldur_api_client/models/booking_offerings_retrieve_field_item.py +1 -0
  25. waldur_api_client/models/create_router.py +1 -1
  26. waldur_api_client/models/create_router_request.py +1 -1
  27. waldur_api_client/models/customer.py +0 -30
  28. waldur_api_client/models/customers_list_field_item.py +0 -2
  29. waldur_api_client/models/customers_retrieve_field_item.py +0 -2
  30. waldur_api_client/models/fingerprint.py +19 -17
  31. waldur_api_client/models/instance_flavor_change_request.py +1 -1
  32. waldur_api_client/models/marketplace_managed_rancher_create_order_attributes.py +144 -0
  33. waldur_api_client/models/marketplace_provider_offerings_list_customer_service_accounts_retrieve_field_item.py +1 -0
  34. waldur_api_client/models/marketplace_provider_offerings_list_field_item.py +1 -0
  35. waldur_api_client/models/marketplace_provider_offerings_list_project_service_accounts_retrieve_field_item.py +1 -0
  36. waldur_api_client/models/marketplace_provider_offerings_retrieve_field_item.py +1 -0
  37. waldur_api_client/models/marketplace_provider_offerings_stats_retrieve_field_item.py +1 -0
  38. waldur_api_client/models/marketplace_provider_offerings_user_has_resource_access_retrieve_field_item.py +1 -0
  39. waldur_api_client/models/marketplace_public_offerings_list_field_item.py +1 -0
  40. waldur_api_client/models/marketplace_public_offerings_retrieve_field_item.py +1 -0
  41. waldur_api_client/models/marketplace_rancher_create_order_attributes.py +142 -0
  42. waldur_api_client/models/marketplace_robot_accounts_list_field_item.py +32 -0
  43. waldur_api_client/models/marketplace_robot_accounts_retrieve_field_item.py +32 -0
  44. waldur_api_client/models/offering.py +9 -0
  45. waldur_api_client/models/offering_create.py +8 -0
  46. waldur_api_client/models/open_stack_backend_instance.py +2 -2
  47. waldur_api_client/models/open_stack_backend_volumes.py +3 -3
  48. waldur_api_client/models/open_stack_backup.py +1 -1
  49. waldur_api_client/models/open_stack_backup_restoration.py +8 -5
  50. waldur_api_client/models/open_stack_backup_restoration_request.py +28 -3
  51. waldur_api_client/models/open_stack_fixed_ip.py +2 -2
  52. waldur_api_client/models/open_stack_fixed_ip_request.py +2 -2
  53. waldur_api_client/models/open_stack_floating_ip.py +5 -4
  54. waldur_api_client/models/open_stack_instance.py +17 -15
  55. waldur_api_client/models/open_stack_instance_allowed_address_pairs_update_request.py +3 -2
  56. waldur_api_client/models/open_stack_instance_availability_zone.py +1 -1
  57. waldur_api_client/models/open_stack_instance_create_order_attributes.py +280 -0
  58. waldur_api_client/models/open_stack_instance_request.py +4 -3
  59. waldur_api_client/models/open_stack_instance_security_groups_update_request.py +1 -1
  60. waldur_api_client/models/open_stack_nested_floating_ip.py +3 -3
  61. waldur_api_client/models/open_stack_nested_instance.py +1 -1
  62. waldur_api_client/models/open_stack_nested_port.py +5 -5
  63. waldur_api_client/models/open_stack_nested_port_request.py +1 -1
  64. waldur_api_client/models/open_stack_nested_security_group.py +1 -53
  65. waldur_api_client/models/open_stack_nested_security_group_request.py +59 -0
  66. waldur_api_client/models/open_stack_nested_sub_net.py +4 -4
  67. waldur_api_client/models/open_stack_nested_sub_net_request.py +4 -4
  68. waldur_api_client/models/open_stack_nested_volume.py +3 -3
  69. waldur_api_client/models/open_stack_nested_volume_request.py +3 -3
  70. waldur_api_client/models/open_stack_network.py +3 -3
  71. waldur_api_client/models/open_stack_port.py +10 -9
  72. waldur_api_client/models/open_stack_port_ip_update_request.py +2 -2
  73. waldur_api_client/models/open_stack_port_request.py +3 -3
  74. waldur_api_client/models/open_stack_router.py +2 -2
  75. waldur_api_client/models/open_stack_router_interface_request.py +4 -2
  76. waldur_api_client/models/open_stack_security_group_rule_create.py +6 -5
  77. waldur_api_client/models/open_stack_security_group_rule_create_request.py +6 -5
  78. waldur_api_client/models/open_stack_security_group_rule_update_request.py +6 -5
  79. waldur_api_client/models/open_stack_server_group.py +2 -1
  80. waldur_api_client/models/open_stack_server_group_request.py +2 -1
  81. waldur_api_client/models/open_stack_snapshot.py +2 -2
  82. waldur_api_client/models/open_stack_snapshot_restoration.py +1 -1
  83. waldur_api_client/models/open_stack_sub_net.py +5 -5
  84. waldur_api_client/models/open_stack_sub_net_request.py +2 -2
  85. waldur_api_client/models/open_stack_tenant.py +3 -3
  86. waldur_api_client/models/open_stack_tenant_create_order_attributes.py +109 -0
  87. waldur_api_client/models/open_stack_volume.py +9 -9
  88. waldur_api_client/models/open_stack_volume_create_order_attributes.py +152 -0
  89. waldur_api_client/models/open_stack_volume_request.py +1 -1
  90. waldur_api_client/models/order_create_request.py +165 -4
  91. waldur_api_client/models/patched_open_stack_instance_request.py +4 -3
  92. waldur_api_client/models/patched_open_stack_server_group_request.py +2 -1
  93. waldur_api_client/models/patched_open_stack_sub_net_request.py +2 -2
  94. waldur_api_client/models/patched_open_stack_volume_request.py +1 -1
  95. waldur_api_client/models/permission_request.py +2 -2
  96. waldur_api_client/models/provider_offering_details.py +9 -0
  97. waldur_api_client/models/public_maintenance_announcement.py +217 -0
  98. waldur_api_client/models/public_maintenance_announcement_state_enum.py +10 -0
  99. waldur_api_client/models/public_maintenance_announcements_count_o_item.py +15 -0
  100. waldur_api_client/models/public_maintenance_announcements_count_state_item.py +12 -0
  101. waldur_api_client/models/public_maintenance_announcements_list_o_item.py +15 -0
  102. waldur_api_client/models/public_maintenance_announcements_list_state_item.py +12 -0
  103. waldur_api_client/models/public_offering_details.py +9 -0
  104. waldur_api_client/models/rancher_cluster_security_group_rule.py +5 -4
  105. waldur_api_client/models/rancher_cluster_security_group_rule_request.py +5 -4
  106. waldur_api_client/models/remote_project_update_request.py +2 -2
  107. waldur_api_client/models/robot_account_details.py +226 -144
  108. waldur_api_client/models/service_provider_compliance_overview.py +122 -0
  109. waldur_api_client/models/service_provider_offering_user_compliance.py +179 -0
  110. waldur_api_client/models/service_provider_offering_user_compliance_state_enum.py +17 -0
  111. waldur_api_client/models/slurm_invoices_slurm_package_create_order_attributes.py +72 -0
  112. waldur_api_client/models/v_mware_virtual_machine_create_order_attributes.py +225 -0
  113. waldur_api_client/models/v_mware_virtual_machine_create_order_attributes_guest_os_type_1.py +155 -0
  114. waldur_api_client/models/v_mware_virtual_machine_create_order_attributes_guest_os_type_2_type_1.py +155 -0
  115. waldur_api_client/models/v_mware_virtual_machine_create_order_attributes_guest_os_type_3_type_1.py +155 -0
  116. waldur_api_client/models/volume_attach_request.py +1 -1
  117. {waldur_api_client-7.7.5.dist-info → waldur_api_client-7.7.6.dist-info}/METADATA +1 -1
  118. {waldur_api_client-7.7.5.dist-info → waldur_api_client-7.7.6.dist-info}/RECORD +120 -85
  119. waldur_api_client/models/nested_security_group_rule.py +0 -222
  120. waldur_api_client/models/nested_security_group_rule_request.py +0 -187
  121. {waldur_api_client-7.7.5.dist-info → waldur_api_client-7.7.6.dist-info}/LICENSE +0 -0
  122. {waldur_api_client-7.7.5.dist-info → waldur_api_client-7.7.6.dist-info}/WHEEL +0 -0
@@ -0,0 +1,179 @@
1
+ import datetime
2
+ from collections.abc import Mapping
3
+ from typing import Any, TypeVar, Union, cast
4
+ from uuid import UUID
5
+
6
+ from attrs import define as _attrs_define
7
+ from attrs import field as _attrs_field
8
+ from dateutil.parser import isoparse
9
+
10
+ from ..models.service_provider_offering_user_compliance_state_enum import ServiceProviderOfferingUserComplianceStateEnum
11
+
12
+ T = TypeVar("T", bound="ServiceProviderOfferingUserCompliance")
13
+
14
+
15
+ @_attrs_define
16
+ class ServiceProviderOfferingUserCompliance:
17
+ """
18
+ Attributes:
19
+ uuid (UUID):
20
+ user_full_name (str):
21
+ user_email (str):
22
+ offering_name (str):
23
+ checklist_name (Union[None, str]):
24
+ username (Union[None, str]):
25
+ state (ServiceProviderOfferingUserComplianceStateEnum):
26
+ completion_percentage (Union[None, int]):
27
+ compliance_status (str):
28
+ last_updated (Union[None, datetime.datetime]):
29
+ created (datetime.datetime):
30
+ """
31
+
32
+ uuid: UUID
33
+ user_full_name: str
34
+ user_email: str
35
+ offering_name: str
36
+ checklist_name: Union[None, str]
37
+ username: Union[None, str]
38
+ state: ServiceProviderOfferingUserComplianceStateEnum
39
+ completion_percentage: Union[None, int]
40
+ compliance_status: str
41
+ last_updated: Union[None, datetime.datetime]
42
+ created: datetime.datetime
43
+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
44
+
45
+ def to_dict(self) -> dict[str, Any]:
46
+ uuid = str(self.uuid)
47
+
48
+ user_full_name = self.user_full_name
49
+
50
+ user_email = self.user_email
51
+
52
+ offering_name = self.offering_name
53
+
54
+ checklist_name: Union[None, str]
55
+ checklist_name = self.checklist_name
56
+
57
+ username: Union[None, str]
58
+ username = self.username
59
+
60
+ state = self.state.value
61
+
62
+ completion_percentage: Union[None, int]
63
+ completion_percentage = self.completion_percentage
64
+
65
+ compliance_status = self.compliance_status
66
+
67
+ last_updated: Union[None, str]
68
+ if isinstance(self.last_updated, datetime.datetime):
69
+ last_updated = self.last_updated.isoformat()
70
+ else:
71
+ last_updated = self.last_updated
72
+
73
+ created = self.created.isoformat()
74
+
75
+ field_dict: dict[str, Any] = {}
76
+ field_dict.update(self.additional_properties)
77
+ field_dict.update(
78
+ {
79
+ "uuid": uuid,
80
+ "user_full_name": user_full_name,
81
+ "user_email": user_email,
82
+ "offering_name": offering_name,
83
+ "checklist_name": checklist_name,
84
+ "username": username,
85
+ "state": state,
86
+ "completion_percentage": completion_percentage,
87
+ "compliance_status": compliance_status,
88
+ "last_updated": last_updated,
89
+ "created": created,
90
+ }
91
+ )
92
+
93
+ return field_dict
94
+
95
+ @classmethod
96
+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
97
+ d = dict(src_dict)
98
+ uuid = UUID(d.pop("uuid"))
99
+
100
+ user_full_name = d.pop("user_full_name")
101
+
102
+ user_email = d.pop("user_email")
103
+
104
+ offering_name = d.pop("offering_name")
105
+
106
+ def _parse_checklist_name(data: object) -> Union[None, str]:
107
+ if data is None:
108
+ return data
109
+ return cast(Union[None, str], data)
110
+
111
+ checklist_name = _parse_checklist_name(d.pop("checklist_name"))
112
+
113
+ def _parse_username(data: object) -> Union[None, str]:
114
+ if data is None:
115
+ return data
116
+ return cast(Union[None, str], data)
117
+
118
+ username = _parse_username(d.pop("username"))
119
+
120
+ state = ServiceProviderOfferingUserComplianceStateEnum(d.pop("state"))
121
+
122
+ def _parse_completion_percentage(data: object) -> Union[None, int]:
123
+ if data is None:
124
+ return data
125
+ return cast(Union[None, int], data)
126
+
127
+ completion_percentage = _parse_completion_percentage(d.pop("completion_percentage"))
128
+
129
+ compliance_status = d.pop("compliance_status")
130
+
131
+ def _parse_last_updated(data: object) -> Union[None, datetime.datetime]:
132
+ if data is None:
133
+ return data
134
+ try:
135
+ if not isinstance(data, str):
136
+ raise TypeError()
137
+ last_updated_type_0 = isoparse(data)
138
+
139
+ return last_updated_type_0
140
+ except: # noqa: E722
141
+ pass
142
+ return cast(Union[None, datetime.datetime], data)
143
+
144
+ last_updated = _parse_last_updated(d.pop("last_updated"))
145
+
146
+ created = isoparse(d.pop("created"))
147
+
148
+ service_provider_offering_user_compliance = cls(
149
+ uuid=uuid,
150
+ user_full_name=user_full_name,
151
+ user_email=user_email,
152
+ offering_name=offering_name,
153
+ checklist_name=checklist_name,
154
+ username=username,
155
+ state=state,
156
+ completion_percentage=completion_percentage,
157
+ compliance_status=compliance_status,
158
+ last_updated=last_updated,
159
+ created=created,
160
+ )
161
+
162
+ service_provider_offering_user_compliance.additional_properties = d
163
+ return service_provider_offering_user_compliance
164
+
165
+ @property
166
+ def additional_keys(self) -> list[str]:
167
+ return list(self.additional_properties.keys())
168
+
169
+ def __getitem__(self, key: str) -> Any:
170
+ return self.additional_properties[key]
171
+
172
+ def __setitem__(self, key: str, value: Any) -> None:
173
+ self.additional_properties[key] = value
174
+
175
+ def __delitem__(self, key: str) -> None:
176
+ del self.additional_properties[key]
177
+
178
+ def __contains__(self, key: str) -> bool:
179
+ return key in self.additional_properties
@@ -0,0 +1,17 @@
1
+ from enum import IntEnum
2
+
3
+
4
+ class ServiceProviderOfferingUserComplianceStateEnum(IntEnum):
5
+ VALUE_1 = 1
6
+ VALUE_2 = 2
7
+ VALUE_3 = 3
8
+ VALUE_4 = 4
9
+ VALUE_5 = 5
10
+ VALUE_6 = 6
11
+ VALUE_7 = 7
12
+ VALUE_8 = 8
13
+ VALUE_9 = 9
14
+ VALUE_10 = 10
15
+
16
+ def __str__(self) -> str:
17
+ return str(self.value)
@@ -0,0 +1,72 @@
1
+ from collections.abc import Mapping
2
+ from typing import Any, TypeVar, Union
3
+
4
+ from attrs import define as _attrs_define
5
+ from attrs import field as _attrs_field
6
+
7
+ from ..types import UNSET, Unset
8
+
9
+ T = TypeVar("T", bound="SlurmInvoicesSlurmPackageCreateOrderAttributes")
10
+
11
+
12
+ @_attrs_define
13
+ class SlurmInvoicesSlurmPackageCreateOrderAttributes:
14
+ """This mixin allows to specify list of fields to be rendered by serializer.
15
+ It expects that request is available in serializer's context.
16
+
17
+ Attributes:
18
+ name (str):
19
+ description (Union[Unset, str]):
20
+ """
21
+
22
+ name: str
23
+ description: Union[Unset, str] = UNSET
24
+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
25
+
26
+ def to_dict(self) -> dict[str, Any]:
27
+ name = self.name
28
+
29
+ description = self.description
30
+
31
+ field_dict: dict[str, Any] = {}
32
+ field_dict.update(self.additional_properties)
33
+ field_dict.update(
34
+ {
35
+ "name": name,
36
+ }
37
+ )
38
+ if description is not UNSET:
39
+ field_dict["description"] = description
40
+
41
+ return field_dict
42
+
43
+ @classmethod
44
+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
45
+ d = dict(src_dict)
46
+ name = d.pop("name")
47
+
48
+ description = d.pop("description", UNSET)
49
+
50
+ slurm_invoices_slurm_package_create_order_attributes = cls(
51
+ name=name,
52
+ description=description,
53
+ )
54
+
55
+ slurm_invoices_slurm_package_create_order_attributes.additional_properties = d
56
+ return slurm_invoices_slurm_package_create_order_attributes
57
+
58
+ @property
59
+ def additional_keys(self) -> list[str]:
60
+ return list(self.additional_properties.keys())
61
+
62
+ def __getitem__(self, key: str) -> Any:
63
+ return self.additional_properties[key]
64
+
65
+ def __setitem__(self, key: str, value: Any) -> None:
66
+ self.additional_properties[key] = value
67
+
68
+ def __delitem__(self, key: str) -> None:
69
+ del self.additional_properties[key]
70
+
71
+ def __contains__(self, key: str) -> bool:
72
+ return key in self.additional_properties
@@ -0,0 +1,225 @@
1
+ from collections.abc import Mapping
2
+ from typing import Any, TypeVar, Union, cast
3
+
4
+ from attrs import define as _attrs_define
5
+ from attrs import field as _attrs_field
6
+
7
+ from ..models.v_mware_virtual_machine_create_order_attributes_guest_os_type_1 import (
8
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType1,
9
+ )
10
+ from ..models.v_mware_virtual_machine_create_order_attributes_guest_os_type_2_type_1 import (
11
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType2Type1,
12
+ )
13
+ from ..models.v_mware_virtual_machine_create_order_attributes_guest_os_type_3_type_1 import (
14
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType3Type1,
15
+ )
16
+ from ..types import UNSET, Unset
17
+
18
+ T = TypeVar("T", bound="VMwareVirtualMachineCreateOrderAttributes")
19
+
20
+
21
+ @_attrs_define
22
+ class VMwareVirtualMachineCreateOrderAttributes:
23
+ """This mixin allows to specify list of fields to be rendered by serializer.
24
+ It expects that request is available in serializer's context.
25
+
26
+ Attributes:
27
+ name (str):
28
+ description (Union[Unset, str]):
29
+ guest_os (Union[None, Unset, VMwareVirtualMachineCreateOrderAttributesGuestOsType1,
30
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType2Type1,
31
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType3Type1]):
32
+ cores_per_socket (Union[Unset, int]): Number of cores per socket in a VM
33
+ template (Union[None, Unset, str]):
34
+ cluster (Union[None, Unset, str]):
35
+ datastore (Union[None, Unset, str]):
36
+ """
37
+
38
+ name: str
39
+ description: Union[Unset, str] = UNSET
40
+ guest_os: Union[
41
+ None,
42
+ Unset,
43
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType1,
44
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType2Type1,
45
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType3Type1,
46
+ ] = UNSET
47
+ cores_per_socket: Union[Unset, int] = UNSET
48
+ template: Union[None, Unset, str] = UNSET
49
+ cluster: Union[None, Unset, str] = UNSET
50
+ datastore: Union[None, Unset, str] = UNSET
51
+ additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
52
+
53
+ def to_dict(self) -> dict[str, Any]:
54
+ name = self.name
55
+
56
+ description = self.description
57
+
58
+ guest_os: Union[None, Unset, str]
59
+ if isinstance(self.guest_os, Unset):
60
+ guest_os = UNSET
61
+ elif isinstance(self.guest_os, VMwareVirtualMachineCreateOrderAttributesGuestOsType1):
62
+ guest_os = self.guest_os.value
63
+ elif isinstance(self.guest_os, VMwareVirtualMachineCreateOrderAttributesGuestOsType2Type1):
64
+ guest_os = self.guest_os.value
65
+ elif isinstance(self.guest_os, VMwareVirtualMachineCreateOrderAttributesGuestOsType3Type1):
66
+ guest_os = self.guest_os.value
67
+ else:
68
+ guest_os = self.guest_os
69
+
70
+ cores_per_socket = self.cores_per_socket
71
+
72
+ template: Union[None, Unset, str]
73
+ if isinstance(self.template, Unset):
74
+ template = UNSET
75
+ else:
76
+ template = self.template
77
+
78
+ cluster: Union[None, Unset, str]
79
+ if isinstance(self.cluster, Unset):
80
+ cluster = UNSET
81
+ else:
82
+ cluster = self.cluster
83
+
84
+ datastore: Union[None, Unset, str]
85
+ if isinstance(self.datastore, Unset):
86
+ datastore = UNSET
87
+ else:
88
+ datastore = self.datastore
89
+
90
+ field_dict: dict[str, Any] = {}
91
+ field_dict.update(self.additional_properties)
92
+ field_dict.update(
93
+ {
94
+ "name": name,
95
+ }
96
+ )
97
+ if description is not UNSET:
98
+ field_dict["description"] = description
99
+ if guest_os is not UNSET:
100
+ field_dict["guest_os"] = guest_os
101
+ if cores_per_socket is not UNSET:
102
+ field_dict["cores_per_socket"] = cores_per_socket
103
+ if template is not UNSET:
104
+ field_dict["template"] = template
105
+ if cluster is not UNSET:
106
+ field_dict["cluster"] = cluster
107
+ if datastore is not UNSET:
108
+ field_dict["datastore"] = datastore
109
+
110
+ return field_dict
111
+
112
+ @classmethod
113
+ def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
114
+ d = dict(src_dict)
115
+ name = d.pop("name")
116
+
117
+ description = d.pop("description", UNSET)
118
+
119
+ def _parse_guest_os(
120
+ data: object,
121
+ ) -> Union[
122
+ None,
123
+ Unset,
124
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType1,
125
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType2Type1,
126
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType3Type1,
127
+ ]:
128
+ if data is None:
129
+ return data
130
+ if isinstance(data, Unset):
131
+ return data
132
+ try:
133
+ if not isinstance(data, str):
134
+ raise TypeError()
135
+ guest_os_type_1 = VMwareVirtualMachineCreateOrderAttributesGuestOsType1(data)
136
+
137
+ return guest_os_type_1
138
+ except: # noqa: E722
139
+ pass
140
+ try:
141
+ if not isinstance(data, str):
142
+ raise TypeError()
143
+ guest_os_type_2_type_1 = VMwareVirtualMachineCreateOrderAttributesGuestOsType2Type1(data)
144
+
145
+ return guest_os_type_2_type_1
146
+ except: # noqa: E722
147
+ pass
148
+ try:
149
+ if not isinstance(data, str):
150
+ raise TypeError()
151
+ guest_os_type_3_type_1 = VMwareVirtualMachineCreateOrderAttributesGuestOsType3Type1(data)
152
+
153
+ return guest_os_type_3_type_1
154
+ except: # noqa: E722
155
+ pass
156
+ return cast(
157
+ Union[
158
+ None,
159
+ Unset,
160
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType1,
161
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType2Type1,
162
+ VMwareVirtualMachineCreateOrderAttributesGuestOsType3Type1,
163
+ ],
164
+ data,
165
+ )
166
+
167
+ guest_os = _parse_guest_os(d.pop("guest_os", UNSET))
168
+
169
+ cores_per_socket = d.pop("cores_per_socket", UNSET)
170
+
171
+ def _parse_template(data: object) -> Union[None, Unset, str]:
172
+ if data is None:
173
+ return data
174
+ if isinstance(data, Unset):
175
+ return data
176
+ return cast(Union[None, Unset, str], data)
177
+
178
+ template = _parse_template(d.pop("template", UNSET))
179
+
180
+ def _parse_cluster(data: object) -> Union[None, Unset, str]:
181
+ if data is None:
182
+ return data
183
+ if isinstance(data, Unset):
184
+ return data
185
+ return cast(Union[None, Unset, str], data)
186
+
187
+ cluster = _parse_cluster(d.pop("cluster", UNSET))
188
+
189
+ def _parse_datastore(data: object) -> Union[None, Unset, str]:
190
+ if data is None:
191
+ return data
192
+ if isinstance(data, Unset):
193
+ return data
194
+ return cast(Union[None, Unset, str], data)
195
+
196
+ datastore = _parse_datastore(d.pop("datastore", UNSET))
197
+
198
+ v_mware_virtual_machine_create_order_attributes = cls(
199
+ name=name,
200
+ description=description,
201
+ guest_os=guest_os,
202
+ cores_per_socket=cores_per_socket,
203
+ template=template,
204
+ cluster=cluster,
205
+ datastore=datastore,
206
+ )
207
+
208
+ v_mware_virtual_machine_create_order_attributes.additional_properties = d
209
+ return v_mware_virtual_machine_create_order_attributes
210
+
211
+ @property
212
+ def additional_keys(self) -> list[str]:
213
+ return list(self.additional_properties.keys())
214
+
215
+ def __getitem__(self, key: str) -> Any:
216
+ return self.additional_properties[key]
217
+
218
+ def __setitem__(self, key: str, value: Any) -> None:
219
+ self.additional_properties[key] = value
220
+
221
+ def __delitem__(self, key: str) -> None:
222
+ del self.additional_properties[key]
223
+
224
+ def __contains__(self, key: str) -> bool:
225
+ return key in self.additional_properties
@@ -0,0 +1,155 @@
1
+ from enum import Enum
2
+
3
+
4
+ class VMwareVirtualMachineCreateOrderAttributesGuestOsType1(str, Enum):
5
+ ASIANUX_3 = "ASIANUX_3"
6
+ ASIANUX_3_64 = "ASIANUX_3_64"
7
+ ASIANUX_4 = "ASIANUX_4"
8
+ ASIANUX_4_64 = "ASIANUX_4_64"
9
+ ASIANUX_5_64 = "ASIANUX_5_64"
10
+ ASIANUX_7_64 = "ASIANUX_7_64"
11
+ CENTOS = "CENTOS"
12
+ CENTOS_6 = "CENTOS_6"
13
+ CENTOS_64 = "CENTOS_64"
14
+ CENTOS_6_64 = "CENTOS_6_64"
15
+ CENTOS_7 = "CENTOS_7"
16
+ CENTOS_7_64 = "CENTOS_7_64"
17
+ COREOS_64 = "COREOS_64"
18
+ DARWIN = "DARWIN"
19
+ DARWIN_10 = "DARWIN_10"
20
+ DARWIN_10_64 = "DARWIN_10_64"
21
+ DARWIN_11 = "DARWIN_11"
22
+ DARWIN_11_64 = "DARWIN_11_64"
23
+ DARWIN_12_64 = "DARWIN_12_64"
24
+ DARWIN_13_64 = "DARWIN_13_64"
25
+ DARWIN_14_64 = "DARWIN_14_64"
26
+ DARWIN_15_64 = "DARWIN_15_64"
27
+ DARWIN_16_64 = "DARWIN_16_64"
28
+ DARWIN_64 = "DARWIN_64"
29
+ DEBIAN_10 = "DEBIAN_10"
30
+ DEBIAN_10_64 = "DEBIAN_10_64"
31
+ DEBIAN_4 = "DEBIAN_4"
32
+ DEBIAN_4_64 = "DEBIAN_4_64"
33
+ DEBIAN_5 = "DEBIAN_5"
34
+ DEBIAN_5_64 = "DEBIAN_5_64"
35
+ DEBIAN_6 = "DEBIAN_6"
36
+ DEBIAN_6_64 = "DEBIAN_6_64"
37
+ DEBIAN_7 = "DEBIAN_7"
38
+ DEBIAN_7_64 = "DEBIAN_7_64"
39
+ DEBIAN_8 = "DEBIAN_8"
40
+ DEBIAN_8_64 = "DEBIAN_8_64"
41
+ DEBIAN_9 = "DEBIAN_9"
42
+ DEBIAN_9_64 = "DEBIAN_9_64"
43
+ DOS = "DOS"
44
+ ECOMSTATION = "ECOMSTATION"
45
+ ECOMSTATION_2 = "ECOMSTATION_2"
46
+ FEDORA = "FEDORA"
47
+ FEDORA_64 = "FEDORA_64"
48
+ FREEBSD = "FREEBSD"
49
+ FREEBSD_64 = "FREEBSD_64"
50
+ GENERIC_LINUX = "GENERIC_LINUX"
51
+ MANDRAKE = "MANDRAKE"
52
+ MANDRIVA = "MANDRIVA"
53
+ MANDRIVA_64 = "MANDRIVA_64"
54
+ NETWARE_4 = "NETWARE_4"
55
+ NETWARE_5 = "NETWARE_5"
56
+ NETWARE_6 = "NETWARE_6"
57
+ NLD_9 = "NLD_9"
58
+ OES = "OES"
59
+ OPENSERVER_5 = "OPENSERVER_5"
60
+ OPENSERVER_6 = "OPENSERVER_6"
61
+ OPENSUSE = "OPENSUSE"
62
+ OPENSUSE_64 = "OPENSUSE_64"
63
+ ORACLE_LINUX = "ORACLE_LINUX"
64
+ ORACLE_LINUX_6 = "ORACLE_LINUX_6"
65
+ ORACLE_LINUX_64 = "ORACLE_LINUX_64"
66
+ ORACLE_LINUX_6_64 = "ORACLE_LINUX_6_64"
67
+ ORACLE_LINUX_7 = "ORACLE_LINUX_7"
68
+ ORACLE_LINUX_7_64 = "ORACLE_LINUX_7_64"
69
+ OS2 = "OS2"
70
+ OTHER = "OTHER"
71
+ OTHER_24X_LINUX = "OTHER_24X_LINUX"
72
+ OTHER_24X_LINUX_64 = "OTHER_24X_LINUX_64"
73
+ OTHER_26X_LINUX = "OTHER_26X_LINUX"
74
+ OTHER_26X_LINUX_64 = "OTHER_26X_LINUX_64"
75
+ OTHER_3X_LINUX = "OTHER_3X_LINUX"
76
+ OTHER_3X_LINUX_64 = "OTHER_3X_LINUX_64"
77
+ OTHER_64 = "OTHER_64"
78
+ OTHER_LINUX = "OTHER_LINUX"
79
+ OTHER_LINUX_64 = "OTHER_LINUX_64"
80
+ REDHAT = "REDHAT"
81
+ RHEL_2 = "RHEL_2"
82
+ RHEL_3 = "RHEL_3"
83
+ RHEL_3_64 = "RHEL_3_64"
84
+ RHEL_4 = "RHEL_4"
85
+ RHEL_4_64 = "RHEL_4_64"
86
+ RHEL_5 = "RHEL_5"
87
+ RHEL_5_64 = "RHEL_5_64"
88
+ RHEL_6 = "RHEL_6"
89
+ RHEL_6_64 = "RHEL_6_64"
90
+ RHEL_7 = "RHEL_7"
91
+ RHEL_7_64 = "RHEL_7_64"
92
+ SJDS = "SJDS"
93
+ SLES = "SLES"
94
+ SLES_10 = "SLES_10"
95
+ SLES_10_64 = "SLES_10_64"
96
+ SLES_11 = "SLES_11"
97
+ SLES_11_64 = "SLES_11_64"
98
+ SLES_12 = "SLES_12"
99
+ SLES_12_64 = "SLES_12_64"
100
+ SLES_64 = "SLES_64"
101
+ SOLARIS_10 = "SOLARIS_10"
102
+ SOLARIS_10_64 = "SOLARIS_10_64"
103
+ SOLARIS_11_64 = "SOLARIS_11_64"
104
+ SOLARIS_6 = "SOLARIS_6"
105
+ SOLARIS_7 = "SOLARIS_7"
106
+ SOLARIS_8 = "SOLARIS_8"
107
+ SOLARIS_9 = "SOLARIS_9"
108
+ SUSE = "SUSE"
109
+ SUSE_64 = "SUSE_64"
110
+ TURBO_LINUX = "TURBO_LINUX"
111
+ TURBO_LINUX_64 = "TURBO_LINUX_64"
112
+ UBUNTU = "UBUNTU"
113
+ UBUNTU_64 = "UBUNTU_64"
114
+ UNIXWARE_7 = "UNIXWARE_7"
115
+ VMKERNEL = "VMKERNEL"
116
+ VMKERNEL_5 = "VMKERNEL_5"
117
+ VMKERNEL_6 = "VMKERNEL_6"
118
+ VMKERNEL_65 = "VMKERNEL_65"
119
+ VMWARE_PHOTON_64 = "VMWARE_PHOTON_64"
120
+ WINDOWS_7 = "WINDOWS_7"
121
+ WINDOWS_7_64 = "WINDOWS_7_64"
122
+ WINDOWS_7_SERVER_64 = "WINDOWS_7_SERVER_64"
123
+ WINDOWS_8 = "WINDOWS_8"
124
+ WINDOWS_8_64 = "WINDOWS_8_64"
125
+ WINDOWS_8_SERVER_64 = "WINDOWS_8_SERVER_64"
126
+ WINDOWS_9 = "WINDOWS_9"
127
+ WINDOWS_9_64 = "WINDOWS_9_64"
128
+ WINDOWS_9_SERVER_64 = "WINDOWS_9_SERVER_64"
129
+ WINDOWS_HYPERV = "WINDOWS_HYPERV"
130
+ WIN_2000_ADV_SERV = "WIN_2000_ADV_SERV"
131
+ WIN_2000_PRO = "WIN_2000_PRO"
132
+ WIN_2000_SERV = "WIN_2000_SERV"
133
+ WIN_31 = "WIN_31"
134
+ WIN_95 = "WIN_95"
135
+ WIN_98 = "WIN_98"
136
+ WIN_LONGHORN = "WIN_LONGHORN"
137
+ WIN_LONGHORN_64 = "WIN_LONGHORN_64"
138
+ WIN_ME = "WIN_ME"
139
+ WIN_NET_BUSINESS = "WIN_NET_BUSINESS"
140
+ WIN_NET_DATACENTER = "WIN_NET_DATACENTER"
141
+ WIN_NET_DATACENTER_64 = "WIN_NET_DATACENTER_64"
142
+ WIN_NET_ENTERPRISE = "WIN_NET_ENTERPRISE"
143
+ WIN_NET_ENTERPRISE_64 = "WIN_NET_ENTERPRISE_64"
144
+ WIN_NET_STANDARD = "WIN_NET_STANDARD"
145
+ WIN_NET_STANDARD_64 = "WIN_NET_STANDARD_64"
146
+ WIN_NET_WEB = "WIN_NET_WEB"
147
+ WIN_NT = "WIN_NT"
148
+ WIN_VISTA = "WIN_VISTA"
149
+ WIN_VISTA_64 = "WIN_VISTA_64"
150
+ WIN_XP_HOME = "WIN_XP_HOME"
151
+ WIN_XP_PRO = "WIN_XP_PRO"
152
+ WIN_XP_PRO_64 = "WIN_XP_PRO_64"
153
+
154
+ def __str__(self) -> str:
155
+ return str(self.value)