Returns a paginated list of CIDR collections in the Amazon Web Services account (metadata only).
Parameters:
-
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 collections to return in the response.
Raises:
Source code in docs_src/capo_route_53/_services/async_route53.py
| async def list_cidr_collections(
self,
*,
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_collections_response.ListCidrCollectionsResponse"
):
"""<p>Returns a paginated list of CIDR collections in the Amazon Web Services account (metadata only).</p>
Args:
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 collections 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.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_route_53.types.list_cidr_collections_request.ListCidrCollectionsRequest]",
) -> AsyncOperationResponse[
"capo_route_53.types.list_cidr_collections_response.ListCidrCollectionsResponse"
]:
import capo_route_53._operations.aws_dns_v20130401.list_cidr_collections
(
output,
http_response,
) = await capo_route_53._operations.aws_dns_v20130401.list_cidr_collections.async_list_cidr_collections(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListCidrCollections")
)
input_: capo_route_53.types.list_cidr_collections_request.ListCidrCollectionsRequest = {}
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
|