Lists Organizational Reports owned by the caller's account within the caller's AWS Organization, ordered by most recently created first. Supports pagination and an optional state filter.
Parameters:
-
max_results
(Optional[MaxResults], default:
None
)
–
Maximum number of items to return in a single page. Defaults to 100.
-
next_token
(Optional[NextToken], default:
None
)
–
Pagination token from a previous ListAgentOrganizationalReports response. Absent on the first page.
-
state
(Optional[OrganizationalReportState], default:
None
)
–
Optional filter restricting the response to reports in a single lifecycle state.
Raises:
Source code in docs_src/capo_wellarchitected/_services/well_architected.py
| def list_agent_organizational_reports(
self,
*,
config_overrides: Optional[WellArchitectedClientConfig] = None,
max_results: Optional[
"capo_wellarchitected.types.max_results.MaxResults"
] = None,
next_token: Optional["capo_wellarchitected.types.next_token.NextToken"] = None,
state: Optional[
"capo_wellarchitected.types.organizational_report_state.OrganizationalReportState"
] = None,
) -> "capo_wellarchitected.types.list_agent_organizational_reports_response.ListAgentOrganizationalReportsResponse":
"""<p>Lists Organizational Reports owned by the caller's account within the caller's AWS Organization, ordered by most recently created first. Supports pagination and an optional state filter.</p>
Args:
max_results: <p>Maximum number of items to return in a single page. Defaults to 100.</p>
next_token: <p>Pagination token from a previous ListAgentOrganizationalReports response. Absent on the first page.</p>
state: <p>Optional filter restricting the response to reports in a single lifecycle state.</p>
Raises:
capo_wellarchitected.errors.access_denied_exception.AccessDeniedException: <p>User does not have sufficient access to perform this action.</p>
capo_wellarchitected.errors.internal_server_exception.InternalServerException: <p>There is a problem with the Well-Architected Tool API service.</p>
capo_wellarchitected.errors.throttling_exception.ThrottlingException: <p>Request was denied due to request throttling.</p>
capo_wellarchitected.errors.validation_exception.ValidationException: <p>The user input is not valid.</p>
capo_wellarchitected.errors.UnknownServiceError: The service returned an error code this client does not model.
"""
def _handler(
req: "OperationRequest[capo_wellarchitected.types.list_agent_organizational_reports_request.ListAgentOrganizationalReportsRequest]",
) -> OperationResponse[
"capo_wellarchitected.types.list_agent_organizational_reports_response.ListAgentOrganizationalReportsResponse"
]:
import capo_wellarchitected._operations.well_architected_api_service_lambda.list_agent_organizational_reports
output, http_response = (
capo_wellarchitected._operations.well_architected_api_service_lambda.list_agent_organizational_reports.list_agent_organizational_reports(
req.options, req.input
)
)
return OperationResponse(output=output, response=http_response)
interceptors_, options_ = self.operation_options(
config_overrides, OperationLogging("ListAgentOrganizationalReports")
)
input_: capo_wellarchitected.types.list_agent_organizational_reports_request.ListAgentOrganizationalReportsRequest = {}
if max_results is not None:
input_["max_results"] = max_results
if next_token is not None:
input_["next_token"] = next_token
if state is not None:
input_["state"] = state
response = execute_pipeline(
OperationRequest(input=input_, options=options_),
handler=_handler,
interceptors=list(interceptors_),
)
response.response.close()
return response.output
|