waldur-api-client 0.2.0__py3-none-any.whl → 7.6.5__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.
- waldur_api_client/api/autoprovisioning_rule_plans/__init__.py +1 -0
- waldur_api_client/api/autoprovisioning_rule_plans/autoprovisioning_rule_plans_create.py +148 -0
- waldur_api_client/api/autoprovisioning_rule_plans/autoprovisioning_rule_plans_destroy.py +89 -0
- waldur_api_client/api/autoprovisioning_rule_plans/autoprovisioning_rule_plans_list.py +169 -0
- waldur_api_client/api/autoprovisioning_rule_plans/autoprovisioning_rule_plans_partial_update.py +162 -0
- waldur_api_client/api/autoprovisioning_rule_plans/autoprovisioning_rule_plans_retrieve.py +140 -0
- waldur_api_client/api/autoprovisioning_rule_plans/autoprovisioning_rule_plans_update.py +162 -0
- waldur_api_client/api/autoprovisioning_rules/__init__.py +1 -0
- waldur_api_client/api/autoprovisioning_rules/autoprovisioning_rules_create.py +148 -0
- waldur_api_client/api/autoprovisioning_rules/autoprovisioning_rules_destroy.py +89 -0
- waldur_api_client/api/autoprovisioning_rules/autoprovisioning_rules_list.py +167 -0
- waldur_api_client/api/autoprovisioning_rules/autoprovisioning_rules_partial_update.py +162 -0
- waldur_api_client/api/autoprovisioning_rules/autoprovisioning_rules_retrieve.py +140 -0
- waldur_api_client/api/autoprovisioning_rules/autoprovisioning_rules_update.py +162 -0
- waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_component_stats_list.py +15 -0
- waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_costs_list.py +15 -0
- waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_customers_list.py +15 -0
- waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_groups_list.py +15 -0
- waldur_api_client/api/marketplace_provider_offerings/marketplace_provider_offerings_list.py +15 -0
- waldur_api_client/api/marketplace_public_offerings/marketplace_public_offerings_list.py +15 -0
- waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_offerings_list.py +15 -0
- waldur_api_client/api/marketplace_service_providers/marketplace_service_providers_users_list.py +15 -0
- waldur_api_client/api/users/users_list.py +15 -0
- waldur_api_client/models/__init__.py +24 -0
- waldur_api_client/models/constance_settings.py +9 -0
- waldur_api_client/models/constance_settings_request.py +9 -0
- waldur_api_client/models/identity_provider.py +11 -11
- waldur_api_client/models/identity_provider_request.py +11 -11
- waldur_api_client/models/merged_plugin_options.py +27 -0
- waldur_api_client/models/merged_plugin_options_request.py +27 -0
- waldur_api_client/models/patched_identity_provider_request.py +11 -11
- waldur_api_client/models/patched_rule_plans_request.py +108 -0
- waldur_api_client/models/patched_rule_plans_request_attributes.py +44 -0
- waldur_api_client/models/patched_rule_plans_request_limits.py +44 -0
- waldur_api_client/models/patched_rule_request.py +101 -0
- waldur_api_client/models/rancher_cluster.py +11 -0
- waldur_api_client/models/rancher_clusters_list_field_item.py +1 -0
- waldur_api_client/models/rancher_clusters_retrieve_field_item.py +1 -0
- waldur_api_client/models/rule.py +128 -0
- waldur_api_client/models/rule_plans.py +126 -0
- waldur_api_client/models/rule_plans_attributes.py +44 -0
- waldur_api_client/models/rule_plans_limits.py +44 -0
- waldur_api_client/models/rule_plans_request.py +109 -0
- waldur_api_client/models/rule_plans_request_attributes.py +44 -0
- waldur_api_client/models/rule_plans_request_limits.py +44 -0
- waldur_api_client/models/rule_request.py +103 -0
- {waldur_api_client-0.2.0.dist-info → waldur_api_client-7.6.5.dist-info}/METADATA +1 -1
- {waldur_api_client-0.2.0.dist-info → waldur_api_client-7.6.5.dist-info}/RECORD +50 -24
- {waldur_api_client-0.2.0.dist-info → waldur_api_client-7.6.5.dist-info}/LICENSE +0 -0
- {waldur_api_client-0.2.0.dist-info → waldur_api_client-7.6.5.dist-info}/WHEEL +0 -0
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import TYPE_CHECKING, 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
|
+
if TYPE_CHECKING:
|
|
10
|
+
from ..models.patched_rule_plans_request_attributes import PatchedRulePlansRequestAttributes
|
|
11
|
+
from ..models.patched_rule_plans_request_limits import PatchedRulePlansRequestLimits
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
T = TypeVar("T", bound="PatchedRulePlansRequest")
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
@_attrs_define
|
|
18
|
+
class PatchedRulePlansRequest:
|
|
19
|
+
"""
|
|
20
|
+
Attributes:
|
|
21
|
+
rule (Union[Unset, str]):
|
|
22
|
+
plan (Union[Unset, str]):
|
|
23
|
+
attributes (Union[Unset, PatchedRulePlansRequestAttributes]):
|
|
24
|
+
limits (Union[Unset, PatchedRulePlansRequestLimits]):
|
|
25
|
+
"""
|
|
26
|
+
|
|
27
|
+
rule: Union[Unset, str] = UNSET
|
|
28
|
+
plan: Union[Unset, str] = UNSET
|
|
29
|
+
attributes: Union[Unset, "PatchedRulePlansRequestAttributes"] = UNSET
|
|
30
|
+
limits: Union[Unset, "PatchedRulePlansRequestLimits"] = UNSET
|
|
31
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
32
|
+
|
|
33
|
+
def to_dict(self) -> dict[str, Any]:
|
|
34
|
+
rule = self.rule
|
|
35
|
+
|
|
36
|
+
plan = self.plan
|
|
37
|
+
|
|
38
|
+
attributes: Union[Unset, dict[str, Any]] = UNSET
|
|
39
|
+
if not isinstance(self.attributes, Unset):
|
|
40
|
+
attributes = self.attributes.to_dict()
|
|
41
|
+
|
|
42
|
+
limits: Union[Unset, dict[str, Any]] = UNSET
|
|
43
|
+
if not isinstance(self.limits, Unset):
|
|
44
|
+
limits = self.limits.to_dict()
|
|
45
|
+
|
|
46
|
+
field_dict: dict[str, Any] = {}
|
|
47
|
+
field_dict.update(self.additional_properties)
|
|
48
|
+
field_dict.update({})
|
|
49
|
+
if rule is not UNSET:
|
|
50
|
+
field_dict["rule"] = rule
|
|
51
|
+
if plan is not UNSET:
|
|
52
|
+
field_dict["plan"] = plan
|
|
53
|
+
if attributes is not UNSET:
|
|
54
|
+
field_dict["attributes"] = attributes
|
|
55
|
+
if limits is not UNSET:
|
|
56
|
+
field_dict["limits"] = limits
|
|
57
|
+
|
|
58
|
+
return field_dict
|
|
59
|
+
|
|
60
|
+
@classmethod
|
|
61
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
62
|
+
from ..models.patched_rule_plans_request_attributes import PatchedRulePlansRequestAttributes
|
|
63
|
+
from ..models.patched_rule_plans_request_limits import PatchedRulePlansRequestLimits
|
|
64
|
+
|
|
65
|
+
d = dict(src_dict)
|
|
66
|
+
rule = d.pop("rule", UNSET)
|
|
67
|
+
|
|
68
|
+
plan = d.pop("plan", UNSET)
|
|
69
|
+
|
|
70
|
+
_attributes = d.pop("attributes", UNSET)
|
|
71
|
+
attributes: Union[Unset, PatchedRulePlansRequestAttributes]
|
|
72
|
+
if isinstance(_attributes, Unset):
|
|
73
|
+
attributes = UNSET
|
|
74
|
+
else:
|
|
75
|
+
attributes = PatchedRulePlansRequestAttributes.from_dict(_attributes)
|
|
76
|
+
|
|
77
|
+
_limits = d.pop("limits", UNSET)
|
|
78
|
+
limits: Union[Unset, PatchedRulePlansRequestLimits]
|
|
79
|
+
if isinstance(_limits, Unset):
|
|
80
|
+
limits = UNSET
|
|
81
|
+
else:
|
|
82
|
+
limits = PatchedRulePlansRequestLimits.from_dict(_limits)
|
|
83
|
+
|
|
84
|
+
patched_rule_plans_request = cls(
|
|
85
|
+
rule=rule,
|
|
86
|
+
plan=plan,
|
|
87
|
+
attributes=attributes,
|
|
88
|
+
limits=limits,
|
|
89
|
+
)
|
|
90
|
+
|
|
91
|
+
patched_rule_plans_request.additional_properties = d
|
|
92
|
+
return patched_rule_plans_request
|
|
93
|
+
|
|
94
|
+
@property
|
|
95
|
+
def additional_keys(self) -> list[str]:
|
|
96
|
+
return list(self.additional_properties.keys())
|
|
97
|
+
|
|
98
|
+
def __getitem__(self, key: str) -> Any:
|
|
99
|
+
return self.additional_properties[key]
|
|
100
|
+
|
|
101
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
102
|
+
self.additional_properties[key] = value
|
|
103
|
+
|
|
104
|
+
def __delitem__(self, key: str) -> None:
|
|
105
|
+
del self.additional_properties[key]
|
|
106
|
+
|
|
107
|
+
def __contains__(self, key: str) -> bool:
|
|
108
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
T = TypeVar("T", bound="PatchedRulePlansRequestAttributes")
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
@_attrs_define
|
|
11
|
+
class PatchedRulePlansRequestAttributes:
|
|
12
|
+
""" """
|
|
13
|
+
|
|
14
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
15
|
+
|
|
16
|
+
def to_dict(self) -> dict[str, Any]:
|
|
17
|
+
field_dict: dict[str, Any] = {}
|
|
18
|
+
field_dict.update(self.additional_properties)
|
|
19
|
+
|
|
20
|
+
return field_dict
|
|
21
|
+
|
|
22
|
+
@classmethod
|
|
23
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
24
|
+
d = dict(src_dict)
|
|
25
|
+
patched_rule_plans_request_attributes = cls()
|
|
26
|
+
|
|
27
|
+
patched_rule_plans_request_attributes.additional_properties = d
|
|
28
|
+
return patched_rule_plans_request_attributes
|
|
29
|
+
|
|
30
|
+
@property
|
|
31
|
+
def additional_keys(self) -> list[str]:
|
|
32
|
+
return list(self.additional_properties.keys())
|
|
33
|
+
|
|
34
|
+
def __getitem__(self, key: str) -> Any:
|
|
35
|
+
return self.additional_properties[key]
|
|
36
|
+
|
|
37
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
38
|
+
self.additional_properties[key] = value
|
|
39
|
+
|
|
40
|
+
def __delitem__(self, key: str) -> None:
|
|
41
|
+
del self.additional_properties[key]
|
|
42
|
+
|
|
43
|
+
def __contains__(self, key: str) -> bool:
|
|
44
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
T = TypeVar("T", bound="PatchedRulePlansRequestLimits")
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
@_attrs_define
|
|
11
|
+
class PatchedRulePlansRequestLimits:
|
|
12
|
+
""" """
|
|
13
|
+
|
|
14
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
15
|
+
|
|
16
|
+
def to_dict(self) -> dict[str, Any]:
|
|
17
|
+
field_dict: dict[str, Any] = {}
|
|
18
|
+
field_dict.update(self.additional_properties)
|
|
19
|
+
|
|
20
|
+
return field_dict
|
|
21
|
+
|
|
22
|
+
@classmethod
|
|
23
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
24
|
+
d = dict(src_dict)
|
|
25
|
+
patched_rule_plans_request_limits = cls()
|
|
26
|
+
|
|
27
|
+
patched_rule_plans_request_limits.additional_properties = d
|
|
28
|
+
return patched_rule_plans_request_limits
|
|
29
|
+
|
|
30
|
+
@property
|
|
31
|
+
def additional_keys(self) -> list[str]:
|
|
32
|
+
return list(self.additional_properties.keys())
|
|
33
|
+
|
|
34
|
+
def __getitem__(self, key: str) -> Any:
|
|
35
|
+
return self.additional_properties[key]
|
|
36
|
+
|
|
37
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
38
|
+
self.additional_properties[key] = value
|
|
39
|
+
|
|
40
|
+
def __delitem__(self, key: str) -> None:
|
|
41
|
+
del self.additional_properties[key]
|
|
42
|
+
|
|
43
|
+
def __contains__(self, key: str) -> bool:
|
|
44
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,101 @@
|
|
|
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 ..types import UNSET, Unset
|
|
8
|
+
|
|
9
|
+
T = TypeVar("T", bound="PatchedRuleRequest")
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
@_attrs_define
|
|
13
|
+
class PatchedRuleRequest:
|
|
14
|
+
"""
|
|
15
|
+
Attributes:
|
|
16
|
+
user_affiliations (Union[Unset, list[str]]):
|
|
17
|
+
user_email_patterns (Union[Unset, list[str]]):
|
|
18
|
+
customer (Union[Unset, str]):
|
|
19
|
+
project_role (Union[None, Unset, str]):
|
|
20
|
+
"""
|
|
21
|
+
|
|
22
|
+
user_affiliations: Union[Unset, list[str]] = UNSET
|
|
23
|
+
user_email_patterns: Union[Unset, list[str]] = UNSET
|
|
24
|
+
customer: Union[Unset, str] = UNSET
|
|
25
|
+
project_role: Union[None, Unset, str] = UNSET
|
|
26
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
27
|
+
|
|
28
|
+
def to_dict(self) -> dict[str, Any]:
|
|
29
|
+
user_affiliations: Union[Unset, list[str]] = UNSET
|
|
30
|
+
if not isinstance(self.user_affiliations, Unset):
|
|
31
|
+
user_affiliations = self.user_affiliations
|
|
32
|
+
|
|
33
|
+
user_email_patterns: Union[Unset, list[str]] = UNSET
|
|
34
|
+
if not isinstance(self.user_email_patterns, Unset):
|
|
35
|
+
user_email_patterns = self.user_email_patterns
|
|
36
|
+
|
|
37
|
+
customer = self.customer
|
|
38
|
+
|
|
39
|
+
project_role: Union[None, Unset, str]
|
|
40
|
+
if isinstance(self.project_role, Unset):
|
|
41
|
+
project_role = UNSET
|
|
42
|
+
else:
|
|
43
|
+
project_role = self.project_role
|
|
44
|
+
|
|
45
|
+
field_dict: dict[str, Any] = {}
|
|
46
|
+
field_dict.update(self.additional_properties)
|
|
47
|
+
field_dict.update({})
|
|
48
|
+
if user_affiliations is not UNSET:
|
|
49
|
+
field_dict["user_affiliations"] = user_affiliations
|
|
50
|
+
if user_email_patterns is not UNSET:
|
|
51
|
+
field_dict["user_email_patterns"] = user_email_patterns
|
|
52
|
+
if customer is not UNSET:
|
|
53
|
+
field_dict["customer"] = customer
|
|
54
|
+
if project_role is not UNSET:
|
|
55
|
+
field_dict["project_role"] = project_role
|
|
56
|
+
|
|
57
|
+
return field_dict
|
|
58
|
+
|
|
59
|
+
@classmethod
|
|
60
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
61
|
+
d = dict(src_dict)
|
|
62
|
+
user_affiliations = cast(list[str], d.pop("user_affiliations", UNSET))
|
|
63
|
+
|
|
64
|
+
user_email_patterns = cast(list[str], d.pop("user_email_patterns", UNSET))
|
|
65
|
+
|
|
66
|
+
customer = d.pop("customer", UNSET)
|
|
67
|
+
|
|
68
|
+
def _parse_project_role(data: object) -> Union[None, Unset, str]:
|
|
69
|
+
if data is None:
|
|
70
|
+
return data
|
|
71
|
+
if isinstance(data, Unset):
|
|
72
|
+
return data
|
|
73
|
+
return cast(Union[None, Unset, str], data)
|
|
74
|
+
|
|
75
|
+
project_role = _parse_project_role(d.pop("project_role", UNSET))
|
|
76
|
+
|
|
77
|
+
patched_rule_request = cls(
|
|
78
|
+
user_affiliations=user_affiliations,
|
|
79
|
+
user_email_patterns=user_email_patterns,
|
|
80
|
+
customer=customer,
|
|
81
|
+
project_role=project_role,
|
|
82
|
+
)
|
|
83
|
+
|
|
84
|
+
patched_rule_request.additional_properties = d
|
|
85
|
+
return patched_rule_request
|
|
86
|
+
|
|
87
|
+
@property
|
|
88
|
+
def additional_keys(self) -> list[str]:
|
|
89
|
+
return list(self.additional_properties.keys())
|
|
90
|
+
|
|
91
|
+
def __getitem__(self, key: str) -> Any:
|
|
92
|
+
return self.additional_properties[key]
|
|
93
|
+
|
|
94
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
95
|
+
self.additional_properties[key] = value
|
|
96
|
+
|
|
97
|
+
def __delitem__(self, key: str) -> None:
|
|
98
|
+
del self.additional_properties[key]
|
|
99
|
+
|
|
100
|
+
def __contains__(self, key: str) -> bool:
|
|
101
|
+
return key in self.additional_properties
|
|
@@ -62,6 +62,7 @@ class RancherCluster:
|
|
|
62
62
|
requested (Union[Unset, Any]): Cluster requested resources in the format {'cpu': '1450m', 'memory': '884Mi',
|
|
63
63
|
'pods': '13'}
|
|
64
64
|
kubernetes_version (Union[Unset, str]): Kubernetes version used in the cluster.
|
|
65
|
+
router_ips (Union[Unset, list[Any]]):
|
|
65
66
|
marketplace_offering_uuid (Union[None, Unset, str]):
|
|
66
67
|
marketplace_offering_name (Union[None, Unset, str]):
|
|
67
68
|
marketplace_offering_plugin_options (Union['RancherClusterMarketplaceOfferingPluginOptionsType0', None, Unset]):
|
|
@@ -109,6 +110,7 @@ class RancherCluster:
|
|
|
109
110
|
capacity: Union[Unset, Any] = UNSET
|
|
110
111
|
requested: Union[Unset, Any] = UNSET
|
|
111
112
|
kubernetes_version: Union[Unset, str] = UNSET
|
|
113
|
+
router_ips: Union[Unset, list[Any]] = UNSET
|
|
112
114
|
marketplace_offering_uuid: Union[None, Unset, str] = UNSET
|
|
113
115
|
marketplace_offering_name: Union[None, Unset, str] = UNSET
|
|
114
116
|
marketplace_offering_plugin_options: Union["RancherClusterMarketplaceOfferingPluginOptionsType0", None, Unset] = (
|
|
@@ -230,6 +232,10 @@ class RancherCluster:
|
|
|
230
232
|
|
|
231
233
|
kubernetes_version = self.kubernetes_version
|
|
232
234
|
|
|
235
|
+
router_ips: Union[Unset, list[Any]] = UNSET
|
|
236
|
+
if not isinstance(self.router_ips, Unset):
|
|
237
|
+
router_ips = self.router_ips
|
|
238
|
+
|
|
233
239
|
marketplace_offering_uuid: Union[None, Unset, str]
|
|
234
240
|
if isinstance(self.marketplace_offering_uuid, Unset):
|
|
235
241
|
marketplace_offering_uuid = UNSET
|
|
@@ -365,6 +371,8 @@ class RancherCluster:
|
|
|
365
371
|
field_dict["requested"] = requested
|
|
366
372
|
if kubernetes_version is not UNSET:
|
|
367
373
|
field_dict["kubernetes_version"] = kubernetes_version
|
|
374
|
+
if router_ips is not UNSET:
|
|
375
|
+
field_dict["router_ips"] = router_ips
|
|
368
376
|
if marketplace_offering_uuid is not UNSET:
|
|
369
377
|
field_dict["marketplace_offering_uuid"] = marketplace_offering_uuid
|
|
370
378
|
if marketplace_offering_name is not UNSET:
|
|
@@ -526,6 +534,8 @@ class RancherCluster:
|
|
|
526
534
|
|
|
527
535
|
kubernetes_version = d.pop("kubernetes_version", UNSET)
|
|
528
536
|
|
|
537
|
+
router_ips = cast(list[Any], d.pop("router_ips", UNSET))
|
|
538
|
+
|
|
529
539
|
def _parse_marketplace_offering_uuid(data: object) -> Union[None, Unset, str]:
|
|
530
540
|
if data is None:
|
|
531
541
|
return data
|
|
@@ -666,6 +676,7 @@ class RancherCluster:
|
|
|
666
676
|
capacity=capacity,
|
|
667
677
|
requested=requested,
|
|
668
678
|
kubernetes_version=kubernetes_version,
|
|
679
|
+
router_ips=router_ips,
|
|
669
680
|
marketplace_offering_uuid=marketplace_offering_uuid,
|
|
670
681
|
marketplace_offering_name=marketplace_offering_name,
|
|
671
682
|
marketplace_offering_plugin_options=marketplace_offering_plugin_options,
|
|
@@ -35,6 +35,7 @@ class RancherClustersListFieldItem(str, Enum):
|
|
|
35
35
|
PUBLIC_IPS = "public_ips"
|
|
36
36
|
REQUESTED = "requested"
|
|
37
37
|
RESOURCE_TYPE = "resource_type"
|
|
38
|
+
ROUTER_IPS = "router_ips"
|
|
38
39
|
RUNTIME_STATE = "runtime_state"
|
|
39
40
|
SECURITY_GROUPS = "security_groups"
|
|
40
41
|
SERVICE_NAME = "service_name"
|
|
@@ -35,6 +35,7 @@ class RancherClustersRetrieveFieldItem(str, Enum):
|
|
|
35
35
|
PUBLIC_IPS = "public_ips"
|
|
36
36
|
REQUESTED = "requested"
|
|
37
37
|
RESOURCE_TYPE = "resource_type"
|
|
38
|
+
ROUTER_IPS = "router_ips"
|
|
38
39
|
RUNTIME_STATE = "runtime_state"
|
|
39
40
|
SECURITY_GROUPS = "security_groups"
|
|
40
41
|
SERVICE_NAME = "service_name"
|
|
@@ -0,0 +1,128 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar, Union, cast
|
|
3
|
+
from uuid import UUID
|
|
4
|
+
|
|
5
|
+
from attrs import define as _attrs_define
|
|
6
|
+
from attrs import field as _attrs_field
|
|
7
|
+
|
|
8
|
+
from ..types import UNSET, Unset
|
|
9
|
+
|
|
10
|
+
T = TypeVar("T", bound="Rule")
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
@_attrs_define
|
|
14
|
+
class Rule:
|
|
15
|
+
"""
|
|
16
|
+
Attributes:
|
|
17
|
+
uuid (UUID):
|
|
18
|
+
url (str):
|
|
19
|
+
customer (str):
|
|
20
|
+
plans (list[str]):
|
|
21
|
+
user_affiliations (Union[Unset, list[str]]):
|
|
22
|
+
user_email_patterns (Union[Unset, list[str]]):
|
|
23
|
+
project_role (Union[None, Unset, str]):
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
uuid: UUID
|
|
27
|
+
url: str
|
|
28
|
+
customer: str
|
|
29
|
+
plans: list[str]
|
|
30
|
+
user_affiliations: Union[Unset, list[str]] = UNSET
|
|
31
|
+
user_email_patterns: Union[Unset, list[str]] = UNSET
|
|
32
|
+
project_role: Union[None, Unset, str] = UNSET
|
|
33
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
34
|
+
|
|
35
|
+
def to_dict(self) -> dict[str, Any]:
|
|
36
|
+
uuid = str(self.uuid)
|
|
37
|
+
|
|
38
|
+
url = self.url
|
|
39
|
+
|
|
40
|
+
customer = self.customer
|
|
41
|
+
|
|
42
|
+
plans = self.plans
|
|
43
|
+
|
|
44
|
+
user_affiliations: Union[Unset, list[str]] = UNSET
|
|
45
|
+
if not isinstance(self.user_affiliations, Unset):
|
|
46
|
+
user_affiliations = self.user_affiliations
|
|
47
|
+
|
|
48
|
+
user_email_patterns: Union[Unset, list[str]] = UNSET
|
|
49
|
+
if not isinstance(self.user_email_patterns, Unset):
|
|
50
|
+
user_email_patterns = self.user_email_patterns
|
|
51
|
+
|
|
52
|
+
project_role: Union[None, Unset, str]
|
|
53
|
+
if isinstance(self.project_role, Unset):
|
|
54
|
+
project_role = UNSET
|
|
55
|
+
else:
|
|
56
|
+
project_role = self.project_role
|
|
57
|
+
|
|
58
|
+
field_dict: dict[str, Any] = {}
|
|
59
|
+
field_dict.update(self.additional_properties)
|
|
60
|
+
field_dict.update(
|
|
61
|
+
{
|
|
62
|
+
"uuid": uuid,
|
|
63
|
+
"url": url,
|
|
64
|
+
"customer": customer,
|
|
65
|
+
"plans": plans,
|
|
66
|
+
}
|
|
67
|
+
)
|
|
68
|
+
if user_affiliations is not UNSET:
|
|
69
|
+
field_dict["user_affiliations"] = user_affiliations
|
|
70
|
+
if user_email_patterns is not UNSET:
|
|
71
|
+
field_dict["user_email_patterns"] = user_email_patterns
|
|
72
|
+
if project_role is not UNSET:
|
|
73
|
+
field_dict["project_role"] = project_role
|
|
74
|
+
|
|
75
|
+
return field_dict
|
|
76
|
+
|
|
77
|
+
@classmethod
|
|
78
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
79
|
+
d = dict(src_dict)
|
|
80
|
+
uuid = UUID(d.pop("uuid"))
|
|
81
|
+
|
|
82
|
+
url = d.pop("url")
|
|
83
|
+
|
|
84
|
+
customer = d.pop("customer")
|
|
85
|
+
|
|
86
|
+
plans = cast(list[str], d.pop("plans"))
|
|
87
|
+
|
|
88
|
+
user_affiliations = cast(list[str], d.pop("user_affiliations", UNSET))
|
|
89
|
+
|
|
90
|
+
user_email_patterns = cast(list[str], d.pop("user_email_patterns", UNSET))
|
|
91
|
+
|
|
92
|
+
def _parse_project_role(data: object) -> Union[None, Unset, str]:
|
|
93
|
+
if data is None:
|
|
94
|
+
return data
|
|
95
|
+
if isinstance(data, Unset):
|
|
96
|
+
return data
|
|
97
|
+
return cast(Union[None, Unset, str], data)
|
|
98
|
+
|
|
99
|
+
project_role = _parse_project_role(d.pop("project_role", UNSET))
|
|
100
|
+
|
|
101
|
+
rule = cls(
|
|
102
|
+
uuid=uuid,
|
|
103
|
+
url=url,
|
|
104
|
+
customer=customer,
|
|
105
|
+
plans=plans,
|
|
106
|
+
user_affiliations=user_affiliations,
|
|
107
|
+
user_email_patterns=user_email_patterns,
|
|
108
|
+
project_role=project_role,
|
|
109
|
+
)
|
|
110
|
+
|
|
111
|
+
rule.additional_properties = d
|
|
112
|
+
return rule
|
|
113
|
+
|
|
114
|
+
@property
|
|
115
|
+
def additional_keys(self) -> list[str]:
|
|
116
|
+
return list(self.additional_properties.keys())
|
|
117
|
+
|
|
118
|
+
def __getitem__(self, key: str) -> Any:
|
|
119
|
+
return self.additional_properties[key]
|
|
120
|
+
|
|
121
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
122
|
+
self.additional_properties[key] = value
|
|
123
|
+
|
|
124
|
+
def __delitem__(self, key: str) -> None:
|
|
125
|
+
del self.additional_properties[key]
|
|
126
|
+
|
|
127
|
+
def __contains__(self, key: str) -> bool:
|
|
128
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import TYPE_CHECKING, Any, TypeVar, Union
|
|
3
|
+
from uuid import UUID
|
|
4
|
+
|
|
5
|
+
from attrs import define as _attrs_define
|
|
6
|
+
from attrs import field as _attrs_field
|
|
7
|
+
|
|
8
|
+
from ..types import UNSET, Unset
|
|
9
|
+
|
|
10
|
+
if TYPE_CHECKING:
|
|
11
|
+
from ..models.rule_plans_attributes import RulePlansAttributes
|
|
12
|
+
from ..models.rule_plans_limits import RulePlansLimits
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
T = TypeVar("T", bound="RulePlans")
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
@_attrs_define
|
|
19
|
+
class RulePlans:
|
|
20
|
+
"""
|
|
21
|
+
Attributes:
|
|
22
|
+
uuid (UUID):
|
|
23
|
+
url (str):
|
|
24
|
+
rule (str):
|
|
25
|
+
plan (str):
|
|
26
|
+
attributes (Union[Unset, RulePlansAttributes]):
|
|
27
|
+
limits (Union[Unset, RulePlansLimits]):
|
|
28
|
+
"""
|
|
29
|
+
|
|
30
|
+
uuid: UUID
|
|
31
|
+
url: str
|
|
32
|
+
rule: str
|
|
33
|
+
plan: str
|
|
34
|
+
attributes: Union[Unset, "RulePlansAttributes"] = UNSET
|
|
35
|
+
limits: Union[Unset, "RulePlansLimits"] = UNSET
|
|
36
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
37
|
+
|
|
38
|
+
def to_dict(self) -> dict[str, Any]:
|
|
39
|
+
uuid = str(self.uuid)
|
|
40
|
+
|
|
41
|
+
url = self.url
|
|
42
|
+
|
|
43
|
+
rule = self.rule
|
|
44
|
+
|
|
45
|
+
plan = self.plan
|
|
46
|
+
|
|
47
|
+
attributes: Union[Unset, dict[str, Any]] = UNSET
|
|
48
|
+
if not isinstance(self.attributes, Unset):
|
|
49
|
+
attributes = self.attributes.to_dict()
|
|
50
|
+
|
|
51
|
+
limits: Union[Unset, dict[str, Any]] = UNSET
|
|
52
|
+
if not isinstance(self.limits, Unset):
|
|
53
|
+
limits = self.limits.to_dict()
|
|
54
|
+
|
|
55
|
+
field_dict: dict[str, Any] = {}
|
|
56
|
+
field_dict.update(self.additional_properties)
|
|
57
|
+
field_dict.update(
|
|
58
|
+
{
|
|
59
|
+
"uuid": uuid,
|
|
60
|
+
"url": url,
|
|
61
|
+
"rule": rule,
|
|
62
|
+
"plan": plan,
|
|
63
|
+
}
|
|
64
|
+
)
|
|
65
|
+
if attributes is not UNSET:
|
|
66
|
+
field_dict["attributes"] = attributes
|
|
67
|
+
if limits is not UNSET:
|
|
68
|
+
field_dict["limits"] = limits
|
|
69
|
+
|
|
70
|
+
return field_dict
|
|
71
|
+
|
|
72
|
+
@classmethod
|
|
73
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
74
|
+
from ..models.rule_plans_attributes import RulePlansAttributes
|
|
75
|
+
from ..models.rule_plans_limits import RulePlansLimits
|
|
76
|
+
|
|
77
|
+
d = dict(src_dict)
|
|
78
|
+
uuid = UUID(d.pop("uuid"))
|
|
79
|
+
|
|
80
|
+
url = d.pop("url")
|
|
81
|
+
|
|
82
|
+
rule = d.pop("rule")
|
|
83
|
+
|
|
84
|
+
plan = d.pop("plan")
|
|
85
|
+
|
|
86
|
+
_attributes = d.pop("attributes", UNSET)
|
|
87
|
+
attributes: Union[Unset, RulePlansAttributes]
|
|
88
|
+
if isinstance(_attributes, Unset):
|
|
89
|
+
attributes = UNSET
|
|
90
|
+
else:
|
|
91
|
+
attributes = RulePlansAttributes.from_dict(_attributes)
|
|
92
|
+
|
|
93
|
+
_limits = d.pop("limits", UNSET)
|
|
94
|
+
limits: Union[Unset, RulePlansLimits]
|
|
95
|
+
if isinstance(_limits, Unset):
|
|
96
|
+
limits = UNSET
|
|
97
|
+
else:
|
|
98
|
+
limits = RulePlansLimits.from_dict(_limits)
|
|
99
|
+
|
|
100
|
+
rule_plans = cls(
|
|
101
|
+
uuid=uuid,
|
|
102
|
+
url=url,
|
|
103
|
+
rule=rule,
|
|
104
|
+
plan=plan,
|
|
105
|
+
attributes=attributes,
|
|
106
|
+
limits=limits,
|
|
107
|
+
)
|
|
108
|
+
|
|
109
|
+
rule_plans.additional_properties = d
|
|
110
|
+
return rule_plans
|
|
111
|
+
|
|
112
|
+
@property
|
|
113
|
+
def additional_keys(self) -> list[str]:
|
|
114
|
+
return list(self.additional_properties.keys())
|
|
115
|
+
|
|
116
|
+
def __getitem__(self, key: str) -> Any:
|
|
117
|
+
return self.additional_properties[key]
|
|
118
|
+
|
|
119
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
120
|
+
self.additional_properties[key] = value
|
|
121
|
+
|
|
122
|
+
def __delitem__(self, key: str) -> None:
|
|
123
|
+
del self.additional_properties[key]
|
|
124
|
+
|
|
125
|
+
def __contains__(self, key: str) -> bool:
|
|
126
|
+
return key in self.additional_properties
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
from collections.abc import Mapping
|
|
2
|
+
from typing import Any, TypeVar
|
|
3
|
+
|
|
4
|
+
from attrs import define as _attrs_define
|
|
5
|
+
from attrs import field as _attrs_field
|
|
6
|
+
|
|
7
|
+
T = TypeVar("T", bound="RulePlansAttributes")
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
@_attrs_define
|
|
11
|
+
class RulePlansAttributes:
|
|
12
|
+
""" """
|
|
13
|
+
|
|
14
|
+
additional_properties: dict[str, Any] = _attrs_field(init=False, factory=dict)
|
|
15
|
+
|
|
16
|
+
def to_dict(self) -> dict[str, Any]:
|
|
17
|
+
field_dict: dict[str, Any] = {}
|
|
18
|
+
field_dict.update(self.additional_properties)
|
|
19
|
+
|
|
20
|
+
return field_dict
|
|
21
|
+
|
|
22
|
+
@classmethod
|
|
23
|
+
def from_dict(cls: type[T], src_dict: Mapping[str, Any]) -> T:
|
|
24
|
+
d = dict(src_dict)
|
|
25
|
+
rule_plans_attributes = cls()
|
|
26
|
+
|
|
27
|
+
rule_plans_attributes.additional_properties = d
|
|
28
|
+
return rule_plans_attributes
|
|
29
|
+
|
|
30
|
+
@property
|
|
31
|
+
def additional_keys(self) -> list[str]:
|
|
32
|
+
return list(self.additional_properties.keys())
|
|
33
|
+
|
|
34
|
+
def __getitem__(self, key: str) -> Any:
|
|
35
|
+
return self.additional_properties[key]
|
|
36
|
+
|
|
37
|
+
def __setitem__(self, key: str, value: Any) -> None:
|
|
38
|
+
self.additional_properties[key] = value
|
|
39
|
+
|
|
40
|
+
def __delitem__(self, key: str) -> None:
|
|
41
|
+
del self.additional_properties[key]
|
|
42
|
+
|
|
43
|
+
def __contains__(self, key: str) -> bool:
|
|
44
|
+
return key in self.additional_properties
|