From 16c4113f93ff7b29752e4087c911fcd44e0d950a Mon Sep 17 00:00:00 2001 From: scaleway-bot Date: Fri, 14 Feb 2025 16:15:02 +0000 Subject: [PATCH] feat: update generated APIs --- scaleway-async/scaleway_async/lb/v1/api.py | 12 +++++++++ .../scaleway_async/lb/v1/marshalling.py | 18 +++++++++++++ scaleway-async/scaleway_async/lb/v1/types.py | 25 +++++++++++++++++++ scaleway/scaleway/lb/v1/api.py | 12 +++++++++ scaleway/scaleway/lb/v1/marshalling.py | 18 +++++++++++++ scaleway/scaleway/lb/v1/types.py | 25 +++++++++++++++++++ 6 files changed, 110 insertions(+) diff --git a/scaleway-async/scaleway_async/lb/v1/api.py b/scaleway-async/scaleway_async/lb/v1/api.py index 1929ba5ee..bd34829f7 100644 --- a/scaleway-async/scaleway_async/lb/v1/api.py +++ b/scaleway-async/scaleway_async/lb/v1/api.py @@ -1515,6 +1515,7 @@ async def create_frontend( timeout_client: Optional[str] = None, certificate_id: Optional[str] = None, certificate_ids: Optional[List[str]] = None, + connection_rate_limit: Optional[int] = None, ) -> Frontend: """ Create a frontend in a given Load Balancer. @@ -1528,6 +1529,7 @@ async def create_frontend( :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. + :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: :class:`Frontend ` Usage: @@ -1558,6 +1560,7 @@ async def create_frontend( timeout_client=timeout_client, certificate_id=certificate_id, certificate_ids=certificate_ids, + connection_rate_limit=connection_rate_limit, ), self.client, ), @@ -1610,6 +1613,7 @@ async def update_frontend( timeout_client: Optional[str] = None, certificate_id: Optional[str] = None, certificate_ids: Optional[List[str]] = None, + connection_rate_limit: Optional[int] = None, ) -> Frontend: """ Update a frontend. @@ -1623,6 +1627,7 @@ async def update_frontend( :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. + :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: :class:`Frontend ` Usage: @@ -1654,6 +1659,7 @@ async def update_frontend( timeout_client=timeout_client, certificate_id=certificate_id, certificate_ids=certificate_ids, + connection_rate_limit=connection_rate_limit, ), self.client, ), @@ -4549,6 +4555,7 @@ async def create_frontend( timeout_client: Optional[str] = None, certificate_id: Optional[str] = None, certificate_ids: Optional[List[str]] = None, + connection_rate_limit: Optional[int] = None, ) -> Frontend: """ Create a frontend in a given load balancer. @@ -4561,6 +4568,7 @@ async def create_frontend( :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. + :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: :class:`Frontend ` Usage: @@ -4593,6 +4601,7 @@ async def create_frontend( timeout_client=timeout_client, certificate_id=certificate_id, certificate_ids=certificate_ids, + connection_rate_limit=connection_rate_limit, ), self.client, ), @@ -4646,6 +4655,7 @@ async def update_frontend( timeout_client: Optional[str] = None, certificate_id: Optional[str] = None, certificate_ids: Optional[List[str]] = None, + connection_rate_limit: Optional[int] = None, ) -> Frontend: """ Update a frontend. @@ -4658,6 +4668,7 @@ async def update_frontend( :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. + :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: :class:`Frontend ` Usage: @@ -4691,6 +4702,7 @@ async def update_frontend( timeout_client=timeout_client, certificate_id=certificate_id, certificate_ids=certificate_ids, + connection_rate_limit=connection_rate_limit, ), self.client, ), diff --git a/scaleway-async/scaleway_async/lb/v1/marshalling.py b/scaleway-async/scaleway_async/lb/v1/marshalling.py index 126b14591..9a2e94fd0 100644 --- a/scaleway-async/scaleway_async/lb/v1/marshalling.py +++ b/scaleway-async/scaleway_async/lb/v1/marshalling.py @@ -855,6 +855,12 @@ def unmarshal_Frontend(data: Any) -> Frontend: else: args["updated_at"] = None + field = data.get("connection_rate_limit", None) + if field is not None: + args["connection_rate_limit"] = field + else: + args["connection_rate_limit"] = None + return Frontend(**args) @@ -1928,6 +1934,9 @@ def marshal_CreateFrontendRequest( if request.certificate_ids is not None: output["certificate_ids"] = request.certificate_ids + if request.connection_rate_limit is not None: + output["connection_rate_limit"] = request.connection_rate_limit + return output @@ -2283,6 +2292,9 @@ def marshal_UpdateFrontendRequest( if request.certificate_ids is not None: output["certificate_ids"] = request.certificate_ids + if request.connection_rate_limit is not None: + output["connection_rate_limit"] = request.connection_rate_limit + return output @@ -2576,6 +2588,9 @@ def marshal_ZonedApiCreateFrontendRequest( if request.certificate_ids is not None: output["certificate_ids"] = request.certificate_ids + if request.connection_rate_limit is not None: + output["connection_rate_limit"] = request.connection_rate_limit + return output @@ -2926,6 +2941,9 @@ def marshal_ZonedApiUpdateFrontendRequest( if request.certificate_ids is not None: output["certificate_ids"] = request.certificate_ids + if request.connection_rate_limit is not None: + output["connection_rate_limit"] = request.connection_rate_limit + return output diff --git a/scaleway-async/scaleway_async/lb/v1/types.py b/scaleway-async/scaleway_async/lb/v1/types.py index 10556a962..51fadbc9c 100644 --- a/scaleway-async/scaleway_async/lb/v1/types.py +++ b/scaleway-async/scaleway_async/lb/v1/types.py @@ -944,6 +944,11 @@ class Frontend: Date on which the frontend was last updated. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class PrivateNetworkDHCPConfig: @@ -1476,6 +1481,11 @@ class CreateFrontendRequest: List of SSL/TLS certificate IDs to bind to the frontend. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class CreateIpRequest: @@ -2680,6 +2690,11 @@ class UpdateFrontendRequest: List of SSL/TLS certificate IDs to bind to the frontend. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class UpdateHealthCheckRequest: @@ -3120,6 +3135,11 @@ class ZonedApiCreateFrontendRequest: List of SSL/TLS certificate IDs to bind to the frontend. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class ZonedApiCreateIpRequest: @@ -4178,6 +4198,11 @@ class ZonedApiUpdateFrontendRequest: List of SSL/TLS certificate IDs to bind to the frontend. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class ZonedApiUpdateHealthCheckRequest: diff --git a/scaleway/scaleway/lb/v1/api.py b/scaleway/scaleway/lb/v1/api.py index 30becc0ad..038a93d88 100644 --- a/scaleway/scaleway/lb/v1/api.py +++ b/scaleway/scaleway/lb/v1/api.py @@ -1515,6 +1515,7 @@ def create_frontend( timeout_client: Optional[str] = None, certificate_id: Optional[str] = None, certificate_ids: Optional[List[str]] = None, + connection_rate_limit: Optional[int] = None, ) -> Frontend: """ Create a frontend in a given Load Balancer. @@ -1528,6 +1529,7 @@ def create_frontend( :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. + :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: :class:`Frontend ` Usage: @@ -1558,6 +1560,7 @@ def create_frontend( timeout_client=timeout_client, certificate_id=certificate_id, certificate_ids=certificate_ids, + connection_rate_limit=connection_rate_limit, ), self.client, ), @@ -1610,6 +1613,7 @@ def update_frontend( timeout_client: Optional[str] = None, certificate_id: Optional[str] = None, certificate_ids: Optional[List[str]] = None, + connection_rate_limit: Optional[int] = None, ) -> Frontend: """ Update a frontend. @@ -1623,6 +1627,7 @@ def update_frontend( :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. + :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: :class:`Frontend ` Usage: @@ -1654,6 +1659,7 @@ def update_frontend( timeout_client=timeout_client, certificate_id=certificate_id, certificate_ids=certificate_ids, + connection_rate_limit=connection_rate_limit, ), self.client, ), @@ -4547,6 +4553,7 @@ def create_frontend( timeout_client: Optional[str] = None, certificate_id: Optional[str] = None, certificate_ids: Optional[List[str]] = None, + connection_rate_limit: Optional[int] = None, ) -> Frontend: """ Create a frontend in a given load balancer. @@ -4559,6 +4566,7 @@ def create_frontend( :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. + :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: :class:`Frontend ` Usage: @@ -4591,6 +4599,7 @@ def create_frontend( timeout_client=timeout_client, certificate_id=certificate_id, certificate_ids=certificate_ids, + connection_rate_limit=connection_rate_limit, ), self.client, ), @@ -4644,6 +4653,7 @@ def update_frontend( timeout_client: Optional[str] = None, certificate_id: Optional[str] = None, certificate_ids: Optional[List[str]] = None, + connection_rate_limit: Optional[int] = None, ) -> Frontend: """ Update a frontend. @@ -4656,6 +4666,7 @@ def update_frontend( :param timeout_client: Maximum allowed inactivity time on the client side. :param certificate_id: Certificate ID, deprecated in favor of certificate_ids array. :param certificate_ids: List of SSL/TLS certificate IDs to bind to the frontend. + :param connection_rate_limit: Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. :return: :class:`Frontend ` Usage: @@ -4689,6 +4700,7 @@ def update_frontend( timeout_client=timeout_client, certificate_id=certificate_id, certificate_ids=certificate_ids, + connection_rate_limit=connection_rate_limit, ), self.client, ), diff --git a/scaleway/scaleway/lb/v1/marshalling.py b/scaleway/scaleway/lb/v1/marshalling.py index 126b14591..9a2e94fd0 100644 --- a/scaleway/scaleway/lb/v1/marshalling.py +++ b/scaleway/scaleway/lb/v1/marshalling.py @@ -855,6 +855,12 @@ def unmarshal_Frontend(data: Any) -> Frontend: else: args["updated_at"] = None + field = data.get("connection_rate_limit", None) + if field is not None: + args["connection_rate_limit"] = field + else: + args["connection_rate_limit"] = None + return Frontend(**args) @@ -1928,6 +1934,9 @@ def marshal_CreateFrontendRequest( if request.certificate_ids is not None: output["certificate_ids"] = request.certificate_ids + if request.connection_rate_limit is not None: + output["connection_rate_limit"] = request.connection_rate_limit + return output @@ -2283,6 +2292,9 @@ def marshal_UpdateFrontendRequest( if request.certificate_ids is not None: output["certificate_ids"] = request.certificate_ids + if request.connection_rate_limit is not None: + output["connection_rate_limit"] = request.connection_rate_limit + return output @@ -2576,6 +2588,9 @@ def marshal_ZonedApiCreateFrontendRequest( if request.certificate_ids is not None: output["certificate_ids"] = request.certificate_ids + if request.connection_rate_limit is not None: + output["connection_rate_limit"] = request.connection_rate_limit + return output @@ -2926,6 +2941,9 @@ def marshal_ZonedApiUpdateFrontendRequest( if request.certificate_ids is not None: output["certificate_ids"] = request.certificate_ids + if request.connection_rate_limit is not None: + output["connection_rate_limit"] = request.connection_rate_limit + return output diff --git a/scaleway/scaleway/lb/v1/types.py b/scaleway/scaleway/lb/v1/types.py index 10556a962..51fadbc9c 100644 --- a/scaleway/scaleway/lb/v1/types.py +++ b/scaleway/scaleway/lb/v1/types.py @@ -944,6 +944,11 @@ class Frontend: Date on which the frontend was last updated. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class PrivateNetworkDHCPConfig: @@ -1476,6 +1481,11 @@ class CreateFrontendRequest: List of SSL/TLS certificate IDs to bind to the frontend. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class CreateIpRequest: @@ -2680,6 +2690,11 @@ class UpdateFrontendRequest: List of SSL/TLS certificate IDs to bind to the frontend. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class UpdateHealthCheckRequest: @@ -3120,6 +3135,11 @@ class ZonedApiCreateFrontendRequest: List of SSL/TLS certificate IDs to bind to the frontend. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class ZonedApiCreateIpRequest: @@ -4178,6 +4198,11 @@ class ZonedApiUpdateFrontendRequest: List of SSL/TLS certificate IDs to bind to the frontend. """ + connection_rate_limit: Optional[int] + """ + Rate limit for new connections established on this frontend. Use 0 value to disable, else value is connections per second. + """ + @dataclass class ZonedApiUpdateHealthCheckRequest: