Returns the list of behavior graphs that the calling account is an administrator account of. This operation can only be called by an administrator account.
Because an account can currently only be the administrator of one behavior graph within a Region, the results always contain a single behavior graph.
Parameters:
-
next_token
(Optional[PaginationToken], default:
None
)
–
For requests to get the next page of results, the pagination token that was returned with the previous set of results. The initial request does not include a pagination token.
-
max_results
(Optional[MemberResultsLimit], default:
None
)
–
The maximum number of graphs to return at a time. The total must be less than the overall limit on the number of results to return, which is currently 200.
Raises:
Source code in docs_src/capo_detective/_services/async_detective.py
| async def list_graphs(
self,
*,
config_overrides: Optional[AsyncDetectiveClientConfig] = None,
next_token: Optional[
"capo_detective.types.pagination_token.PaginationToken"
] = None,
max_results: Optional[
"capo_detective.types.member_results_limit.MemberResultsLimit"
] = None,
) -> "capo_detective.types.list_graphs_response.ListGraphsResponse":
"""<p>Returns the list of behavior graphs that the calling account is an administrator account of. This operation can only be called by an administrator account.</p> <p>Because an account can currently only be the administrator of one behavior graph within a Region, the results always contain a single behavior graph.</p>
Args:
next_token: <p>For requests to get the next page of results, the pagination token that was returned with the previous set of results. The initial request does not include a pagination token.</p>
max_results: <p>The maximum number of graphs to return at a time. The total must be less than the overall limit on the number of results to return, which is currently 200.</p>
Raises:
capo_detective.errors.access_denied_exception.AccessDeniedException: <p>The request issuer does not have permission to access this resource or perform this operation.</p>
capo_detective.errors.internal_server_exception.InternalServerException: <p>The request was valid but failed because of a problem with the service.</p>
capo_detective.errors.validation_exception.ValidationException: <p>The request parameters are invalid.</p>
capo_detective.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
async def _handler(
req: "AsyncOperationRequest[capo_detective.types.list_graphs_request.ListGraphsRequest]",
) -> AsyncOperationResponse[
"capo_detective.types.list_graphs_response.ListGraphsResponse"
]:
import capo_detective._operations.amazon_detective.list_graphs
(
output,
http_response,
) = await capo_detective._operations.amazon_detective.list_graphs.async_list_graphs(
req.options, req.input
)
return AsyncOperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListGraphs")
)
input_: capo_detective.types.list_graphs_request.ListGraphsRequest = {}
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
|