Lists the lookup tables in the caller's account and Region. Returns a summary for each table. Content is not included.
Parameters:
-
max_results
(Optional[int], default:
None
)
–
The maximum number of lookup tables to return per page.
-
next_token
(Optional[str], default:
None
)
–
A token to retrieve the next page of results.
Raises:
Examples:
List the lookup tables in an account and Region
The following example returns a page of lookup table summaries. Content is not included. A nextToken is returned when more results are available. Payloads are shown as JSON; on the wire they are CBOR-encoded.
>>> await client.list_lookups(max_results=10)
Source code in docs_src/capo_cloudwatchomni/_services/async_cloud_watch_omni.py
| async def list_lookups(
self,
*,
config_overrides: Optional[AsyncCloudWatchOmniClientConfig] = None,
max_results: Optional[int] = None,
next_token: Optional[str] = None,
) -> "capo_cloudwatchomni.types.list_lookups_response.ListLookupsResponse":
"""Lists the lookup tables in the caller's account and Region. Returns a summary for each table. Content is not included.
Args:
max_results: The maximum number of lookup tables to return per page.
next_token: A token to retrieve the next page of results.
Raises:
capo_cloudwatchomni.errors.internal_server_exception.InternalServerException: An unexpected error occurred while processing the request.
capo_cloudwatchomni.errors.throttling_exception.ThrottlingException: The request was throttled due to exceeding the allowed request rate.
capo_cloudwatchomni.errors.validation_exception.ValidationException: A parameter is specified incorrectly.
capo_cloudwatchomni.errors.UnknownServiceError: The service returned an error code this client does not model.
Examples:
List the lookup tables in an account and Region
The following example returns a page of lookup table summaries. Content is not included. A nextToken is returned when more results are available. Payloads are shown as JSON; on the wire they are CBOR-encoded.
>>> await client.list_lookups(max_results=10)
"""
async def _handler(
req: "AsyncOperationRequest[capo_cloudwatchomni.types.list_lookups_request.ListLookupsRequest]",
) -> AsyncOperationResponse[
"capo_cloudwatchomni.types.list_lookups_response.ListLookupsResponse"
]:
import capo_cloudwatchomni._operations.cloud_watch_omni_frontend.list_lookups
(
output,
http_response,
) = await capo_cloudwatchomni._operations.cloud_watch_omni_frontend.list_lookups.async_list_lookups(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListLookups")
)
input_: capo_cloudwatchomni.types.list_lookups_request.ListLookupsRequest = {}
if max_results is not None:
input_["max_results"] = max_results
if next_token is not None:
input_["next_token"] = next_token
response = await aexecute_pipeline(
AsyncOperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
await response.response.aclose()
return response.output
|