ListFindings - IAM Access Analyzer

ListFindings

Retrieves a list of findings generated by the specified analyzer. ListFindings and ListFindingsV2 both use access-analyzer:ListFindings in the Action element of an IAM policy statement. You must have permission to perform the access-analyzer:ListFindings action.

To learn about filter keys that you can use to retrieve a list of findings, see IAM Access Analyzer filter keys in the IAM User Guide.

Request Syntax

POST /finding HTTP/1.1 Content-type: application/json { "analyzerArn": "string", "filter": { "string" : { "contains": [ "string" ], "eq": [ "string" ], "exists": boolean, "neq": [ "string" ] } }, "maxResults": number, "nextToken": "string", "sort": { "attributeName": "string", "orderBy": "string" } }

URI Request Parameters

The request does not use any URI parameters.

Request Body

The request accepts the following data in JSON format.

analyzerArn

The ARN of the analyzer to retrieve findings from.

Type: String

Pattern: [^:]*:[^:]*:[^:]*:[^:]*:[^:]*:analyzer/.{1,255}

Required: Yes

filter

A filter to match for the findings to return.

Type: String to Criterion object map

Required: No

maxResults

The maximum number of results to return in the response.

Type: Integer

Required: No

nextToken

A token used for pagination of results returned.

Type: String

Required: No

sort

The sort order for the findings returned.

Type: SortCriteria object

Required: No

Response Syntax

HTTP/1.1 200 Content-type: application/json { "findings": [ { "action": [ "string" ], "analyzedAt": "string", "condition": { "string" : "string" }, "createdAt": "string", "error": "string", "id": "string", "isPublic": boolean, "principal": { "string" : "string" }, "resource": "string", "resourceOwnerAccount": "string", "resourceType": "string", "sources": [ { "detail": { "accessPointAccount": "string", "accessPointArn": "string" }, "type": "string" } ], "status": "string", "updatedAt": "string" } ], "nextToken": "string" }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

findings

A list of findings retrieved from the analyzer that match the filter criteria specified, if any.

Type: Array of FindingSummary objects

nextToken

A token used for pagination of results returned.

Type: String

Errors

For information about the errors that are common to all actions, see Common Errors.

AccessDeniedException

You do not have sufficient access to perform this action.

HTTP Status Code: 403

InternalServerException

Internal server error.

HTTP Status Code: 500

ResourceNotFoundException

The specified resource could not be found.

HTTP Status Code: 404

ThrottlingException

Throttling limit exceeded error.

HTTP Status Code: 429

ValidationException

Validation exception error.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: