async def update_traffic_policy_comment(
self,
id: "capo_route_53.types.traffic_policy_id.TrafficPolicyId",
version: "capo_route_53.types.traffic_policy_version.TrafficPolicyVersion",
comment: "capo_route_53.types.traffic_policy_comment.TrafficPolicyComment",
*,
config_overrides: Optional[AsyncRoute53ClientConfig] = None,
) -> "capo_route_53.types.update_traffic_policy_comment_response.UpdateTrafficPolicyCommentResponse":
"""<p>Updates the comment for a specified traffic policy version.</p>
Args:
id: <p>The value of <code>Id</code> for the traffic policy that you want to update the comment for.</p>
version: <p>The value of <code>Version</code> for the traffic policy that you want to update the comment for.</p>
comment: <p>The new comment for the specified traffic policy and version.</p>
Raises:
capo_route_53.errors.concurrent_modification.ConcurrentModification: <p>Another user submitted a request to create, update, or delete the object at the same time that you did. Retry the request. </p>
capo_route_53.errors.invalid_input.InvalidInput: <p>The input is not valid.</p>
capo_route_53.errors.no_such_traffic_policy.NoSuchTrafficPolicy: <p>No traffic policy exists with the specified ID.</p>
capo_route_53.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_route_53.types.update_traffic_policy_comment_request.UpdateTrafficPolicyCommentRequest]",
) -> AsyncOperationResponse[
"capo_route_53.types.update_traffic_policy_comment_response.UpdateTrafficPolicyCommentResponse"
]:
import capo_route_53._operations.aws_dns_v20130401.update_traffic_policy_comment
(
output,
http_response,
) = await capo_route_53._operations.aws_dns_v20130401.update_traffic_policy_comment.async_update_traffic_policy_comment(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("UpdateTrafficPolicyComment")
)
input_: capo_route_53.types.update_traffic_policy_comment_request.UpdateTrafficPolicyCommentRequest = {
"id": id,
"version": version,
"comment": comment,
}
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output