From 2b15f3a931896cdc670bb4f48be09985b176ff2e Mon Sep 17 00:00:00 2001 From: SDK Generator Bot Date: Tue, 18 Mar 2025 08:09:37 +0000 Subject: [PATCH] Generate loadbalancer --- .../src/stackit/loadbalancer/__init__.py | 5 +- .../stackit/loadbalancer/api/default_api.py | 1289 +++++------------ .../src/stackit/loadbalancer/api_client.py | 2 +- .../src/stackit/loadbalancer/configuration.py | 9 +- .../src/stackit/loadbalancer/exceptions.py | 2 +- .../stackit/loadbalancer/models/__init__.py | 5 +- .../models/active_health_check.py | 8 +- .../models/create_credentials_payload.py | 2 +- .../models/create_credentials_response.py | 2 +- .../models/create_load_balancer_payload.py | 7 +- .../models/credentials_response.py | 6 +- .../models/get_credentials_response.py | 2 +- .../loadbalancer/models/get_quota_response.py | 25 +- .../models/get_service_status_response.py | 103 -- .../models/google_protobuf_any.py | 2 +- .../models/list_credentials_response.py | 2 +- .../models/list_load_balancers_response.py | 2 +- .../models/list_plans_response.py | 2 +- .../stackit/loadbalancer/models/listener.py | 2 +- .../loadbalancer/models/load_balancer.py | 7 +- .../models/load_balancer_error.py | 2 +- .../models/load_balancer_options.py | 2 +- .../loadbalancer_option_access_control.py | 2 +- .../models/loadbalancer_option_logs.py | 2 +- .../models/loadbalancer_option_metrics.py | 2 +- .../loadbalancer_option_observability.py | 2 +- .../stackit/loadbalancer/models/network.py | 2 +- .../loadbalancer/models/options_tcp.py | 2 +- .../loadbalancer/models/options_udp.py | 2 +- .../loadbalancer/models/plan_details.py | 6 +- .../models/server_name_indicator.py | 2 +- .../models/session_persistence.py | 2 +- .../src/stackit/loadbalancer/models/status.py | 2 +- .../src/stackit/loadbalancer/models/target.py | 2 +- .../loadbalancer/models/target_pool.py | 2 +- .../models/update_credentials_payload.py | 2 +- .../models/update_credentials_response.py | 2 +- .../models/update_load_balancer_payload.py | 7 +- .../models/update_target_pool_payload.py | 2 +- .../src/stackit/loadbalancer/rest.py | 2 +- 40 files changed, 463 insertions(+), 1070 deletions(-) delete mode 100644 services/loadbalancer/src/stackit/loadbalancer/models/get_service_status_response.py diff --git a/services/loadbalancer/src/stackit/loadbalancer/__init__.py b/services/loadbalancer/src/stackit/loadbalancer/__init__.py index 0000a4c8..6242eb3f 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/__init__.py +++ b/services/loadbalancer/src/stackit/loadbalancer/__init__.py @@ -7,7 +7,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -46,9 +46,6 @@ from stackit.loadbalancer.models.credentials_response import CredentialsResponse from stackit.loadbalancer.models.get_credentials_response import GetCredentialsResponse from stackit.loadbalancer.models.get_quota_response import GetQuotaResponse -from stackit.loadbalancer.models.get_service_status_response import ( - GetServiceStatusResponse, -) from stackit.loadbalancer.models.google_protobuf_any import GoogleProtobufAny from stackit.loadbalancer.models.list_credentials_response import ( ListCredentialsResponse, diff --git a/services/loadbalancer/src/stackit/loadbalancer/api/default_api.py b/services/loadbalancer/src/stackit/loadbalancer/api/default_api.py index f70e1299..a2bd9ed4 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/api/default_api.py +++ b/services/loadbalancer/src/stackit/loadbalancer/api/default_api.py @@ -5,13 +5,12 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. """ # noqa: E501 docstring might be too long -import warnings from typing import Any, Dict, List, Optional, Tuple, Union from pydantic import Field, StrictFloat, StrictInt, StrictStr, validate_call @@ -31,9 +30,6 @@ ) from stackit.loadbalancer.models.get_credentials_response import GetCredentialsResponse from stackit.loadbalancer.models.get_quota_response import GetQuotaResponse -from stackit.loadbalancer.models.get_service_status_response import ( - GetServiceStatusResponse, -) from stackit.loadbalancer.models.list_credentials_response import ( ListCredentialsResponse, ) @@ -75,8 +71,9 @@ def __init__(self, configuration: Configuration = None) -> None: def create_credentials( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, create_credentials_payload: CreateCredentialsPayload, + x_request_id: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -93,10 +90,12 @@ def create_credentials( :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str :param create_credentials_payload: (required) :type create_credentials_payload: CreateCredentialsPayload + :param x_request_id: + :type x_request_id: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -121,8 +120,9 @@ def create_credentials( _param = self._create_credentials_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, create_credentials_payload=create_credentials_payload, + x_request_id=x_request_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -147,8 +147,9 @@ def create_credentials( def create_credentials_with_http_info( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, create_credentials_payload: CreateCredentialsPayload, + x_request_id: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -165,10 +166,12 @@ def create_credentials_with_http_info( :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str :param create_credentials_payload: (required) :type create_credentials_payload: CreateCredentialsPayload + :param x_request_id: + :type x_request_id: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -193,8 +196,9 @@ def create_credentials_with_http_info( _param = self._create_credentials_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, create_credentials_payload=create_credentials_payload, + x_request_id=x_request_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -219,8 +223,9 @@ def create_credentials_with_http_info( def create_credentials_without_preload_content( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, create_credentials_payload: CreateCredentialsPayload, + x_request_id: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -237,10 +242,12 @@ def create_credentials_without_preload_content( :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str :param create_credentials_payload: (required) :type create_credentials_payload: CreateCredentialsPayload + :param x_request_id: + :type x_request_id: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -265,8 +272,9 @@ def create_credentials_without_preload_content( _param = self._create_credentials_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, create_credentials_payload=create_credentials_payload, + x_request_id=x_request_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -286,8 +294,9 @@ def create_credentials_without_preload_content( def _create_credentials_serialize( self, project_id, - x_request_id, + region, create_credentials_payload, + x_request_id, _request_auth, _content_type, _headers, @@ -308,6 +317,8 @@ def _create_credentials_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region # process the query parameters # process the header parameters if x_request_id is not None: @@ -334,7 +345,7 @@ def _create_credentials_serialize( return self.api_client.param_serialize( method="POST", - resource_path="/v1/projects/{projectId}/credentials", + resource_path="/v2/projects/{projectId}/regions/{region}/credentials", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -351,8 +362,9 @@ def _create_credentials_serialize( def create_load_balancer( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, create_load_balancer_payload: CreateLoadBalancerPayload, + x_request_id: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -369,10 +381,12 @@ def create_load_balancer( :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str :param create_load_balancer_payload: (required) :type create_load_balancer_payload: CreateLoadBalancerPayload + :param x_request_id: + :type x_request_id: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -397,8 +411,9 @@ def create_load_balancer( _param = self._create_load_balancer_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, create_load_balancer_payload=create_load_balancer_payload, + x_request_id=x_request_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -424,8 +439,9 @@ def create_load_balancer( def create_load_balancer_with_http_info( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, create_load_balancer_payload: CreateLoadBalancerPayload, + x_request_id: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -442,10 +458,12 @@ def create_load_balancer_with_http_info( :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str :param create_load_balancer_payload: (required) :type create_load_balancer_payload: CreateLoadBalancerPayload + :param x_request_id: + :type x_request_id: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -470,8 +488,9 @@ def create_load_balancer_with_http_info( _param = self._create_load_balancer_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, create_load_balancer_payload=create_load_balancer_payload, + x_request_id=x_request_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -497,8 +516,9 @@ def create_load_balancer_with_http_info( def create_load_balancer_without_preload_content( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, create_load_balancer_payload: CreateLoadBalancerPayload, + x_request_id: Optional[StrictStr] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -515,10 +535,12 @@ def create_load_balancer_without_preload_content( :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str :param create_load_balancer_payload: (required) :type create_load_balancer_payload: CreateLoadBalancerPayload + :param x_request_id: + :type x_request_id: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -543,8 +565,9 @@ def create_load_balancer_without_preload_content( _param = self._create_load_balancer_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, create_load_balancer_payload=create_load_balancer_payload, + x_request_id=x_request_id, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -565,8 +588,9 @@ def create_load_balancer_without_preload_content( def _create_load_balancer_serialize( self, project_id, - x_request_id, + region, create_load_balancer_payload, + x_request_id, _request_auth, _content_type, _headers, @@ -587,6 +611,8 @@ def _create_load_balancer_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region # process the query parameters # process the header parameters if x_request_id is not None: @@ -613,7 +639,7 @@ def _create_load_balancer_serialize( return self.api_client.param_serialize( method="POST", - resource_path="/v1/projects/{projectId}/load-balancers", + resource_path="/v2/projects/{projectId}/regions/{region}/load-balancers", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -630,6 +656,7 @@ def _create_load_balancer_serialize( def delete_credentials( self, project_id: StrictStr, + region: StrictStr, credentials_ref: StrictStr, _request_timeout: Union[ None, @@ -647,6 +674,8 @@ def delete_credentials( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param credentials_ref: (required) :type credentials_ref: str :param _request_timeout: timeout setting for this request. If one @@ -673,6 +702,7 @@ def delete_credentials( _param = self._delete_credentials_serialize( project_id=project_id, + region=region, credentials_ref=credentials_ref, _request_auth=_request_auth, _content_type=_content_type, @@ -698,6 +728,7 @@ def delete_credentials( def delete_credentials_with_http_info( self, project_id: StrictStr, + region: StrictStr, credentials_ref: StrictStr, _request_timeout: Union[ None, @@ -715,6 +746,8 @@ def delete_credentials_with_http_info( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param credentials_ref: (required) :type credentials_ref: str :param _request_timeout: timeout setting for this request. If one @@ -741,6 +774,7 @@ def delete_credentials_with_http_info( _param = self._delete_credentials_serialize( project_id=project_id, + region=region, credentials_ref=credentials_ref, _request_auth=_request_auth, _content_type=_content_type, @@ -766,6 +800,7 @@ def delete_credentials_with_http_info( def delete_credentials_without_preload_content( self, project_id: StrictStr, + region: StrictStr, credentials_ref: StrictStr, _request_timeout: Union[ None, @@ -783,6 +818,8 @@ def delete_credentials_without_preload_content( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param credentials_ref: (required) :type credentials_ref: str :param _request_timeout: timeout setting for this request. If one @@ -809,6 +846,7 @@ def delete_credentials_without_preload_content( _param = self._delete_credentials_serialize( project_id=project_id, + region=region, credentials_ref=credentials_ref, _request_auth=_request_auth, _content_type=_content_type, @@ -829,6 +867,7 @@ def delete_credentials_without_preload_content( def _delete_credentials_serialize( self, project_id, + region, credentials_ref, _request_auth, _content_type, @@ -850,6 +889,8 @@ def _delete_credentials_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region if credentials_ref is not None: _path_params["credentialsRef"] = credentials_ref # process the query parameters @@ -866,7 +907,7 @@ def _delete_credentials_serialize( return self.api_client.param_serialize( method="DELETE", - resource_path="/v1/projects/{projectId}/credentials/{credentialsRef}", + resource_path="/v2/projects/{projectId}/regions/{region}/credentials/{credentialsRef}", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -883,6 +924,7 @@ def _delete_credentials_serialize( def delete_load_balancer( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, _request_timeout: Union[ None, @@ -900,6 +942,8 @@ def delete_load_balancer( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param _request_timeout: timeout setting for this request. If one @@ -926,6 +970,7 @@ def delete_load_balancer( _param = self._delete_load_balancer_serialize( project_id=project_id, + region=region, name=name, _request_auth=_request_auth, _content_type=_content_type, @@ -951,6 +996,7 @@ def delete_load_balancer( def delete_load_balancer_with_http_info( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, _request_timeout: Union[ None, @@ -968,6 +1014,8 @@ def delete_load_balancer_with_http_info( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param _request_timeout: timeout setting for this request. If one @@ -994,6 +1042,7 @@ def delete_load_balancer_with_http_info( _param = self._delete_load_balancer_serialize( project_id=project_id, + region=region, name=name, _request_auth=_request_auth, _content_type=_content_type, @@ -1019,6 +1068,7 @@ def delete_load_balancer_with_http_info( def delete_load_balancer_without_preload_content( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, _request_timeout: Union[ None, @@ -1036,6 +1086,8 @@ def delete_load_balancer_without_preload_content( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param _request_timeout: timeout setting for this request. If one @@ -1062,6 +1114,7 @@ def delete_load_balancer_without_preload_content( _param = self._delete_load_balancer_serialize( project_id=project_id, + region=region, name=name, _request_auth=_request_auth, _content_type=_content_type, @@ -1082,6 +1135,7 @@ def delete_load_balancer_without_preload_content( def _delete_load_balancer_serialize( self, project_id, + region, name, _request_auth, _content_type, @@ -1103,6 +1157,8 @@ def _delete_load_balancer_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region if name is not None: _path_params["name"] = name # process the query parameters @@ -1119,7 +1175,7 @@ def _delete_load_balancer_serialize( return self.api_client.param_serialize( method="DELETE", - resource_path="/v1/projects/{projectId}/load-balancers/{name}", + resource_path="/v2/projects/{projectId}/regions/{region}/load-balancers/{name}", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -1133,9 +1189,11 @@ def _delete_load_balancer_serialize( ) @validate_call - def disable_service( + def get_credentials( self, project_id: StrictStr, + region: StrictStr, + credentials_ref: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1145,13 +1203,17 @@ def disable_service( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> object: - """(Deprecated) Disables the functionality of load balancers for the project specified. + ) -> GetCredentialsResponse: + """Get a single credential reference in a project. - DEPRECATED! Disabling the load balancer functionality is now automatic. The endpoint is kept for compatibility. Disable will disable the load balancer functionality for the project specified. + Get Credentials :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str + :param credentials_ref: (required) + :type credentials_ref: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1173,10 +1235,11 @@ def disable_service( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 docstring might be too long - warnings.warn("DELETE /v1/projects/{projectId} is deprecated.", DeprecationWarning) - _param = self._disable_service_serialize( + _param = self._get_credentials_serialize( project_id=project_id, + region=region, + credentials_ref=credentials_ref, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1184,10 +1247,11 @@ def disable_service( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "object", + "200": "GetCredentialsResponse", "400": None, "401": "str", "403": None, + "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) @@ -1198,9 +1262,11 @@ def disable_service( ).data @validate_call - def disable_service_with_http_info( + def get_credentials_with_http_info( self, project_id: StrictStr, + region: StrictStr, + credentials_ref: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1210,13 +1276,17 @@ def disable_service_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[object]: - """(Deprecated) Disables the functionality of load balancers for the project specified. + ) -> ApiResponse[GetCredentialsResponse]: + """Get a single credential reference in a project. - DEPRECATED! Disabling the load balancer functionality is now automatic. The endpoint is kept for compatibility. Disable will disable the load balancer functionality for the project specified. + Get Credentials :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str + :param credentials_ref: (required) + :type credentials_ref: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1238,10 +1308,11 @@ def disable_service_with_http_info( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 docstring might be too long - warnings.warn("DELETE /v1/projects/{projectId} is deprecated.", DeprecationWarning) - _param = self._disable_service_serialize( + _param = self._get_credentials_serialize( project_id=project_id, + region=region, + credentials_ref=credentials_ref, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1249,10 +1320,11 @@ def disable_service_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "object", + "200": "GetCredentialsResponse", "400": None, "401": "str", "403": None, + "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) @@ -1263,9 +1335,11 @@ def disable_service_with_http_info( ) @validate_call - def disable_service_without_preload_content( + def get_credentials_without_preload_content( self, project_id: StrictStr, + region: StrictStr, + credentials_ref: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1276,12 +1350,16 @@ def disable_service_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """(Deprecated) Disables the functionality of load balancers for the project specified. + """Get a single credential reference in a project. - DEPRECATED! Disabling the load balancer functionality is now automatic. The endpoint is kept for compatibility. Disable will disable the load balancer functionality for the project specified. + Get Credentials :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str + :param credentials_ref: (required) + :type credentials_ref: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1303,10 +1381,11 @@ def disable_service_without_preload_content( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 docstring might be too long - warnings.warn("DELETE /v1/projects/{projectId} is deprecated.", DeprecationWarning) - _param = self._disable_service_serialize( + _param = self._get_credentials_serialize( project_id=project_id, + region=region, + credentials_ref=credentials_ref, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1314,18 +1393,21 @@ def disable_service_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "object", + "200": "GetCredentialsResponse", "400": None, "401": "str", "403": None, + "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) return response_data.response - def _disable_service_serialize( + def _get_credentials_serialize( self, project_id, + region, + credentials_ref, _request_auth, _content_type, _headers, @@ -1346,6 +1428,10 @@ def _disable_service_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region + if credentials_ref is not None: + _path_params["credentialsRef"] = credentials_ref # process the query parameters # process the header parameters # process the form parameters @@ -1359,8 +1445,8 @@ def _disable_service_serialize( _auth_settings: List[str] = [] return self.api_client.param_serialize( - method="DELETE", - resource_path="/v1/projects/{projectId}", + method="GET", + resource_path="/v2/projects/{projectId}/regions/{region}/credentials/{credentialsRef}", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -1374,10 +1460,11 @@ def _disable_service_serialize( ) @validate_call - def enable_service( + def get_load_balancer( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, + name: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1387,15 +1474,17 @@ def enable_service( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> object: - """(Deprecated) Enables the functionality of load balancers for the project specified. + ) -> LoadBalancer: + """Get a single load balancer in a project. - DEPRECATED! Use CreateLoadBalancer directly instead. Enable will enable the load balancer functionality for the project specified. + Get Load Balancer will get a single load balancer of a project. This contains all the information set during creation or updates. Additionally, it will have information about the state of the load balancer in the form of a status field and error description feedback. :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str + :param name: (required) + :type name: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1417,11 +1506,11 @@ def enable_service( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 docstring might be too long - warnings.warn("POST /v1/projects/{projectId} is deprecated.", DeprecationWarning) - _param = self._enable_service_serialize( + _param = self._get_load_balancer_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, + name=name, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1429,10 +1518,11 @@ def enable_service( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "object", + "200": "LoadBalancer", "400": None, "401": "str", "403": None, + "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) @@ -1443,10 +1533,11 @@ def enable_service( ).data @validate_call - def enable_service_with_http_info( + def get_load_balancer_with_http_info( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, + name: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1456,15 +1547,17 @@ def enable_service_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[object]: - """(Deprecated) Enables the functionality of load balancers for the project specified. + ) -> ApiResponse[LoadBalancer]: + """Get a single load balancer in a project. - DEPRECATED! Use CreateLoadBalancer directly instead. Enable will enable the load balancer functionality for the project specified. + Get Load Balancer will get a single load balancer of a project. This contains all the information set during creation or updates. Additionally, it will have information about the state of the load balancer in the form of a status field and error description feedback. :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str + :param name: (required) + :type name: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1486,11 +1579,11 @@ def enable_service_with_http_info( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 docstring might be too long - warnings.warn("POST /v1/projects/{projectId} is deprecated.", DeprecationWarning) - _param = self._enable_service_serialize( + _param = self._get_load_balancer_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, + name=name, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1498,10 +1591,11 @@ def enable_service_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "object", + "200": "LoadBalancer", "400": None, "401": "str", "403": None, + "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) @@ -1512,10 +1606,11 @@ def enable_service_with_http_info( ) @validate_call - def enable_service_without_preload_content( + def get_load_balancer_without_preload_content( self, project_id: StrictStr, - x_request_id: StrictStr, + region: StrictStr, + name: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1526,14 +1621,16 @@ def enable_service_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """(Deprecated) Enables the functionality of load balancers for the project specified. + """Get a single load balancer in a project. - DEPRECATED! Use CreateLoadBalancer directly instead. Enable will enable the load balancer functionality for the project specified. + Get Load Balancer will get a single load balancer of a project. This contains all the information set during creation or updates. Additionally, it will have information about the state of the load balancer in the form of a status field and error description feedback. :param project_id: (required) :type project_id: str - :param x_request_id: (required) - :type x_request_id: str + :param region: (required) + :type region: str + :param name: (required) + :type name: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1555,11 +1652,11 @@ def enable_service_without_preload_content( :type _host_index: int, optional :return: Returns the result object. """ # noqa: E501 docstring might be too long - warnings.warn("POST /v1/projects/{projectId} is deprecated.", DeprecationWarning) - _param = self._enable_service_serialize( + _param = self._get_load_balancer_serialize( project_id=project_id, - x_request_id=x_request_id, + region=region, + name=name, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1567,19 +1664,21 @@ def enable_service_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "object", + "200": "LoadBalancer", "400": None, "401": "str", "403": None, + "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) return response_data.response - def _enable_service_serialize( + def _get_load_balancer_serialize( self, project_id, - x_request_id, + region, + name, _request_auth, _content_type, _headers, @@ -1600,10 +1699,12 @@ def _enable_service_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region + if name is not None: + _path_params["name"] = name # process the query parameters # process the header parameters - if x_request_id is not None: - _header_params["X-Request-ID"] = x_request_id # process the form parameters # process the body parameter @@ -1615,8 +1716,8 @@ def _enable_service_serialize( _auth_settings: List[str] = [] return self.api_client.param_serialize( - method="POST", - resource_path="/v1/projects/{projectId}", + method="GET", + resource_path="/v2/projects/{projectId}/regions/{region}/load-balancers/{name}", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -1630,10 +1731,10 @@ def _enable_service_serialize( ) @validate_call - def get_credentials( + def get_quota( self, project_id: StrictStr, - credentials_ref: StrictStr, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1643,15 +1744,15 @@ def get_credentials( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetCredentialsResponse: - """Get a single credential reference in a project. + ) -> GetQuotaResponse: + """Get the quota of Load Balancers and Target Pools in a project. - Get Credentials + GetQuota gets the configured load balancer quota for the project. Default is 3. :param project_id: (required) :type project_id: str - :param credentials_ref: (required) - :type credentials_ref: str + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1674,9 +1775,9 @@ def get_credentials( :return: Returns the result object. """ # noqa: E501 docstring might be too long - _param = self._get_credentials_serialize( + _param = self._get_quota_serialize( project_id=project_id, - credentials_ref=credentials_ref, + region=region, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1684,11 +1785,10 @@ def get_credentials( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "GetCredentialsResponse", + "200": "GetQuotaResponse", "400": None, "401": "str", "403": None, - "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) @@ -1699,10 +1799,10 @@ def get_credentials( ).data @validate_call - def get_credentials_with_http_info( + def get_quota_with_http_info( self, project_id: StrictStr, - credentials_ref: StrictStr, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1712,15 +1812,15 @@ def get_credentials_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetCredentialsResponse]: - """Get a single credential reference in a project. + ) -> ApiResponse[GetQuotaResponse]: + """Get the quota of Load Balancers and Target Pools in a project. - Get Credentials + GetQuota gets the configured load balancer quota for the project. Default is 3. :param project_id: (required) :type project_id: str - :param credentials_ref: (required) - :type credentials_ref: str + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1743,9 +1843,9 @@ def get_credentials_with_http_info( :return: Returns the result object. """ # noqa: E501 docstring might be too long - _param = self._get_credentials_serialize( + _param = self._get_quota_serialize( project_id=project_id, - credentials_ref=credentials_ref, + region=region, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1753,11 +1853,10 @@ def get_credentials_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "GetCredentialsResponse", + "200": "GetQuotaResponse", "400": None, "401": "str", "403": None, - "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) @@ -1768,10 +1867,10 @@ def get_credentials_with_http_info( ) @validate_call - def get_credentials_without_preload_content( + def get_quota_without_preload_content( self, project_id: StrictStr, - credentials_ref: StrictStr, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1782,14 +1881,14 @@ def get_credentials_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get a single credential reference in a project. + """Get the quota of Load Balancers and Target Pools in a project. - Get Credentials + GetQuota gets the configured load balancer quota for the project. Default is 3. :param project_id: (required) :type project_id: str - :param credentials_ref: (required) - :type credentials_ref: str + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1812,9 +1911,9 @@ def get_credentials_without_preload_content( :return: Returns the result object. """ # noqa: E501 docstring might be too long - _param = self._get_credentials_serialize( + _param = self._get_quota_serialize( project_id=project_id, - credentials_ref=credentials_ref, + region=region, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1822,20 +1921,19 @@ def get_credentials_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "GetCredentialsResponse", + "200": "GetQuotaResponse", "400": None, "401": "str", "403": None, - "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) return response_data.response - def _get_credentials_serialize( + def _get_quota_serialize( self, project_id, - credentials_ref, + region, _request_auth, _content_type, _headers, @@ -1856,8 +1954,8 @@ def _get_credentials_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id - if credentials_ref is not None: - _path_params["credentialsRef"] = credentials_ref + if region is not None: + _path_params["region"] = region # process the query parameters # process the header parameters # process the form parameters @@ -1872,7 +1970,7 @@ def _get_credentials_serialize( return self.api_client.param_serialize( method="GET", - resource_path="/v1/projects/{projectId}/credentials/{credentialsRef}", + resource_path="/v2/projects/{projectId}/regions/{region}/quota", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -1886,10 +1984,10 @@ def _get_credentials_serialize( ) @validate_call - def get_load_balancer( + def list_credentials( self, project_id: StrictStr, - name: StrictStr, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1899,15 +1997,15 @@ def get_load_balancer( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> LoadBalancer: - """Get a single load balancer in a project. + ) -> ListCredentialsResponse: + """List all credentials in a project. - Get Load Balancer will get a single load balancer of a project. This contains all the information set during creation or updates. Additionally, it will have information about the state of the load balancer in the form of a status field and error description feedback. + List Credentials :param project_id: (required) :type project_id: str - :param name: (required) - :type name: str + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1930,9 +2028,9 @@ def get_load_balancer( :return: Returns the result object. """ # noqa: E501 docstring might be too long - _param = self._get_load_balancer_serialize( + _param = self._list_credentials_serialize( project_id=project_id, - name=name, + region=region, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -1940,11 +2038,10 @@ def get_load_balancer( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "LoadBalancer", + "200": "ListCredentialsResponse", "400": None, "401": "str", "403": None, - "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) @@ -1955,10 +2052,10 @@ def get_load_balancer( ).data @validate_call - def get_load_balancer_with_http_info( + def list_credentials_with_http_info( self, project_id: StrictStr, - name: StrictStr, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -1968,15 +2065,15 @@ def get_load_balancer_with_http_info( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[LoadBalancer]: - """Get a single load balancer in a project. + ) -> ApiResponse[ListCredentialsResponse]: + """List all credentials in a project. - Get Load Balancer will get a single load balancer of a project. This contains all the information set during creation or updates. Additionally, it will have information about the state of the load balancer in the form of a status field and error description feedback. + List Credentials :param project_id: (required) :type project_id: str - :param name: (required) - :type name: str + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -1999,9 +2096,9 @@ def get_load_balancer_with_http_info( :return: Returns the result object. """ # noqa: E501 docstring might be too long - _param = self._get_load_balancer_serialize( + _param = self._list_credentials_serialize( project_id=project_id, - name=name, + region=region, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -2009,11 +2106,10 @@ def get_load_balancer_with_http_info( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "LoadBalancer", + "200": "ListCredentialsResponse", "400": None, "401": "str", "403": None, - "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) @@ -2024,10 +2120,10 @@ def get_load_balancer_with_http_info( ) @validate_call - def get_load_balancer_without_preload_content( + def list_credentials_without_preload_content( self, project_id: StrictStr, - name: StrictStr, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -2038,14 +2134,14 @@ def get_load_balancer_without_preload_content( _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, ) -> RESTResponseType: - """Get a single load balancer in a project. + """List all credentials in a project. - Get Load Balancer will get a single load balancer of a project. This contains all the information set during creation or updates. Additionally, it will have information about the state of the load balancer in the form of a status field and error description feedback. + List Credentials :param project_id: (required) :type project_id: str - :param name: (required) - :type name: str + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -2068,9 +2164,9 @@ def get_load_balancer_without_preload_content( :return: Returns the result object. """ # noqa: E501 docstring might be too long - _param = self._get_load_balancer_serialize( + _param = self._list_credentials_serialize( project_id=project_id, - name=name, + region=region, _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, @@ -2078,20 +2174,19 @@ def get_load_balancer_without_preload_content( ) _response_types_map: Dict[str, Optional[str]] = { - "200": "LoadBalancer", + "200": "ListCredentialsResponse", "400": None, "401": "str", "403": None, - "404": None, "500": None, } response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) return response_data.response - def _get_load_balancer_serialize( + def _list_credentials_serialize( self, project_id, - name, + region, _request_auth, _content_type, _headers, @@ -2112,8 +2207,8 @@ def _get_load_balancer_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id - if name is not None: - _path_params["name"] = name + if region is not None: + _path_params["region"] = region # process the query parameters # process the header parameters # process the form parameters @@ -2128,7 +2223,7 @@ def _get_load_balancer_serialize( return self.api_client.param_serialize( method="GET", - resource_path="/v1/projects/{projectId}/load-balancers/{name}", + resource_path="/v2/projects/{projectId}/regions/{region}/credentials", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -2142,9 +2237,22 @@ def _get_load_balancer_serialize( ) @validate_call - def get_quota( + def list_load_balancers( self, project_id: StrictStr, + region: StrictStr, + page_size: Annotated[ + Optional[StrictStr], + Field( + description="page_size specifies how many load balancers should be returned on this page. Must be a positive number <= 1000" + ), + ] = None, + page_id: Annotated[ + Optional[StrictStr], + Field( + description="page_id is a page identifier returned by the previous response and is used to request the next page" + ), + ] = None, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -2154,743 +2262,19 @@ def get_quota( _content_type: Optional[StrictStr] = None, _headers: Optional[Dict[StrictStr, Any]] = None, _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetQuotaResponse: - """Get the quota of Load Balancers and Target Pools in a project. + ) -> ListLoadBalancersResponse: + """List load balancers in a project. - GetQuota gets the configured load balancer quota for the project. Default is 3. + ListLoadBalancer will list load balancers of a project. This contains information set during creation or updates for every load balancer in the project. Additionally, it will have information about the state of the load balancer in the form of a status field and error description feedback. :param project_id: (required) :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - - _param = self._get_quota_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "GetQuotaResponse", - "400": None, - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - response_data.read() - return self.api_client.response_deserialize( - response_data=response_data, - response_types_map=_response_types_map, - ).data - - @validate_call - def get_quota_with_http_info( - self, - project_id: StrictStr, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetQuotaResponse]: - """Get the quota of Load Balancers and Target Pools in a project. - - GetQuota gets the configured load balancer quota for the project. Default is 3. - - :param project_id: (required) - :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - - _param = self._get_quota_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "GetQuotaResponse", - "400": None, - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - response_data.read() - return self.api_client.response_deserialize( - response_data=response_data, - response_types_map=_response_types_map, - ) - - @validate_call - def get_quota_without_preload_content( - self, - project_id: StrictStr, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> RESTResponseType: - """Get the quota of Load Balancers and Target Pools in a project. - - GetQuota gets the configured load balancer quota for the project. Default is 3. - - :param project_id: (required) - :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - - _param = self._get_quota_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "GetQuotaResponse", - "400": None, - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - return response_data.response - - def _get_quota_serialize( - self, - project_id, - _request_auth, - _content_type, - _headers, - _host_index, - ) -> RequestSerialized: - - _host = None - - _collection_formats: Dict[str, str] = {} - - _path_params: Dict[str, str] = {} - _query_params: List[Tuple[str, str]] = [] - _header_params: Dict[str, Optional[str]] = _headers or {} - _form_params: List[Tuple[str, str]] = [] - _files: Dict[str, Union[str, bytes]] = {} - _body_params: Optional[bytes] = None - - # process the path parameters - if project_id is not None: - _path_params["projectId"] = project_id - # process the query parameters - # process the header parameters - # process the form parameters - # process the body parameter - - # set the HTTP header `Accept` - if "Accept" not in _header_params: - _header_params["Accept"] = self.api_client.select_header_accept(["application/json", "text/plain"]) - - # authentication setting - _auth_settings: List[str] = [] - - return self.api_client.param_serialize( - method="GET", - resource_path="/v1/projects/{projectId}/quota", - path_params=_path_params, - query_params=_query_params, - header_params=_header_params, - body=_body_params, - post_params=_form_params, - files=_files, - auth_settings=_auth_settings, - collection_formats=_collection_formats, - _host=_host, - _request_auth=_request_auth, - ) - - @validate_call - def get_service_status( - self, - project_id: StrictStr, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> GetServiceStatusResponse: - """(Deprecated) Return the status of load balancer functionality for the project specified. - - DEPRECATED! Checking the status is now obsolete. The endpoint is kept for compatibility. Status will return the load balancer functionality status for the project specified. - - :param project_id: (required) - :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - warnings.warn("GET /v1/projects/{projectId} is deprecated.", DeprecationWarning) - - _param = self._get_service_status_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "GetServiceStatusResponse", - "400": None, - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - response_data.read() - return self.api_client.response_deserialize( - response_data=response_data, - response_types_map=_response_types_map, - ).data - - @validate_call - def get_service_status_with_http_info( - self, - project_id: StrictStr, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[GetServiceStatusResponse]: - """(Deprecated) Return the status of load balancer functionality for the project specified. - - DEPRECATED! Checking the status is now obsolete. The endpoint is kept for compatibility. Status will return the load balancer functionality status for the project specified. - - :param project_id: (required) - :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - warnings.warn("GET /v1/projects/{projectId} is deprecated.", DeprecationWarning) - - _param = self._get_service_status_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "GetServiceStatusResponse", - "400": None, - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - response_data.read() - return self.api_client.response_deserialize( - response_data=response_data, - response_types_map=_response_types_map, - ) - - @validate_call - def get_service_status_without_preload_content( - self, - project_id: StrictStr, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> RESTResponseType: - """(Deprecated) Return the status of load balancer functionality for the project specified. - - DEPRECATED! Checking the status is now obsolete. The endpoint is kept for compatibility. Status will return the load balancer functionality status for the project specified. - - :param project_id: (required) - :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - warnings.warn("GET /v1/projects/{projectId} is deprecated.", DeprecationWarning) - - _param = self._get_service_status_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "GetServiceStatusResponse", - "400": None, - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - return response_data.response - - def _get_service_status_serialize( - self, - project_id, - _request_auth, - _content_type, - _headers, - _host_index, - ) -> RequestSerialized: - - _host = None - - _collection_formats: Dict[str, str] = {} - - _path_params: Dict[str, str] = {} - _query_params: List[Tuple[str, str]] = [] - _header_params: Dict[str, Optional[str]] = _headers or {} - _form_params: List[Tuple[str, str]] = [] - _files: Dict[str, Union[str, bytes]] = {} - _body_params: Optional[bytes] = None - - # process the path parameters - if project_id is not None: - _path_params["projectId"] = project_id - # process the query parameters - # process the header parameters - # process the form parameters - # process the body parameter - - # set the HTTP header `Accept` - if "Accept" not in _header_params: - _header_params["Accept"] = self.api_client.select_header_accept(["application/json", "text/plain"]) - - # authentication setting - _auth_settings: List[str] = [] - - return self.api_client.param_serialize( - method="GET", - resource_path="/v1/projects/{projectId}", - path_params=_path_params, - query_params=_query_params, - header_params=_header_params, - body=_body_params, - post_params=_form_params, - files=_files, - auth_settings=_auth_settings, - collection_formats=_collection_formats, - _host=_host, - _request_auth=_request_auth, - ) - - @validate_call - def list_credentials( - self, - project_id: StrictStr, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListCredentialsResponse: - """List all credentials in a project. - - List Credentials - - :param project_id: (required) - :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - - _param = self._list_credentials_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "ListCredentialsResponse", - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - response_data.read() - return self.api_client.response_deserialize( - response_data=response_data, - response_types_map=_response_types_map, - ).data - - @validate_call - def list_credentials_with_http_info( - self, - project_id: StrictStr, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ApiResponse[ListCredentialsResponse]: - """List all credentials in a project. - - List Credentials - - :param project_id: (required) - :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - - _param = self._list_credentials_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "ListCredentialsResponse", - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - response_data.read() - return self.api_client.response_deserialize( - response_data=response_data, - response_types_map=_response_types_map, - ) - - @validate_call - def list_credentials_without_preload_content( - self, - project_id: StrictStr, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> RESTResponseType: - """List all credentials in a project. - - List Credentials - - :param project_id: (required) - :type project_id: str - :param _request_timeout: timeout setting for this request. If one - number provided, it will be total request - timeout. It can also be a pair (tuple) of - (connection, read) timeouts. - :type _request_timeout: int, tuple(int, int), optional - :param _request_auth: set to override the auth_settings for an a single - request; this effectively ignores the - authentication in the spec for a single request. - :type _request_auth: dict, optional - :param _content_type: force content-type for the request. - :type _content_type: str, Optional - :param _headers: set to override the headers for a single - request; this effectively ignores the headers - in the spec for a single request. - :type _headers: dict, optional - :param _host_index: set to override the host_index for a single - request; this effectively ignores the host_index - in the spec for a single request. - :type _host_index: int, optional - :return: Returns the result object. - """ # noqa: E501 docstring might be too long - - _param = self._list_credentials_serialize( - project_id=project_id, - _request_auth=_request_auth, - _content_type=_content_type, - _headers=_headers, - _host_index=_host_index, - ) - - _response_types_map: Dict[str, Optional[str]] = { - "200": "ListCredentialsResponse", - "401": "str", - "403": None, - "500": None, - } - response_data = self.api_client.call_api(*_param, _request_timeout=_request_timeout) - return response_data.response - - def _list_credentials_serialize( - self, - project_id, - _request_auth, - _content_type, - _headers, - _host_index, - ) -> RequestSerialized: - - _host = None - - _collection_formats: Dict[str, str] = {} - - _path_params: Dict[str, str] = {} - _query_params: List[Tuple[str, str]] = [] - _header_params: Dict[str, Optional[str]] = _headers or {} - _form_params: List[Tuple[str, str]] = [] - _files: Dict[str, Union[str, bytes]] = {} - _body_params: Optional[bytes] = None - - # process the path parameters - if project_id is not None: - _path_params["projectId"] = project_id - # process the query parameters - # process the header parameters - # process the form parameters - # process the body parameter - - # set the HTTP header `Accept` - if "Accept" not in _header_params: - _header_params["Accept"] = self.api_client.select_header_accept(["application/json", "text/plain"]) - - # authentication setting - _auth_settings: List[str] = [] - - return self.api_client.param_serialize( - method="GET", - resource_path="/v1/projects/{projectId}/credentials", - path_params=_path_params, - query_params=_query_params, - header_params=_header_params, - body=_body_params, - post_params=_form_params, - files=_files, - auth_settings=_auth_settings, - collection_formats=_collection_formats, - _host=_host, - _request_auth=_request_auth, - ) - - @validate_call - def list_load_balancers( - self, - project_id: StrictStr, - page_size: Annotated[ - Optional[StrictStr], - Field( - description="page_size specifies how many load balancers should be returned on this page. Must be a positive number <= 1000" - ), - ] = None, - page_id: Annotated[ - Optional[StrictStr], - Field( - description="page_id is a page identifier returned by the previous response and is used to request the next page" - ), - ] = None, - _request_timeout: Union[ - None, - Annotated[StrictFloat, Field(gt=0)], - Tuple[Annotated[StrictFloat, Field(gt=0)], Annotated[StrictFloat, Field(gt=0)]], - ] = None, - _request_auth: Optional[Dict[StrictStr, Any]] = None, - _content_type: Optional[StrictStr] = None, - _headers: Optional[Dict[StrictStr, Any]] = None, - _host_index: Annotated[StrictInt, Field(ge=0, le=0)] = 0, - ) -> ListLoadBalancersResponse: - """List load balancers in a project. - - ListLoadBalancer will list load balancers of a project. This contains information set during creation or updates for every load balancer in the project. Additionally, it will have information about the state of the load balancer in the form of a status field and error description feedback. - - :param project_id: (required) - :type project_id: str - :param page_size: page_size specifies how many load balancers should be returned on this page. Must be a positive number <= 1000 - :type page_size: str - :param page_id: page_id is a page identifier returned by the previous response and is used to request the next page - :type page_id: str + :param region: (required) + :type region: str + :param page_size: page_size specifies how many load balancers should be returned on this page. Must be a positive number <= 1000 + :type page_size: str + :param page_id: page_id is a page identifier returned by the previous response and is used to request the next page + :type page_id: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -2915,6 +2299,7 @@ def list_load_balancers( _param = self._list_load_balancers_serialize( project_id=project_id, + region=region, page_size=page_size, page_id=page_id, _request_auth=_request_auth, @@ -2942,6 +2327,7 @@ def list_load_balancers( def list_load_balancers_with_http_info( self, project_id: StrictStr, + region: StrictStr, page_size: Annotated[ Optional[StrictStr], Field( @@ -2970,6 +2356,8 @@ def list_load_balancers_with_http_info( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param page_size: page_size specifies how many load balancers should be returned on this page. Must be a positive number <= 1000 :type page_size: str :param page_id: page_id is a page identifier returned by the previous response and is used to request the next page @@ -2998,6 +2386,7 @@ def list_load_balancers_with_http_info( _param = self._list_load_balancers_serialize( project_id=project_id, + region=region, page_size=page_size, page_id=page_id, _request_auth=_request_auth, @@ -3025,6 +2414,7 @@ def list_load_balancers_with_http_info( def list_load_balancers_without_preload_content( self, project_id: StrictStr, + region: StrictStr, page_size: Annotated[ Optional[StrictStr], Field( @@ -3053,6 +2443,8 @@ def list_load_balancers_without_preload_content( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param page_size: page_size specifies how many load balancers should be returned on this page. Must be a positive number <= 1000 :type page_size: str :param page_id: page_id is a page identifier returned by the previous response and is used to request the next page @@ -3081,6 +2473,7 @@ def list_load_balancers_without_preload_content( _param = self._list_load_balancers_serialize( project_id=project_id, + region=region, page_size=page_size, page_id=page_id, _request_auth=_request_auth, @@ -3103,6 +2496,7 @@ def list_load_balancers_without_preload_content( def _list_load_balancers_serialize( self, project_id, + region, page_size, page_id, _request_auth, @@ -3125,6 +2519,8 @@ def _list_load_balancers_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region # process the query parameters if page_size is not None: @@ -3147,7 +2543,7 @@ def _list_load_balancers_serialize( return self.api_client.param_serialize( method="GET", - resource_path="/v1/projects/{projectId}/load-balancers", + resource_path="/v2/projects/{projectId}/regions/{region}/load-balancers", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -3163,6 +2559,7 @@ def _list_load_balancers_serialize( @validate_call def list_plans( self, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -3177,6 +2574,8 @@ def list_plans( ListPlans returns for the configured service plans for a project. + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -3200,7 +2599,11 @@ def list_plans( """ # noqa: E501 docstring might be too long _param = self._list_plans_serialize( - _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, _host_index=_host_index + region=region, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index, ) _response_types_map: Dict[str, Optional[str]] = { @@ -3220,6 +2623,7 @@ def list_plans( @validate_call def list_plans_with_http_info( self, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -3234,6 +2638,8 @@ def list_plans_with_http_info( ListPlans returns for the configured service plans for a project. + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -3257,7 +2663,11 @@ def list_plans_with_http_info( """ # noqa: E501 docstring might be too long _param = self._list_plans_serialize( - _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, _host_index=_host_index + region=region, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index, ) _response_types_map: Dict[str, Optional[str]] = { @@ -3277,6 +2687,7 @@ def list_plans_with_http_info( @validate_call def list_plans_without_preload_content( self, + region: StrictStr, _request_timeout: Union[ None, Annotated[StrictFloat, Field(gt=0)], @@ -3291,6 +2702,8 @@ def list_plans_without_preload_content( ListPlans returns for the configured service plans for a project. + :param region: (required) + :type region: str :param _request_timeout: timeout setting for this request. If one number provided, it will be total request timeout. It can also be a pair (tuple) of @@ -3314,7 +2727,11 @@ def list_plans_without_preload_content( """ # noqa: E501 docstring might be too long _param = self._list_plans_serialize( - _request_auth=_request_auth, _content_type=_content_type, _headers=_headers, _host_index=_host_index + region=region, + _request_auth=_request_auth, + _content_type=_content_type, + _headers=_headers, + _host_index=_host_index, ) _response_types_map: Dict[str, Optional[str]] = { @@ -3329,6 +2746,7 @@ def list_plans_without_preload_content( def _list_plans_serialize( self, + region, _request_auth, _content_type, _headers, @@ -3347,6 +2765,8 @@ def _list_plans_serialize( _body_params: Optional[bytes] = None # process the path parameters + if region is not None: + _path_params["region"] = region # process the query parameters # process the header parameters # process the form parameters @@ -3361,7 +2781,7 @@ def _list_plans_serialize( return self.api_client.param_serialize( method="GET", - resource_path="/v1/plans", + resource_path="/v2/regions/{region}/plans", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -3378,6 +2798,7 @@ def _list_plans_serialize( def update_credentials( self, project_id: StrictStr, + region: StrictStr, credentials_ref: StrictStr, update_credentials_payload: UpdateCredentialsPayload, _request_timeout: Union[ @@ -3396,6 +2817,8 @@ def update_credentials( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param credentials_ref: (required) :type credentials_ref: str :param update_credentials_payload: (required) @@ -3424,6 +2847,7 @@ def update_credentials( _param = self._update_credentials_serialize( project_id=project_id, + region=region, credentials_ref=credentials_ref, update_credentials_payload=update_credentials_payload, _request_auth=_request_auth, @@ -3451,6 +2875,7 @@ def update_credentials( def update_credentials_with_http_info( self, project_id: StrictStr, + region: StrictStr, credentials_ref: StrictStr, update_credentials_payload: UpdateCredentialsPayload, _request_timeout: Union[ @@ -3469,6 +2894,8 @@ def update_credentials_with_http_info( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param credentials_ref: (required) :type credentials_ref: str :param update_credentials_payload: (required) @@ -3497,6 +2924,7 @@ def update_credentials_with_http_info( _param = self._update_credentials_serialize( project_id=project_id, + region=region, credentials_ref=credentials_ref, update_credentials_payload=update_credentials_payload, _request_auth=_request_auth, @@ -3524,6 +2952,7 @@ def update_credentials_with_http_info( def update_credentials_without_preload_content( self, project_id: StrictStr, + region: StrictStr, credentials_ref: StrictStr, update_credentials_payload: UpdateCredentialsPayload, _request_timeout: Union[ @@ -3542,6 +2971,8 @@ def update_credentials_without_preload_content( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param credentials_ref: (required) :type credentials_ref: str :param update_credentials_payload: (required) @@ -3570,6 +3001,7 @@ def update_credentials_without_preload_content( _param = self._update_credentials_serialize( project_id=project_id, + region=region, credentials_ref=credentials_ref, update_credentials_payload=update_credentials_payload, _request_auth=_request_auth, @@ -3592,6 +3024,7 @@ def update_credentials_without_preload_content( def _update_credentials_serialize( self, project_id, + region, credentials_ref, update_credentials_payload, _request_auth, @@ -3614,6 +3047,8 @@ def _update_credentials_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region if credentials_ref is not None: _path_params["credentialsRef"] = credentials_ref # process the query parameters @@ -3640,7 +3075,7 @@ def _update_credentials_serialize( return self.api_client.param_serialize( method="PUT", - resource_path="/v1/projects/{projectId}/credentials/{credentialsRef}", + resource_path="/v2/projects/{projectId}/regions/{region}/credentials/{credentialsRef}", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -3657,6 +3092,7 @@ def _update_credentials_serialize( def update_load_balancer( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, update_load_balancer_payload: UpdateLoadBalancerPayload, _request_timeout: Union[ @@ -3675,6 +3111,8 @@ def update_load_balancer( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param update_load_balancer_payload: (required) @@ -3703,6 +3141,7 @@ def update_load_balancer( _param = self._update_load_balancer_serialize( project_id=project_id, + region=region, name=name, update_load_balancer_payload=update_load_balancer_payload, _request_auth=_request_auth, @@ -3730,6 +3169,7 @@ def update_load_balancer( def update_load_balancer_with_http_info( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, update_load_balancer_payload: UpdateLoadBalancerPayload, _request_timeout: Union[ @@ -3748,6 +3188,8 @@ def update_load_balancer_with_http_info( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param update_load_balancer_payload: (required) @@ -3776,6 +3218,7 @@ def update_load_balancer_with_http_info( _param = self._update_load_balancer_serialize( project_id=project_id, + region=region, name=name, update_load_balancer_payload=update_load_balancer_payload, _request_auth=_request_auth, @@ -3803,6 +3246,7 @@ def update_load_balancer_with_http_info( def update_load_balancer_without_preload_content( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, update_load_balancer_payload: UpdateLoadBalancerPayload, _request_timeout: Union[ @@ -3821,6 +3265,8 @@ def update_load_balancer_without_preload_content( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param update_load_balancer_payload: (required) @@ -3849,6 +3295,7 @@ def update_load_balancer_without_preload_content( _param = self._update_load_balancer_serialize( project_id=project_id, + region=region, name=name, update_load_balancer_payload=update_load_balancer_payload, _request_auth=_request_auth, @@ -3871,6 +3318,7 @@ def update_load_balancer_without_preload_content( def _update_load_balancer_serialize( self, project_id, + region, name, update_load_balancer_payload, _request_auth, @@ -3893,6 +3341,8 @@ def _update_load_balancer_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region if name is not None: _path_params["name"] = name # process the query parameters @@ -3919,7 +3369,7 @@ def _update_load_balancer_serialize( return self.api_client.param_serialize( method="PUT", - resource_path="/v1/projects/{projectId}/load-balancers/{name}", + resource_path="/v2/projects/{projectId}/regions/{region}/load-balancers/{name}", path_params=_path_params, query_params=_query_params, header_params=_header_params, @@ -3936,6 +3386,7 @@ def _update_load_balancer_serialize( def update_target_pool( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, target_pool_name: StrictStr, update_target_pool_payload: UpdateTargetPoolPayload, @@ -3955,6 +3406,8 @@ def update_target_pool( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param target_pool_name: (required) @@ -3985,6 +3438,7 @@ def update_target_pool( _param = self._update_target_pool_serialize( project_id=project_id, + region=region, name=name, target_pool_name=target_pool_name, update_target_pool_payload=update_target_pool_payload, @@ -4012,6 +3466,7 @@ def update_target_pool( def update_target_pool_with_http_info( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, target_pool_name: StrictStr, update_target_pool_payload: UpdateTargetPoolPayload, @@ -4031,6 +3486,8 @@ def update_target_pool_with_http_info( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param target_pool_name: (required) @@ -4061,6 +3518,7 @@ def update_target_pool_with_http_info( _param = self._update_target_pool_serialize( project_id=project_id, + region=region, name=name, target_pool_name=target_pool_name, update_target_pool_payload=update_target_pool_payload, @@ -4088,6 +3546,7 @@ def update_target_pool_with_http_info( def update_target_pool_without_preload_content( self, project_id: StrictStr, + region: StrictStr, name: StrictStr, target_pool_name: StrictStr, update_target_pool_payload: UpdateTargetPoolPayload, @@ -4107,6 +3566,8 @@ def update_target_pool_without_preload_content( :param project_id: (required) :type project_id: str + :param region: (required) + :type region: str :param name: (required) :type name: str :param target_pool_name: (required) @@ -4137,6 +3598,7 @@ def update_target_pool_without_preload_content( _param = self._update_target_pool_serialize( project_id=project_id, + region=region, name=name, target_pool_name=target_pool_name, update_target_pool_payload=update_target_pool_payload, @@ -4159,6 +3621,7 @@ def update_target_pool_without_preload_content( def _update_target_pool_serialize( self, project_id, + region, name, target_pool_name, update_target_pool_payload, @@ -4182,6 +3645,8 @@ def _update_target_pool_serialize( # process the path parameters if project_id is not None: _path_params["projectId"] = project_id + if region is not None: + _path_params["region"] = region if name is not None: _path_params["name"] = name if target_pool_name is not None: @@ -4210,7 +3675,7 @@ def _update_target_pool_serialize( return self.api_client.param_serialize( method="PUT", - resource_path="/v1/projects/{projectId}/load-balancers/{name}/target-pools/{targetPoolName}", + resource_path="/v2/projects/{projectId}/regions/{region}/load-balancers/{name}/target-pools/{targetPoolName}", path_params=_path_params, query_params=_query_params, header_params=_header_params, diff --git a/services/loadbalancer/src/stackit/loadbalancer/api_client.py b/services/loadbalancer/src/stackit/loadbalancer/api_client.py index 3968b234..1606a562 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/api_client.py +++ b/services/loadbalancer/src/stackit/loadbalancer/api_client.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/configuration.py b/services/loadbalancer/src/stackit/loadbalancer/configuration.py index 50b53a76..591de51d 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/configuration.py +++ b/services/loadbalancer/src/stackit/loadbalancer/configuration.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -32,7 +32,7 @@ def __init__( ) """Constructor """ - self._base_path = "https://load-balancer.api.eu01.stackit.cloud" + self._base_path = "https://load-balancer.api.stackit.cloud" """Default Base url """ self.server_index = 0 if server_index is None else server_index @@ -56,13 +56,12 @@ def get_host_settings(self): """ return [ { - "url": "https://load-balancer.api.{region}stackit.cloud", + "url": "https://load-balancer.api.stackit.cloud", "description": "No description provided", "variables": { "region": { "description": "No description provided", - "default_value": "eu01.", - "enum_values": ["eu01."], + "default_value": "global", } }, } diff --git a/services/loadbalancer/src/stackit/loadbalancer/exceptions.py b/services/loadbalancer/src/stackit/loadbalancer/exceptions.py index b7e1dfe8..cc3b4f97 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/exceptions.py +++ b/services/loadbalancer/src/stackit/loadbalancer/exceptions.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/__init__.py b/services/loadbalancer/src/stackit/loadbalancer/models/__init__.py index 89dbeb74..5adda514 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/__init__.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/__init__.py @@ -6,7 +6,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -27,9 +27,6 @@ from stackit.loadbalancer.models.credentials_response import CredentialsResponse from stackit.loadbalancer.models.get_credentials_response import GetCredentialsResponse from stackit.loadbalancer.models.get_quota_response import GetQuotaResponse -from stackit.loadbalancer.models.get_service_status_response import ( - GetServiceStatusResponse, -) from stackit.loadbalancer.models.google_protobuf_any import GoogleProtobufAny from stackit.loadbalancer.models.list_credentials_response import ( ListCredentialsResponse, diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/active_health_check.py b/services/loadbalancer/src/stackit/loadbalancer/models/active_health_check.py index ae6d0449..e6e45cc2 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/active_health_check.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/active_health_check.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -18,7 +18,7 @@ import re from typing import Any, ClassVar, Dict, List, Optional, Set -from pydantic import BaseModel, ConfigDict, Field, StrictInt, field_validator +from pydantic import BaseModel, ConfigDict, Field, field_validator from typing_extensions import Annotated, Self @@ -27,7 +27,7 @@ class ActiveHealthCheck(BaseModel): ActiveHealthCheck """ - healthy_threshold: Optional[StrictInt] = Field( + healthy_threshold: Optional[Annotated[int, Field(le=1000000, strict=True, ge=1)]] = Field( default=None, description="Healthy threshold of the health checking", alias="healthyThreshold" ) interval: Optional[Annotated[str, Field(strict=True)]] = Field( @@ -41,7 +41,7 @@ class ActiveHealthCheck(BaseModel): timeout: Optional[Annotated[str, Field(strict=True)]] = Field( default=None, description="Active health checking timeout duration in seconds" ) - unhealthy_threshold: Optional[StrictInt] = Field( + unhealthy_threshold: Optional[Annotated[int, Field(le=1000000, strict=True, ge=1)]] = Field( default=None, description="Unhealthy threshold of the health checking", alias="unhealthyThreshold" ) __properties: ClassVar[List[str]] = [ diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/create_credentials_payload.py b/services/loadbalancer/src/stackit/loadbalancer/models/create_credentials_payload.py index 36e2db3b..715ff3e1 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/create_credentials_payload.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/create_credentials_payload.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/create_credentials_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/create_credentials_response.py index 2d5dfb38..374d16e8 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/create_credentials_response.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/create_credentials_response.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/create_load_balancer_payload.py b/services/loadbalancer/src/stackit/loadbalancer/models/create_load_balancer_payload.py index 67a81503..4b0f8cd2 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/create_load_balancer_payload.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/create_load_balancer_payload.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -63,6 +63,7 @@ class CreateLoadBalancerPayload(BaseModel): description="Transient private load balancer IP address that can change any time.", alias="privateAddress", ) + region: Optional[StrictStr] = Field(default=None, description="Region of the LoadBalancer") status: Optional[StrictStr] = None target_pools: Optional[List[TargetPool]] = Field( default=None, @@ -82,6 +83,7 @@ class CreateLoadBalancerPayload(BaseModel): "options", "planId", "privateAddress", + "region", "status", "targetPools", "version", @@ -143,11 +145,13 @@ def to_dict(self) -> Dict[str, Any]: * OpenAPI `readOnly` fields are excluded. * OpenAPI `readOnly` fields are excluded. * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. """ excluded_fields: Set[str] = set( [ "errors", "private_address", + "region", "status", ] ) @@ -219,6 +223,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "options": LoadBalancerOptions.from_dict(obj["options"]) if obj.get("options") is not None else None, "planId": obj.get("planId"), "privateAddress": obj.get("privateAddress"), + "region": obj.get("region"), "status": obj.get("status"), "targetPools": ( [TargetPool.from_dict(_item) for _item in obj["targetPools"]] diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/credentials_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/credentials_response.py index dbcdba43..6e67b41c 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/credentials_response.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/credentials_response.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -35,8 +35,9 @@ class CredentialsResponse(BaseModel): display_name: Optional[Annotated[str, Field(strict=True)]] = Field( default=None, description="Credential name", alias="displayName" ) + region: Optional[StrictStr] = Field(default=None, description="Region of the Credential") username: Optional[StrictStr] = Field(default=None, description="The username used for the ARGUS instance") - __properties: ClassVar[List[str]] = ["credentialsRef", "displayName", "username"] + __properties: ClassVar[List[str]] = ["credentialsRef", "displayName", "region", "username"] @field_validator("display_name") def display_name_validate_regular_expression(cls, value): @@ -100,6 +101,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: { "credentialsRef": obj.get("credentialsRef"), "displayName": obj.get("displayName"), + "region": obj.get("region"), "username": obj.get("username"), } ) diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/get_credentials_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/get_credentials_response.py index 20a68e93..66debb29 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/get_credentials_response.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/get_credentials_response.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/get_quota_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/get_quota_response.py index 82ff4001..51038bd9 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/get_quota_response.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/get_quota_response.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -35,7 +35,8 @@ class GetQuotaResponse(BaseModel): project_id: Optional[Annotated[str, Field(strict=True)]] = Field( default=None, description="Project identifier", alias="projectId" ) - __properties: ClassVar[List[str]] = ["maxLoadBalancers", "projectId"] + region: Optional[Annotated[str, Field(strict=True)]] = Field(default=None, description="Region") + __properties: ClassVar[List[str]] = ["maxLoadBalancers", "projectId", "region"] @field_validator("project_id") def project_id_validate_regular_expression(cls, value): @@ -49,6 +50,16 @@ def project_id_validate_regular_expression(cls, value): ) return value + @field_validator("region") + def region_validate_regular_expression(cls, value): + """Validates the regular expression""" + if value is None: + return value + + if not re.match(r"^[a-z]{2,4}[0-9]{2}$", value): + raise ValueError(r"must validate the regular expression /^[a-z]{2,4}[0-9]{2}$/") + return value + model_config = ConfigDict( populate_by_name=True, validate_assignment=True, @@ -79,10 +90,12 @@ def to_dict(self) -> Dict[str, Any]: were set at model initialization. Other fields with value `None` are ignored. * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. """ excluded_fields: Set[str] = set( [ "project_id", + "region", ] ) @@ -102,5 +115,11 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: if not isinstance(obj, dict): return cls.model_validate(obj) - _obj = cls.model_validate({"maxLoadBalancers": obj.get("maxLoadBalancers"), "projectId": obj.get("projectId")}) + _obj = cls.model_validate( + { + "maxLoadBalancers": obj.get("maxLoadBalancers"), + "projectId": obj.get("projectId"), + "region": obj.get("region"), + } + ) return _obj diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/get_service_status_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/get_service_status_response.py deleted file mode 100644 index e43361a3..00000000 --- a/services/loadbalancer/src/stackit/loadbalancer/models/get_service_status_response.py +++ /dev/null @@ -1,103 +0,0 @@ -# coding: utf-8 - -""" - Load Balancer API - - This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - - The version of the OpenAPI document: 1.7.2 - Generated by OpenAPI Generator (https://openapi-generator.tech) - - Do not edit the class manually. -""" # noqa: E501 docstring might be too long - -from __future__ import annotations - -import json -import pprint -from typing import Any, ClassVar, Dict, List, Optional, Set - -from pydantic import BaseModel, ConfigDict, Field, StrictStr, field_validator -from typing_extensions import Self - - -class GetServiceStatusResponse(BaseModel): - """ - Response with customer project status. - """ - - status: Optional[StrictStr] = Field(default=None, description="status of the project") - __properties: ClassVar[List[str]] = ["status"] - - @field_validator("status") - def status_validate_enum(cls, value): - """Validates the enum""" - if value is None: - return value - - if value not in set( - [ - "STATUS_UNSPECIFIED", - "STATUS_READY", - "STATUS_FAILED", - "STATUS_UPDATING", - "STATUS_DELETING", - "STATUS_DISABLED", - "STATUS_PROJECT_UNKNOWN", - ] - ): - raise ValueError( - "must be one of enum values ('STATUS_UNSPECIFIED', 'STATUS_READY', 'STATUS_FAILED', 'STATUS_UPDATING', 'STATUS_DELETING', 'STATUS_DISABLED', 'STATUS_PROJECT_UNKNOWN')" - ) - return value - - model_config = ConfigDict( - populate_by_name=True, - validate_assignment=True, - protected_namespaces=(), - ) - - def to_str(self) -> str: - """Returns the string representation of the model using alias""" - return pprint.pformat(self.model_dump(by_alias=True)) - - def to_json(self) -> str: - """Returns the JSON representation of the model using alias""" - # TODO: pydantic v2: use .model_dump_json(by_alias=True, exclude_unset=True) instead - return json.dumps(self.to_dict()) - - @classmethod - def from_json(cls, json_str: str) -> Optional[Self]: - """Create an instance of GetServiceStatusResponse from a JSON string""" - return cls.from_dict(json.loads(json_str)) - - def to_dict(self) -> Dict[str, Any]: - """Return the dictionary representation of the model using alias. - - This has the following differences from calling pydantic's - `self.model_dump(by_alias=True)`: - - * `None` is only added to the output dict for nullable fields that - were set at model initialization. Other fields with value `None` - are ignored. - """ - excluded_fields: Set[str] = set([]) - - _dict = self.model_dump( - by_alias=True, - exclude=excluded_fields, - exclude_none=True, - ) - return _dict - - @classmethod - def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: - """Create an instance of GetServiceStatusResponse from a dict""" - if obj is None: - return None - - if not isinstance(obj, dict): - return cls.model_validate(obj) - - _obj = cls.model_validate({"status": obj.get("status")}) - return _obj diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/google_protobuf_any.py b/services/loadbalancer/src/stackit/loadbalancer/models/google_protobuf_any.py index fb99257a..de07d88e 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/google_protobuf_any.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/google_protobuf_any.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/list_credentials_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/list_credentials_response.py index 956cf6d5..ff1a14e9 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/list_credentials_response.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/list_credentials_response.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/list_load_balancers_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/list_load_balancers_response.py index 15797d0f..644c96f3 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/list_load_balancers_response.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/list_load_balancers_response.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/list_plans_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/list_plans_response.py index e7a9264c..41ecbbc7 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/list_plans_response.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/list_plans_response.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/listener.py b/services/loadbalancer/src/stackit/loadbalancer/models/listener.py index 0bcb6e75..e192d503 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/listener.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/listener.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer.py b/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer.py index 04accdce..edd3cdb2 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -63,6 +63,7 @@ class LoadBalancer(BaseModel): description="Transient private load balancer IP address that can change any time.", alias="privateAddress", ) + region: Optional[StrictStr] = Field(default=None, description="Region of the LoadBalancer") status: Optional[StrictStr] = None target_pools: Optional[List[TargetPool]] = Field( default=None, @@ -82,6 +83,7 @@ class LoadBalancer(BaseModel): "options", "planId", "privateAddress", + "region", "status", "targetPools", "version", @@ -143,11 +145,13 @@ def to_dict(self) -> Dict[str, Any]: * OpenAPI `readOnly` fields are excluded. * OpenAPI `readOnly` fields are excluded. * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. """ excluded_fields: Set[str] = set( [ "errors", "private_address", + "region", "status", ] ) @@ -219,6 +223,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "options": LoadBalancerOptions.from_dict(obj["options"]) if obj.get("options") is not None else None, "planId": obj.get("planId"), "privateAddress": obj.get("privateAddress"), + "region": obj.get("region"), "status": obj.get("status"), "targetPools": ( [TargetPool.from_dict(_item) for _item in obj["targetPools"]] diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer_error.py b/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer_error.py index 2ae6d35a..e89c93b2 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer_error.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer_error.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer_options.py b/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer_options.py index 2eb78285..9306f60f 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer_options.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/load_balancer_options.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_access_control.py b/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_access_control.py index 21d28c0b..13345d4c 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_access_control.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_access_control.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_logs.py b/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_logs.py index 6277e395..2e8d6891 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_logs.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_logs.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_metrics.py b/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_metrics.py index 9dcfcd1c..21afed4c 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_metrics.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_metrics.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_observability.py b/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_observability.py index 106439e9..a9980bf2 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_observability.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/loadbalancer_option_observability.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/network.py b/services/loadbalancer/src/stackit/loadbalancer/models/network.py index 011a3de4..5f022b5c 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/network.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/network.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/options_tcp.py b/services/loadbalancer/src/stackit/loadbalancer/models/options_tcp.py index 0adb779a..19ecef68 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/options_tcp.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/options_tcp.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/options_udp.py b/services/loadbalancer/src/stackit/loadbalancer/models/options_udp.py index 9f61995e..d2756fcc 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/options_udp.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/options_udp.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/plan_details.py b/services/loadbalancer/src/stackit/loadbalancer/models/plan_details.py index 152cf54e..172c54b9 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/plan_details.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/plan_details.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -35,7 +35,8 @@ class PlanDetails(BaseModel): ) name: Optional[StrictStr] = Field(default=None, description="Service Plan Name") plan_id: Optional[StrictStr] = Field(default=None, description="Service Plan Identifier", alias="planId") - __properties: ClassVar[List[str]] = ["description", "flavorName", "maxConnections", "name", "planId"] + region: Optional[StrictStr] = Field(default=None, description="Region this Plan is available in") + __properties: ClassVar[List[str]] = ["description", "flavorName", "maxConnections", "name", "planId", "region"] model_config = ConfigDict( populate_by_name=True, @@ -92,6 +93,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "maxConnections": obj.get("maxConnections"), "name": obj.get("name"), "planId": obj.get("planId"), + "region": obj.get("region"), } ) return _obj diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/server_name_indicator.py b/services/loadbalancer/src/stackit/loadbalancer/models/server_name_indicator.py index dfb20445..d90156a4 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/server_name_indicator.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/server_name_indicator.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/session_persistence.py b/services/loadbalancer/src/stackit/loadbalancer/models/session_persistence.py index 0ffbbf50..641f861c 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/session_persistence.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/session_persistence.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/status.py b/services/loadbalancer/src/stackit/loadbalancer/models/status.py index 6e2a6ef4..460d96ea 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/status.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/status.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/target.py b/services/loadbalancer/src/stackit/loadbalancer/models/target.py index bea81595..14e07fc4 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/target.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/target.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/target_pool.py b/services/loadbalancer/src/stackit/loadbalancer/models/target_pool.py index f5f4a70c..5e2019d7 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/target_pool.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/target_pool.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/update_credentials_payload.py b/services/loadbalancer/src/stackit/loadbalancer/models/update_credentials_payload.py index cce2496f..c7192923 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/update_credentials_payload.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/update_credentials_payload.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/update_credentials_response.py b/services/loadbalancer/src/stackit/loadbalancer/models/update_credentials_response.py index 8dd51ded..ab34a5d3 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/update_credentials_response.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/update_credentials_response.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/update_load_balancer_payload.py b/services/loadbalancer/src/stackit/loadbalancer/models/update_load_balancer_payload.py index 475b45be..3ade60ce 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/update_load_balancer_payload.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/update_load_balancer_payload.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. @@ -63,6 +63,7 @@ class UpdateLoadBalancerPayload(BaseModel): description="Transient private load balancer IP address that can change any time.", alias="privateAddress", ) + region: Optional[StrictStr] = Field(default=None, description="Region of the LoadBalancer") status: Optional[StrictStr] = None target_pools: Optional[List[TargetPool]] = Field( default=None, @@ -82,6 +83,7 @@ class UpdateLoadBalancerPayload(BaseModel): "options", "planId", "privateAddress", + "region", "status", "targetPools", "version", @@ -143,11 +145,13 @@ def to_dict(self) -> Dict[str, Any]: * OpenAPI `readOnly` fields are excluded. * OpenAPI `readOnly` fields are excluded. * OpenAPI `readOnly` fields are excluded. + * OpenAPI `readOnly` fields are excluded. """ excluded_fields: Set[str] = set( [ "errors", "private_address", + "region", "status", ] ) @@ -219,6 +223,7 @@ def from_dict(cls, obj: Optional[Dict[str, Any]]) -> Optional[Self]: "options": LoadBalancerOptions.from_dict(obj["options"]) if obj.get("options") is not None else None, "planId": obj.get("planId"), "privateAddress": obj.get("privateAddress"), + "region": obj.get("region"), "status": obj.get("status"), "targetPools": ( [TargetPool.from_dict(_item) for _item in obj["targetPools"]] diff --git a/services/loadbalancer/src/stackit/loadbalancer/models/update_target_pool_payload.py b/services/loadbalancer/src/stackit/loadbalancer/models/update_target_pool_payload.py index 05e24008..49545229 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/models/update_target_pool_payload.py +++ b/services/loadbalancer/src/stackit/loadbalancer/models/update_target_pool_payload.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually. diff --git a/services/loadbalancer/src/stackit/loadbalancer/rest.py b/services/loadbalancer/src/stackit/loadbalancer/rest.py index a2ab4f11..d02425a3 100644 --- a/services/loadbalancer/src/stackit/loadbalancer/rest.py +++ b/services/loadbalancer/src/stackit/loadbalancer/rest.py @@ -5,7 +5,7 @@ This API offers an interface to provision and manage load balancing servers in your STACKIT project. It also has the possibility of pooling target servers for load balancing purposes. For each load balancer provided, two VMs are deployed in your OpenStack project subject to a fee. - The version of the OpenAPI document: 1.7.2 + The version of the OpenAPI document: 2.0.0 Generated by OpenAPI Generator (https://openapi-generator.tech) Do not edit the class manually.