diff --git a/DO_OPENAPI_COMMIT_SHA.txt b/DO_OPENAPI_COMMIT_SHA.txt index 2720b78..bc20549 100644 --- a/DO_OPENAPI_COMMIT_SHA.txt +++ b/DO_OPENAPI_COMMIT_SHA.txt @@ -1 +1 @@ -479ee7b +2c75905 diff --git a/src/pydo/aio/operations/_operations.py b/src/pydo/aio/operations/_operations.py index e2d9b25..dce8770 100644 --- a/src/pydo/aio/operations/_operations.py +++ b/src/pydo/aio/operations/_operations.py @@ -89,6 +89,7 @@ build_databases_destroy_cluster_request, build_databases_destroy_replica_request, build_databases_get_ca_request, + build_databases_get_cluster_metrics_credentials_request, build_databases_get_cluster_request, build_databases_get_config_request, build_databases_get_connection_pool_request, @@ -112,6 +113,7 @@ build_databases_patch_config_request, build_databases_promote_replica_request, build_databases_reset_auth_request, + build_databases_update_cluster_metrics_credentials_request, build_databases_update_cluster_size_request, build_databases_update_connection_pool_request, build_databases_update_eviction_policy_request, @@ -75519,6 +75521,14 @@ async def list_clusters( indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing + to the database cluster's node(s). + "port": 0 # Optional. The port on which a + service is listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database @@ -75854,6 +75864,14 @@ async def create_cluster( "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the database + cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. Required. @@ -76044,6 +76062,14 @@ async def create_cluster( "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the + database cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. @@ -76293,6 +76319,14 @@ async def create_cluster( "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the + database cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. @@ -76540,6 +76574,14 @@ async def create_cluster(self, body: Union[JSON, IO], **kwargs: Any) -> JSON: "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the + database cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. @@ -76862,6 +76904,14 @@ async def get_cluster(self, database_cluster_uuid: str, **kwargs: Any) -> JSON: "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the + database cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. @@ -86534,6 +86584,257 @@ async def delete_kafka_topic( return deserialized + @distributed_trace_async + async def get_cluster_metrics_credentials(self, **kwargs: Any) -> JSON: + """Retrieve Database Clusters' Metrics Endpoint Credentials. + + To show the credentials for all database clusters' metrics endpoints, send a GET request to + ``/v2/databases/metrics/credentials``. The result will be a JSON object with a ``credentials`` + key. + + :return: JSON object + :rtype: JSON + :raises ~azure.core.exceptions.HttpResponseError: + + Example: + .. code-block:: python + + # response body for status code(s): 200 + response == { + "credentials": { + "credentials": { + "basic_auth_password": "str", # Optional. basic + authentication password for metrics HTTP endpoint. + "basic_auth_username": "str" # Optional. basic + authentication username for metrics HTTP endpoint. + } + } + } + # response body for status code(s): 404 + response == { + "id": "str", # A short identifier corresponding to the HTTP status code + returned. For example, the ID for a response returning a 404 status code would + be "not_found.". Required. + "message": "str", # A message providing additional information about the + error, including details to help resolve it when possible. Required. + "request_id": "str" # Optional. Optionally, some endpoints may include a + request ID that should be provided when reporting bugs or opening support + tickets to help identify the issue. + } + """ + error_map = { + 404: ResourceNotFoundError, + 409: ResourceExistsError, + 401: lambda response: ClientAuthenticationError(response=response), + 429: HttpResponseError, + 500: HttpResponseError, + } + error_map.update(kwargs.pop("error_map", {}) or {}) + + _headers = kwargs.pop("headers", {}) or {} + _params = kwargs.pop("params", {}) or {} + + cls = kwargs.pop("cls", None) # type: ClsType[JSON] + + request = build_databases_get_cluster_metrics_credentials_request( + headers=_headers, + params=_params, + ) + request.url = self._client.format_url(request.url) # type: ignore + + pipeline_response = await self._client._pipeline.run( # type: ignore # pylint: disable=protected-access + request, stream=False, **kwargs + ) + + response = pipeline_response.http_response + + if response.status_code not in [200, 404]: + map_error( + status_code=response.status_code, response=response, error_map=error_map + ) + raise HttpResponseError(response=response) + + response_headers = {} + if response.status_code == 200: + response_headers["ratelimit-limit"] = self._deserialize( + "int", response.headers.get("ratelimit-limit") + ) + response_headers["ratelimit-remaining"] = self._deserialize( + "int", response.headers.get("ratelimit-remaining") + ) + response_headers["ratelimit-reset"] = self._deserialize( + "int", response.headers.get("ratelimit-reset") + ) + + if response.content: + deserialized = response.json() + else: + deserialized = None + + if response.status_code == 404: + response_headers["ratelimit-limit"] = self._deserialize( + "int", response.headers.get("ratelimit-limit") + ) + response_headers["ratelimit-remaining"] = self._deserialize( + "int", response.headers.get("ratelimit-remaining") + ) + response_headers["ratelimit-reset"] = self._deserialize( + "int", response.headers.get("ratelimit-reset") + ) + + if response.content: + deserialized = response.json() + else: + deserialized = None + + if cls: + return cls(pipeline_response, cast(JSON, deserialized), response_headers) + + return cast(JSON, deserialized) + + @overload + async def update_cluster_metrics_credentials( # pylint: disable=inconsistent-return-statements + self, + body: Optional[JSON] = None, + *, + content_type: str = "application/json", + **kwargs: Any + ) -> None: + """Update Database Clusters' Metrics Endpoint Credentials. + + To update the credentials for all database clusters' metrics endpoints, send a PUT request to + ``/v2/databases/metrics/credentials``. A successful request will receive a 204 No Content + status code with no body in response. + + :param body: Default value is None. + :type body: JSON + :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. + Default value is "application/json". + :paramtype content_type: str + :return: None + :rtype: None + :raises ~azure.core.exceptions.HttpResponseError: + + Example: + .. code-block:: python + + # JSON input template you can fill out and use as your body input. + body = { + "credentials": { + "basic_auth_password": "str", # Optional. basic authentication + password for metrics HTTP endpoint. + "basic_auth_username": "str" # Optional. basic authentication + username for metrics HTTP endpoint. + } + } + """ + + @overload + async def update_cluster_metrics_credentials( # pylint: disable=inconsistent-return-statements + self, + body: Optional[IO] = None, + *, + content_type: str = "application/json", + **kwargs: Any + ) -> None: + """Update Database Clusters' Metrics Endpoint Credentials. + + To update the credentials for all database clusters' metrics endpoints, send a PUT request to + ``/v2/databases/metrics/credentials``. A successful request will receive a 204 No Content + status code with no body in response. + + :param body: Default value is None. + :type body: IO + :keyword content_type: Body Parameter content-type. Content type parameter for binary body. + Default value is "application/json". + :paramtype content_type: str + :return: None + :rtype: None + :raises ~azure.core.exceptions.HttpResponseError: + """ + + @distributed_trace_async + async def update_cluster_metrics_credentials( # pylint: disable=inconsistent-return-statements + self, body: Optional[Union[JSON, IO]] = None, **kwargs: Any + ) -> None: + """Update Database Clusters' Metrics Endpoint Credentials. + + To update the credentials for all database clusters' metrics endpoints, send a PUT request to + ``/v2/databases/metrics/credentials``. A successful request will receive a 204 No Content + status code with no body in response. + + :param body: Is either a model type or a IO type. Default value is None. + :type body: JSON or IO + :keyword content_type: Body Parameter content-type. Known values are: 'application/json'. + Default value is None. + :paramtype content_type: str + :return: None + :rtype: None + :raises ~azure.core.exceptions.HttpResponseError: + """ + error_map = { + 404: ResourceNotFoundError, + 409: ResourceExistsError, + 401: lambda response: ClientAuthenticationError(response=response), + 429: HttpResponseError, + 500: HttpResponseError, + } + error_map.update(kwargs.pop("error_map", {}) or {}) + + _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) + _params = kwargs.pop("params", {}) or {} + + content_type = kwargs.pop( + "content_type", _headers.pop("Content-Type", None) + ) # type: Optional[str] + cls = kwargs.pop("cls", None) # type: ClsType[None] + + content_type = content_type or "application/json" + _json = None + _content = None + if isinstance(body, (IO, bytes)): + _content = body + else: + if body is not None: + _json = body + else: + _json = None + + request = build_databases_update_cluster_metrics_credentials_request( + content_type=content_type, + json=_json, + content=_content, + headers=_headers, + params=_params, + ) + request.url = self._client.format_url(request.url) # type: ignore + + pipeline_response = await self._client._pipeline.run( # type: ignore # pylint: disable=protected-access + request, stream=False, **kwargs + ) + + response = pipeline_response.http_response + + if response.status_code not in [204]: + map_error( + status_code=response.status_code, response=response, error_map=error_map + ) + raise HttpResponseError(response=response) + + response_headers = {} + response_headers["ratelimit-limit"] = self._deserialize( + "int", response.headers.get("ratelimit-limit") + ) + response_headers["ratelimit-remaining"] = self._deserialize( + "int", response.headers.get("ratelimit-remaining") + ) + response_headers["ratelimit-reset"] = self._deserialize( + "int", response.headers.get("ratelimit-reset") + ) + + if cls: + return cls(pipeline_response, None, response_headers) + class DomainsOperations: """ diff --git a/src/pydo/operations/_operations.py b/src/pydo/operations/_operations.py index 5de9fdb..7fd8403 100644 --- a/src/pydo/operations/_operations.py +++ b/src/pydo/operations/_operations.py @@ -280,7 +280,7 @@ def build_apps_list_request( page: int = 1, per_page: int = 20, with_projects: Optional[bool] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -411,7 +411,7 @@ def build_apps_get_logs_active_deployment_request( follow: Optional[bool] = None, type: str = "UNSPECIFIED", pod_connection_timeout: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -554,7 +554,7 @@ def build_apps_get_logs_request( follow: Optional[bool] = None, type: str = "UNSPECIFIED", pod_connection_timeout: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -597,7 +597,7 @@ def build_apps_get_logs_aggregate_request( follow: Optional[bool] = None, type: str = "UNSPECIFIED", pod_connection_timeout: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -636,7 +636,7 @@ def build_apps_get_logs_active_deployment_aggregate_request( follow: Optional[bool] = None, type: str = "UNSPECIFIED", pod_connection_timeout: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -2556,6 +2556,45 @@ def build_databases_delete_kafka_topic_request( return HttpRequest(method="DELETE", url=_url, headers=_headers, **kwargs) +def build_databases_get_cluster_metrics_credentials_request( + **kwargs: Any, +) -> HttpRequest: + _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) + + accept = _headers.pop("Accept", "application/json") + + # Construct URL + _url = "/v2/databases/metrics/credentials" + + # Construct headers + _headers["Accept"] = _SERIALIZER.header("accept", accept, "str") + + return HttpRequest(method="GET", url=_url, headers=_headers, **kwargs) + + +def build_databases_update_cluster_metrics_credentials_request( + **kwargs: Any, +) -> HttpRequest: + _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) + + content_type = kwargs.pop( + "content_type", _headers.pop("Content-Type", None) + ) # type: Optional[str] + accept = _headers.pop("Accept", "application/json") + + # Construct URL + _url = "/v2/databases/metrics/credentials" + + # Construct headers + if content_type is not None: + _headers["Content-Type"] = _SERIALIZER.header( + "content_type", content_type, "str" + ) + _headers["Accept"] = _SERIALIZER.header("accept", accept, "str") + + return HttpRequest(method="PUT", url=_url, headers=_headers, **kwargs) + + def build_domains_list_request( *, per_page: int = 20, page: int = 1, **kwargs: Any ) -> HttpRequest: @@ -2649,7 +2688,7 @@ def build_domains_list_records_request( type: Optional[str] = None, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -2826,7 +2865,7 @@ def build_droplets_list_request( page: int = 1, tag_name: Optional[str] = None, name: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -3804,7 +3843,7 @@ def build_images_list_request( tag_name: Optional[str] = None, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -4412,7 +4451,7 @@ def build_kubernetes_delete_node_request( *, skip_drain: int = 0, replace: int = 0, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -5223,7 +5262,7 @@ def build_monitoring_get_app_memory_percentage_metrics_request( start: str, end: str, app_component: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -5256,7 +5295,7 @@ def build_monitoring_get_app_cpu_percentage_metrics_request( start: str, end: str, app_component: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -5289,7 +5328,7 @@ def build_monitoring_get_app_restart_count_metrics_yml_request( start: str, end: str, app_component: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -5802,7 +5841,7 @@ def build_registry_list_repositories_v2_request( per_page: int = 20, page: int = 1, page_token: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -5841,7 +5880,7 @@ def build_registry_list_repository_tags_request( *, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -5902,7 +5941,7 @@ def build_registry_list_repository_manifests_request( *, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -6265,7 +6304,7 @@ def build_snapshots_list_request( per_page: int = 20, page: int = 1, resource_type: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -6485,7 +6524,7 @@ def build_volumes_list_request( region: Optional[str] = None, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -6983,7 +7022,7 @@ def build_vpcs_list_members_request( resource_type: Optional[str] = None, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> HttpRequest: _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) _params = case_insensitive_dict(kwargs.pop("params", {}) or {}) @@ -8100,7 +8139,7 @@ def update( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an SSH Key's Name. @@ -8163,7 +8202,7 @@ def update( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an SSH Key's Name. @@ -8754,7 +8793,7 @@ def list( page: int = 1, per_page: int = 20, with_projects: Optional[bool] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Apps. @@ -40853,7 +40892,7 @@ def update( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an App. @@ -47953,7 +47992,7 @@ def update( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an App. @@ -60228,7 +60267,7 @@ def get_logs_active_deployment( follow: Optional[bool] = None, type: str = "UNSPECIFIED", pod_connection_timeout: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Retrieve Active Deployment Logs. @@ -61715,7 +61754,7 @@ def create_deployment( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create an App Deployment. @@ -62928,7 +62967,7 @@ def create_deployment( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create an App Deployment. @@ -67958,7 +67997,7 @@ def get_logs( follow: Optional[bool] = None, type: str = "UNSPECIFIED", pod_connection_timeout: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Retrieve Deployment Logs. @@ -68100,7 +68139,7 @@ def get_logs_aggregate( follow: Optional[bool] = None, type: str = "UNSPECIFIED", pod_connection_timeout: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Retrieve Aggregate Deployment Logs. @@ -68238,7 +68277,7 @@ def get_logs_active_deployment_aggregate( follow: Optional[bool] = None, type: str = "UNSPECIFIED", pod_connection_timeout: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Retrieve Active Deployment Aggregate Logs. @@ -73240,7 +73279,7 @@ def assign_alert_destinations( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update destinations for alerts. @@ -73357,7 +73396,7 @@ def assign_alert_destinations( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update destinations for alerts. @@ -73641,7 +73680,7 @@ def create_rollback( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Rollback App. @@ -74867,7 +74906,7 @@ def create_rollback( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Rollback App. @@ -77376,7 +77415,7 @@ def validate_rollback( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Validate App Rollback. @@ -77492,7 +77531,7 @@ def validate_rollback( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Validate App Rollback. @@ -79970,7 +80009,7 @@ def update_endpoints( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a CDN Endpoint. @@ -80047,7 +80086,7 @@ def update_endpoints( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a CDN Endpoint. @@ -80354,7 +80393,7 @@ def purge_cache( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Purge the Cache for an Existing CDN Endpoint. @@ -80408,7 +80447,7 @@ def purge_cache( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Purge the Cache for an Existing CDN Endpoint. @@ -82450,6 +82489,14 @@ def list_clusters(self, *, tag_name: Optional[str] = None, **kwargs: Any) -> JSO indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing + to the database cluster's node(s). + "port": 0 # Optional. The port on which a + service is listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database @@ -82785,6 +82832,14 @@ def create_cluster( "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the database + cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. Required. @@ -82975,6 +83030,14 @@ def create_cluster( "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the + database cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. @@ -83224,6 +83287,14 @@ def create_cluster( "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the + database cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. @@ -83471,6 +83542,14 @@ def create_cluster(self, body: Union[JSON, IO], **kwargs: Any) -> JSON: "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the + database cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. @@ -83793,6 +83872,14 @@ def get_cluster(self, database_cluster_uuid: str, **kwargs: Any) -> JSON: "pending": bool # Optional. A boolean value indicating whether any maintenance is scheduled to be performed in the next window. }, + "metrics_endpoints": [ + { + "host": "str", # Optional. A FQDN pointing to the + database cluster's node(s). + "port": 0 # Optional. The port on which a service is + listening. + } + ], "name": "str", # A unique, human-readable name referring to a database cluster. Required. "num_nodes": 0, # The number of nodes in the database cluster. @@ -84241,7 +84328,7 @@ def patch_config( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update the Database Configuration for an Existing Database. @@ -84287,7 +84374,7 @@ def patch_config( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update the Database Configuration for an Existing Database. @@ -84661,7 +84748,7 @@ def update_online_migration( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Start an Online Migration. @@ -84732,7 +84819,7 @@ def update_online_migration( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Start an Online Migration. @@ -85016,7 +85103,7 @@ def update_region( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Migrate a Database Cluster to a New Region. @@ -85069,7 +85156,7 @@ def update_region( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Migrate a Database Cluster to a New Region. @@ -85238,7 +85325,7 @@ def update_cluster_size( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Resize a Database Cluster. @@ -85295,7 +85382,7 @@ def update_cluster_size( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Resize a Database Cluster. @@ -85578,7 +85665,7 @@ def update_firewall_rules( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update Firewall Rules (Trusted Sources) for a Database. @@ -85647,7 +85734,7 @@ def update_firewall_rules( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update Firewall Rules (Trusted Sources) for a Database. @@ -85818,7 +85905,7 @@ def update_maintenance_window( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Configure a Database Cluster's Maintenance Window. @@ -85874,7 +85961,7 @@ def update_maintenance_window( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Configure a Database Cluster's Maintenance Window. @@ -86325,7 +86412,7 @@ def create_replica( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a Read-only Replica. @@ -86501,7 +86588,7 @@ def create_replica( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a Read-only Replica. @@ -86614,7 +86701,7 @@ def create_replica( self, database_cluster_uuid: str, body: Optional[Union[JSON, IO]] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a Read-only Replica. @@ -87473,7 +87560,7 @@ def add_user( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Add a Database User. @@ -87616,7 +87703,7 @@ def add_user( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Add a Database User. @@ -88156,7 +88243,7 @@ def update_user( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Database User. @@ -88279,7 +88366,7 @@ def update_user( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Database User. @@ -88376,7 +88463,7 @@ def update_user( database_cluster_uuid: str, username: str, body: Union[JSON, IO], - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Database User. @@ -88560,7 +88647,7 @@ def reset_auth( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Reset a Database User's Password or Authentication Method. @@ -88668,7 +88755,7 @@ def reset_auth( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Reset a Database User's Password or Authentication Method. @@ -88762,7 +88849,7 @@ def reset_auth( database_cluster_uuid: str, username: str, body: Union[JSON, IO], - **kwargs: Any + **kwargs: Any, ) -> JSON: """Reset a Database User's Password or Authentication Method. @@ -89054,7 +89141,7 @@ def add( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Add a New Database. @@ -89111,7 +89198,7 @@ def add( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Add a New Database. @@ -89711,7 +89798,7 @@ def add_connection_pool( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Add a New Connection Pool (PostgreSQL). @@ -89923,7 +90010,7 @@ def add_connection_pool( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Add a New Connection Pool (PostgreSQL). @@ -90463,7 +90550,7 @@ def update_connection_pool( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update Connection Pools (PostgreSQL). @@ -90522,7 +90609,7 @@ def update_connection_pool( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update Connection Pools (PostgreSQL). @@ -90564,7 +90651,7 @@ def update_connection_pool( database_cluster_uuid: str, pool_name: str, body: Union[JSON, IO], - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update Connection Pools (PostgreSQL). @@ -90905,7 +90992,7 @@ def update_eviction_policy( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Configure the Eviction Policy for a Redis Cluster. @@ -90960,7 +91047,7 @@ def update_eviction_policy( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Configure the Eviction Policy for a Redis Cluster. @@ -91223,7 +91310,7 @@ def update_sql_mode( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update SQL Mode for a Cluster. @@ -91273,7 +91360,7 @@ def update_sql_mode( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Update SQL Mode for a Cluster. @@ -91436,7 +91523,7 @@ def update_major_version( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Upgrade Major Version for a Database. @@ -91484,7 +91571,7 @@ def update_major_version( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Upgrade Major Version for a Database. @@ -91758,7 +91845,7 @@ def create_kafka_topic( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create Topic for a Kafka Cluster. @@ -92020,7 +92107,7 @@ def create_kafka_topic( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create Topic for a Kafka Cluster. @@ -92185,7 +92272,7 @@ def create_kafka_topic( self, database_cluster_uuid: str, body: Optional[Union[JSON, IO]] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create Topic for a Kafka Cluster. @@ -92670,7 +92757,7 @@ def update_kafka_topic( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Topic for a Kafka Cluster. @@ -92934,7 +93021,7 @@ def update_kafka_topic( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Topic for a Kafka Cluster. @@ -93102,7 +93189,7 @@ def update_kafka_topic( database_cluster_uuid: str, topic_name: str, body: Optional[Union[JSON, IO]] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Topic for a Kafka Cluster. @@ -93455,6 +93542,257 @@ def delete_kafka_topic( return deserialized + @distributed_trace + def get_cluster_metrics_credentials(self, **kwargs: Any) -> JSON: + """Retrieve Database Clusters' Metrics Endpoint Credentials. + + To show the credentials for all database clusters' metrics endpoints, send a GET request to + ``/v2/databases/metrics/credentials``. The result will be a JSON object with a ``credentials`` + key. + + :return: JSON object + :rtype: JSON + :raises ~azure.core.exceptions.HttpResponseError: + + Example: + .. code-block:: python + + # response body for status code(s): 200 + response == { + "credentials": { + "credentials": { + "basic_auth_password": "str", # Optional. basic + authentication password for metrics HTTP endpoint. + "basic_auth_username": "str" # Optional. basic + authentication username for metrics HTTP endpoint. + } + } + } + # response body for status code(s): 404 + response == { + "id": "str", # A short identifier corresponding to the HTTP status code + returned. For example, the ID for a response returning a 404 status code would + be "not_found.". Required. + "message": "str", # A message providing additional information about the + error, including details to help resolve it when possible. Required. + "request_id": "str" # Optional. Optionally, some endpoints may include a + request ID that should be provided when reporting bugs or opening support + tickets to help identify the issue. + } + """ + error_map = { + 404: ResourceNotFoundError, + 409: ResourceExistsError, + 401: lambda response: ClientAuthenticationError(response=response), + 429: HttpResponseError, + 500: HttpResponseError, + } + error_map.update(kwargs.pop("error_map", {}) or {}) + + _headers = kwargs.pop("headers", {}) or {} + _params = kwargs.pop("params", {}) or {} + + cls = kwargs.pop("cls", None) # type: ClsType[JSON] + + request = build_databases_get_cluster_metrics_credentials_request( + headers=_headers, + params=_params, + ) + request.url = self._client.format_url(request.url) # type: ignore + + pipeline_response = self._client._pipeline.run( # type: ignore # pylint: disable=protected-access + request, stream=False, **kwargs + ) + + response = pipeline_response.http_response + + if response.status_code not in [200, 404]: + map_error( + status_code=response.status_code, response=response, error_map=error_map + ) + raise HttpResponseError(response=response) + + response_headers = {} + if response.status_code == 200: + response_headers["ratelimit-limit"] = self._deserialize( + "int", response.headers.get("ratelimit-limit") + ) + response_headers["ratelimit-remaining"] = self._deserialize( + "int", response.headers.get("ratelimit-remaining") + ) + response_headers["ratelimit-reset"] = self._deserialize( + "int", response.headers.get("ratelimit-reset") + ) + + if response.content: + deserialized = response.json() + else: + deserialized = None + + if response.status_code == 404: + response_headers["ratelimit-limit"] = self._deserialize( + "int", response.headers.get("ratelimit-limit") + ) + response_headers["ratelimit-remaining"] = self._deserialize( + "int", response.headers.get("ratelimit-remaining") + ) + response_headers["ratelimit-reset"] = self._deserialize( + "int", response.headers.get("ratelimit-reset") + ) + + if response.content: + deserialized = response.json() + else: + deserialized = None + + if cls: + return cls(pipeline_response, cast(JSON, deserialized), response_headers) + + return cast(JSON, deserialized) + + @overload + def update_cluster_metrics_credentials( # pylint: disable=inconsistent-return-statements + self, + body: Optional[JSON] = None, + *, + content_type: str = "application/json", + **kwargs: Any, + ) -> None: + """Update Database Clusters' Metrics Endpoint Credentials. + + To update the credentials for all database clusters' metrics endpoints, send a PUT request to + ``/v2/databases/metrics/credentials``. A successful request will receive a 204 No Content + status code with no body in response. + + :param body: Default value is None. + :type body: JSON + :keyword content_type: Body Parameter content-type. Content type parameter for JSON body. + Default value is "application/json". + :paramtype content_type: str + :return: None + :rtype: None + :raises ~azure.core.exceptions.HttpResponseError: + + Example: + .. code-block:: python + + # JSON input template you can fill out and use as your body input. + body = { + "credentials": { + "basic_auth_password": "str", # Optional. basic authentication + password for metrics HTTP endpoint. + "basic_auth_username": "str" # Optional. basic authentication + username for metrics HTTP endpoint. + } + } + """ + + @overload + def update_cluster_metrics_credentials( # pylint: disable=inconsistent-return-statements + self, + body: Optional[IO] = None, + *, + content_type: str = "application/json", + **kwargs: Any, + ) -> None: + """Update Database Clusters' Metrics Endpoint Credentials. + + To update the credentials for all database clusters' metrics endpoints, send a PUT request to + ``/v2/databases/metrics/credentials``. A successful request will receive a 204 No Content + status code with no body in response. + + :param body: Default value is None. + :type body: IO + :keyword content_type: Body Parameter content-type. Content type parameter for binary body. + Default value is "application/json". + :paramtype content_type: str + :return: None + :rtype: None + :raises ~azure.core.exceptions.HttpResponseError: + """ + + @distributed_trace + def update_cluster_metrics_credentials( # pylint: disable=inconsistent-return-statements + self, body: Optional[Union[JSON, IO]] = None, **kwargs: Any + ) -> None: + """Update Database Clusters' Metrics Endpoint Credentials. + + To update the credentials for all database clusters' metrics endpoints, send a PUT request to + ``/v2/databases/metrics/credentials``. A successful request will receive a 204 No Content + status code with no body in response. + + :param body: Is either a model type or a IO type. Default value is None. + :type body: JSON or IO + :keyword content_type: Body Parameter content-type. Known values are: 'application/json'. + Default value is None. + :paramtype content_type: str + :return: None + :rtype: None + :raises ~azure.core.exceptions.HttpResponseError: + """ + error_map = { + 404: ResourceNotFoundError, + 409: ResourceExistsError, + 401: lambda response: ClientAuthenticationError(response=response), + 429: HttpResponseError, + 500: HttpResponseError, + } + error_map.update(kwargs.pop("error_map", {}) or {}) + + _headers = case_insensitive_dict(kwargs.pop("headers", {}) or {}) + _params = kwargs.pop("params", {}) or {} + + content_type = kwargs.pop( + "content_type", _headers.pop("Content-Type", None) + ) # type: Optional[str] + cls = kwargs.pop("cls", None) # type: ClsType[None] + + content_type = content_type or "application/json" + _json = None + _content = None + if isinstance(body, (IO, bytes)): + _content = body + else: + if body is not None: + _json = body + else: + _json = None + + request = build_databases_update_cluster_metrics_credentials_request( + content_type=content_type, + json=_json, + content=_content, + headers=_headers, + params=_params, + ) + request.url = self._client.format_url(request.url) # type: ignore + + pipeline_response = self._client._pipeline.run( # type: ignore # pylint: disable=protected-access + request, stream=False, **kwargs + ) + + response = pipeline_response.http_response + + if response.status_code not in [204]: + map_error( + status_code=response.status_code, response=response, error_map=error_map + ) + raise HttpResponseError(response=response) + + response_headers = {} + response_headers["ratelimit-limit"] = self._deserialize( + "int", response.headers.get("ratelimit-limit") + ) + response_headers["ratelimit-remaining"] = self._deserialize( + "int", response.headers.get("ratelimit-remaining") + ) + response_headers["ratelimit-reset"] = self._deserialize( + "int", response.headers.get("ratelimit-reset") + ) + + if cls: + return cls(pipeline_response, None, response_headers) + class DomainsOperations: """ @@ -93584,7 +93922,7 @@ def create( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Domain. @@ -93651,7 +93989,7 @@ def create( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Domain. @@ -94027,7 +94365,7 @@ def list_records( type: Optional[str] = None, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Domain Records. @@ -94189,7 +94527,7 @@ def create_record( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Domain Record. @@ -94263,7 +94601,7 @@ def create_record( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Domain Record. @@ -94616,7 +94954,7 @@ def patch_record( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Domain Record. @@ -94711,7 +95049,7 @@ def patch_record( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Domain Record. @@ -94781,7 +95119,7 @@ def patch_record( domain_name: str, domain_record_id: int, body: Optional[Union[JSON, IO]] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Domain Record. @@ -94941,7 +95279,7 @@ def update_record( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Domain Record. @@ -95036,7 +95374,7 @@ def update_record( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Domain Record. @@ -95106,7 +95444,7 @@ def update_record( domain_name: str, domain_record_id: int, body: Optional[Union[JSON, IO]] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Domain Record. @@ -95389,7 +95727,7 @@ def list( page: int = 1, tag_name: Optional[str] = None, name: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Droplets. @@ -95698,7 +96036,7 @@ def create( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Droplet. @@ -95751,7 +96089,7 @@ def create( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Droplet. @@ -97514,7 +97852,7 @@ def destroy_with_associated_resources_selective( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Selectively Destroy a Droplet and its Associated Resources. @@ -97589,7 +97927,7 @@ def destroy_with_associated_resources_selective( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Selectively Destroy a Droplet and its Associated Resources. @@ -98480,7 +98818,7 @@ def post( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate a Droplet Action. @@ -98617,7 +98955,7 @@ def post( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate a Droplet Action. @@ -98967,7 +99305,7 @@ def post_by_tag( *, tag_name: Optional[str] = None, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Acting on Tagged Droplets. @@ -99058,7 +99396,7 @@ def post_by_tag( *, tag_name: Optional[str] = None, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Acting on Tagged Droplets. @@ -99145,7 +99483,7 @@ def post_by_tag( body: Optional[Union[JSON, IO]] = None, *, tag_name: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Acting on Tagged Droplets. @@ -99661,7 +99999,7 @@ def create( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Firewall. @@ -99911,7 +100249,7 @@ def create( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Firewall. @@ -100498,7 +100836,7 @@ def update( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Firewall. @@ -100754,7 +101092,7 @@ def update( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Firewall. @@ -101259,7 +101597,7 @@ def assign_droplets( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Droplets to a Firewall. @@ -101314,7 +101652,7 @@ def assign_droplets( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Droplets to a Firewall. @@ -101502,7 +101840,7 @@ def delete_droplets( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Droplets from a Firewall. @@ -101557,7 +101895,7 @@ def delete_droplets( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Droplets from a Firewall. @@ -101745,7 +102083,7 @@ def add_tags( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Tags to a Firewall. @@ -101797,7 +102135,7 @@ def add_tags( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Tags to a Firewall. @@ -101985,7 +102323,7 @@ def delete_tags( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Tags from a Firewall. @@ -102037,7 +102375,7 @@ def delete_tags( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Tags from a Firewall. @@ -102225,7 +102563,7 @@ def add_rules( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Rules to a Firewall. @@ -102343,7 +102681,7 @@ def add_rules( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Rules to a Firewall. @@ -102533,7 +102871,7 @@ def delete_rules( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Rules from a Firewall. @@ -102651,7 +102989,7 @@ def delete_rules( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Rules from a Firewall. @@ -103583,7 +103921,7 @@ def create_trigger( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create Trigger. @@ -103675,7 +104013,7 @@ def create_trigger( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create Trigger. @@ -104066,7 +104404,7 @@ def update_trigger( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Trigger. @@ -104156,7 +104494,7 @@ def update_trigger( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Trigger. @@ -104526,7 +104864,7 @@ def list( tag_name: Optional[str] = None, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Images. @@ -105227,7 +105565,7 @@ def update( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an Image. @@ -105345,7 +105683,7 @@ def update( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an Image. @@ -105887,7 +106225,7 @@ def post( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate an Image Action. @@ -105979,7 +106317,7 @@ def post( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate an Image Action. @@ -107601,7 +107939,7 @@ def update_cluster( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Kubernetes Cluster. @@ -107819,7 +108157,7 @@ def update_cluster( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Kubernetes Cluster. @@ -108495,7 +108833,7 @@ def destroy_associated_resources_selective( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Selectively Delete a Cluster and its Associated Resources. @@ -108561,7 +108899,7 @@ def destroy_associated_resources_selective( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Selectively Delete a Cluster and its Associated Resources. @@ -109215,7 +109553,7 @@ def upgrade_cluster( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Upgrade a Kubernetes Cluster. @@ -109266,7 +109604,7 @@ def upgrade_cluster( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Upgrade a Kubernetes Cluster. @@ -109603,7 +109941,7 @@ def add_node_pool( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Add a Node Pool to a Kubernetes Cluster. @@ -109779,7 +110117,7 @@ def add_node_pool( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Add a Node Pool to a Kubernetes Cluster. @@ -110250,7 +110588,7 @@ def update_node_pool( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Node Pool in a Kubernetes Cluster. @@ -110429,7 +110767,7 @@ def update_node_pool( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Node Pool in a Kubernetes Cluster. @@ -110843,7 +111181,7 @@ def delete_node( *, skip_drain: int = 0, replace: int = 0, - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Delete a Node in a Kubernetes Cluster. @@ -110972,7 +111310,7 @@ def recycle_node_pool( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Recycle a Kubernetes Node Pool. @@ -111025,7 +111363,7 @@ def recycle_node_pool( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Recycle a Kubernetes Node Pool. @@ -111433,7 +111771,7 @@ def run_cluster_lint( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Run Clusterlint Checks on a Kubernetes Cluster. @@ -111509,7 +111847,7 @@ def run_cluster_lint( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Run Clusterlint Checks on a Kubernetes Cluster. @@ -111841,7 +112179,7 @@ def add_registry( # pylint: disable=inconsistent-return-statements body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> None: """Add Container Registry to Kubernetes Clusters. @@ -111875,7 +112213,7 @@ def add_registry( # pylint: disable=inconsistent-return-statements body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> None: """Add Container Registry to Kubernetes Clusters. @@ -111979,7 +112317,7 @@ def remove_registry( # pylint: disable=inconsistent-return-statements body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> None: """Remove Container Registry from Kubernetes Clusters. @@ -112013,7 +112351,7 @@ def remove_registry( # pylint: disable=inconsistent-return-statements body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> None: """Remove Container Registry from Kubernetes Clusters. @@ -113157,7 +113495,7 @@ def update( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Load Balancer. @@ -113337,7 +113675,7 @@ def update( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Load Balancer. @@ -113867,7 +114205,7 @@ def add_droplets( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Droplets to a Load Balancer. @@ -113924,7 +114262,7 @@ def add_droplets( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Droplets to a Load Balancer. @@ -114097,7 +114435,7 @@ def remove_droplets( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Droplets from a Load Balancer. @@ -114151,7 +114489,7 @@ def remove_droplets( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Droplets from a Load Balancer. @@ -114318,7 +114656,7 @@ def add_forwarding_rules( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Forwarding Rules to a Load Balancer. @@ -114398,7 +114736,7 @@ def add_forwarding_rules( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Add Forwarding Rules to a Load Balancer. @@ -114567,7 +114905,7 @@ def remove_forwarding_rules( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Forwarding Rules from a Load Balancer. @@ -114647,7 +114985,7 @@ def remove_forwarding_rules( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Remove Forwarding Rules from a Load Balancer. @@ -115772,7 +116110,7 @@ def update_alert_policy( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an Alert Policy. @@ -116015,7 +116353,7 @@ def update_alert_policy( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an Alert Policy. @@ -116574,7 +116912,7 @@ def get_droplet_bandwidth_metrics( direction: str, start: str, end: str, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Get Droplet Bandwidth Metrics. @@ -117678,7 +118016,7 @@ def get_app_memory_percentage_metrics( start: str, end: str, app_component: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Get App Memory Percentage Metrics. @@ -117786,7 +118124,7 @@ def get_app_cpu_percentage_metrics( start: str, end: str, app_component: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Get App CPU Percentage Metrics. @@ -117894,7 +118232,7 @@ def get_app_restart_count_metrics_yml( start: str, end: str, app_component: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Get App Restart Count Metrics. @@ -119263,7 +119601,7 @@ def update( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Project. @@ -119365,7 +119703,7 @@ def update( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Project. @@ -119588,7 +119926,7 @@ def patch( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Patch a Project. @@ -119690,7 +120028,7 @@ def patch( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Patch a Project. @@ -120160,7 +120498,7 @@ def assign_resources( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Assign Resources to a Project. @@ -120228,7 +120566,7 @@ def assign_resources( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Assign Resources to a Project. @@ -121536,7 +121874,7 @@ def update_subscription( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Subscription Tier. @@ -121600,7 +121938,7 @@ def update_subscription( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Subscription Tier. @@ -122235,7 +122573,7 @@ def list_repositories_v2( per_page: int = 20, page: int = 1, page_token: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Container Registry Repositories (V2). @@ -122415,7 +122753,7 @@ def list_repository_tags( *, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Container Registry Repository Tags. @@ -122561,7 +122899,7 @@ def delete_repository_tag( registry_name: str, repository_name: str, repository_tag: str, - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Delete Container Registry Repository Tag. @@ -122679,7 +123017,7 @@ def list_repository_manifests( *, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Container Registry Repository Manifests. @@ -122835,7 +123173,7 @@ def delete_repository_manifest( registry_name: str, repository_name: str, manifest_digest: str, - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Delete Container Registry Repository Manifest. @@ -123344,7 +123682,7 @@ def update_garbage_collection( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Garbage Collection. @@ -123416,7 +123754,7 @@ def update_garbage_collection( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Garbage Collection. @@ -123480,7 +123818,7 @@ def update_garbage_collection( registry_name: str, garbage_collection_uuid: str, body: Union[JSON, IO], - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update Garbage Collection. @@ -124581,7 +124919,7 @@ def post( body: Optional[JSON] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate a Reserved IP Action. @@ -124677,7 +125015,7 @@ def post( body: Optional[IO] = None, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate a Reserved IP Action. @@ -125243,7 +125581,7 @@ def list( per_page: int = 20, page: int = 1, resource_type: Optional[str] = None, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Snapshots. @@ -126410,7 +126748,7 @@ def assign_resources( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Tag a Resource. @@ -126468,7 +126806,7 @@ def assign_resources( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Tag a Resource. @@ -126635,7 +126973,7 @@ def unassign_resources( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Untag a Resource. @@ -126693,7 +127031,7 @@ def unassign_resources( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> Optional[JSON]: """Untag a Resource. @@ -126881,7 +127219,7 @@ def list( region: Optional[str] = None, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List All Block Storage Volumes. @@ -127768,7 +128106,7 @@ def post( per_page: int = 20, page: int = 1, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate A Block Storage Action By Volume Name. @@ -127896,7 +128234,7 @@ def post( per_page: int = 20, page: int = 1, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate A Block Storage Action By Volume Name. @@ -128380,7 +128718,7 @@ def post_by_id( per_page: int = 20, page: int = 1, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate A Block Storage Action By Volume Id. @@ -128526,7 +128864,7 @@ def post_by_id( per_page: int = 20, page: int = 1, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate A Block Storage Action By Volume Id. @@ -128668,7 +129006,7 @@ def post_by_id( *, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Initiate A Block Storage Action By Volume Id. @@ -128896,7 +129234,7 @@ def get( *, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> JSON: """Retrieve an Existing Volume Action. @@ -129437,7 +129775,7 @@ def create( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create Snapshot from a Volume. @@ -129513,7 +129851,7 @@ def create( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create Snapshot from a Volume. @@ -130279,7 +130617,7 @@ def update( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a VPC. @@ -130364,7 +130702,7 @@ def update( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a VPC. @@ -130581,7 +130919,7 @@ def patch( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Partially Update a VPC. @@ -130667,7 +131005,7 @@ def patch( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Partially Update a VPC. @@ -130987,7 +131325,7 @@ def list_members( resource_type: Optional[str] = None, per_page: int = 20, page: int = 1, - **kwargs: Any + **kwargs: Any, ) -> JSON: """List the Member Resources of a VPC. @@ -131593,7 +131931,7 @@ def update_check( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Check. @@ -131666,7 +132004,7 @@ def update_check( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update a Check. @@ -132236,7 +132574,7 @@ def create_alert( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Alert. @@ -132346,7 +132684,7 @@ def create_alert( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Create a New Alert. @@ -132721,7 +133059,7 @@ def update_alert( body: JSON, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an Alert. @@ -132824,7 +133162,7 @@ def update_alert( body: IO, *, content_type: str = "application/json", - **kwargs: Any + **kwargs: Any, ) -> JSON: """Update an Alert.