Use this operation in a monitoring account to return the list of sinks created in that account.
Parameters:
-
max_results
(Optional[ListSinksMaxResults], default:
None
)
–
Limits the number of returned links to the specified number.
-
next_token
(Optional[NextToken], default:
None
)
–
The token for the next set of items to return. You received this token from a previous call.
Raises:
Source code in docs_src/capo_oam/_services/async_oam.py
| async def list_sinks(
self,
*,
config_overrides: Optional[AsyncOAMClientConfig] = None,
max_results: Optional[
"capo_oam.types.list_sinks_max_results.ListSinksMaxResults"
] = None,
next_token: Optional["capo_oam.types.next_token.NextToken"] = None,
) -> "capo_oam.types.list_sinks_output.ListSinksOutput":
"""<p>Use this operation in a monitoring account to return the list of sinks created in that account.</p>
Args:
max_results: <p>Limits the number of returned links to the specified number.</p>
next_token: <p>The token for the next set of items to return. You received this token from a previous call.</p>
Raises:
capo_oam.errors.internal_service_fault.InternalServiceFault: <p>Unexpected error while processing the request. Retry the request.</p>
capo_oam.errors.invalid_parameter_exception.InvalidParameterException: <p>A parameter is specified incorrectly.</p>
capo_oam.errors.resource_not_found_exception.ResourceNotFoundException: <p>The request references a resource that does not exist.</p>
capo_oam.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_oam.types.list_sinks_input.ListSinksInput]",
) -> AsyncOperationResponse["capo_oam.types.list_sinks_output.ListSinksOutput"]:
import capo_oam._operations.oamservice.list_sinks
(
output,
http_response,
) = await capo_oam._operations.oamservice.list_sinks.async_list_sinks(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListSinks")
)
input_: capo_oam.types.list_sinks_input.ListSinksInput = {}
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
|