list_tasks
async
¶
list_tasks(
environment_arn: EnvironmentArn,
project: ProjectName,
*,
config_overrides: Optional[AsyncAssuranceClientConfig] = None,
filters: Optional[TaskFilterList] = None,
max_results: Optional[MaxResults] = None,
next_token: Optional[PaginationToken] = None,
) -> ListTasksOutput
Lists all tasks within a governance environment.
Parameters:
-
environment_arn(EnvironmentArn) –The ARN of this governance environment.
-
project(ProjectName) –The project to list tasks for. Each request is scoped to one project.
-
filters(Optional[TaskFilterList], default:None) –The response filter criteria. Optional. See
TaskFilterNamefor the filterable attributes. A result must match every attribute you name, and matches if it equals any of the values you give for that attribute. Omittingfiltersreturns every task in the project.A single-valued criterion for
framework,framework-version, orcontrol-idnarrows the results when every broader component is also supplied. When a broader component is absent, the criterion is applied to the returned results.An
assessment-idcriterion returns the task history for that assessment. It accepts one value and requires single-valuedframework,framework-version, andcontrol-idcriteria alongside it. -
max_results(Optional[MaxResults], default:None) –The maximum number of records to return on one page. If you omit it, the operation uses its default page size. If more records are available, use the
nextTokenvalue from the response to get the next page. -
next_token(Optional[PaginationToken], default:None) –The pagination token returned by a previous request. Use it to retrieve the next page of results. If the value is null, there are no more results to return.
Raises:
-
AccessDeniedException–You do not have sufficient access to perform this action. This error occurs when the request is unauthenticated, or is authenticated but lacks permission to invoke the operation.
-
InternalServerException–An internal server error occurred.
-
ResourceNotFoundException–The requested resource was not found.
-
ThrottlingException–The request was throttled.
-
ValidationException–The request failed validation.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
List open tasks in a project Lists the open tasks in the payments-prod project so the team can see the remaining PCI-DSS remediation work.
>>> await client.list_tasks(environment_arn='arn:aws:assurance:us-east-1:111122223333:environment/a1b2c3d4-5678-90ab-cdef-EXAMPLE11111', project='payments-prod', filters=[{'name': 'status', 'values': ['OPEN']}], max_results=20)
Source code in docs_src/capo_assurance/_services/async_assurance.py
6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 | |