Returns a paginated list of CIDR locations for the given collection (metadata only, does not include CIDR blocks).
Parameters:
-
collection_id
(UUID)
–
-
next_token
(Optional[PaginationToken], default:
None
)
–
An opaque pagination token to indicate where the service is to begin enumerating results.
If no value is provided, the listing of results starts from the beginning.
-
max_results
(Optional[int], default:
None
)
–
The maximum number of CIDR collection locations to return in the response.
Raises:
Source code in docs_src/capo_route_53/_services/async_route53.py
| async def list_cidr_locations(
self,
collection_id: "capo_route_53.types.uuid.UUID",
*,
config_overrides: Optional[AsyncRoute53ClientConfig] = None,
next_token: Optional[
"capo_route_53.types.pagination_token.PaginationToken"
] = None,
max_results: Optional[int] = None,
) -> "capo_route_53.types.list_cidr_locations_response.ListCidrLocationsResponse":
"""<p>Returns a paginated list of CIDR locations for the given collection (metadata only, does not include CIDR blocks).</p>
Args:
collection_id: <p>The CIDR collection ID.</p>
next_token: <p>An opaque pagination token to indicate where the service is to begin enumerating results.</p> <p>If no value is provided, the listing of results starts from the beginning.</p>
max_results: <p>The maximum number of CIDR collection locations to return in the response.</p>
Raises:
capo_route_53.errors.invalid_input.InvalidInput: <p>The input is not valid.</p>
capo_route_53.errors.no_such_cidr_collection_exception.NoSuchCidrCollectionException: <p>The CIDR collection you specified, doesn't exist.</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.list_cidr_locations_request.ListCidrLocationsRequest]",
) -> AsyncOperationResponse[
"capo_route_53.types.list_cidr_locations_response.ListCidrLocationsResponse"
]:
import capo_route_53._operations.aws_dns_v20130401.list_cidr_locations
(
output,
http_response,
) = await capo_route_53._operations.aws_dns_v20130401.list_cidr_locations.async_list_cidr_locations(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListCidrLocations")
)
input_: capo_route_53.types.list_cidr_locations_request.ListCidrLocationsRequest = {
"collection_id": collection_id
}
if next_token is not None:
input_["next_token"] = next_token
if max_results is not None:
input_["max_results"] = max_results
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|