{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-iam-access-analyzer/json-schema/amazon-iam-access-analyzer-list-findings-response-schema.json",
  "title": "ListFindingsResponse",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-iam-access-analyzer-finding-api-openapi.yml#/components/schemas/ListFindingsResponse",
  "type": "object",
  "properties": {
    "findings": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/FindingSummary"
      },
      "description": "A list of findings retrieved from the analyzer that match the filter criteria specified, if any."
    },
    "nextToken": {
      "type": "string",
      "description": "A token used for pagination of results returned."
    }
  },
  "required": [
    "findings"
  ],
  "$defs": {
    "FindingSource": {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "description": "Indicates the type of access that generated the finding."
        },
        "detail": {
          "$ref": "#/$defs/FindingSourceDetail"
        }
      },
      "required": [
        "type"
      ]
    },
    "FindingSourceDetail": {
      "type": "object",
      "properties": {
        "accessPointArn": {
          "type": "string",
          "description": "The ARN of the access point that generated the finding. The ARN format depends on whether the ARN represents an access point or a multi-region access point."
        },
        "accessPointAccount": {
          "type": "string",
          "description": "The account of the cross-account access point that generated the finding."
        }
      }
    },
    "FindingSummary": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "The ID of the finding."
        },
        "principal": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "The external principal that has access to a resource within the zone of trust."
        },
        "action": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "The action in the analyzed policy statement that an external principal has permission to use."
        },
        "resource": {
          "type": "string",
          "description": "The resource that the external principal has access to."
        },
        "isPublic": {
          "type": "boolean",
          "description": "Indicates whether the finding reports a resource that has a policy that allows public access."
        },
        "resourceType": {
          "type": "string",
          "description": "The type of the resource that the external principal has access to."
        },
        "condition": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          },
          "description": "The condition in the analyzed policy statement that resulted in a finding."
        },
        "createdAt": {
          "type": "string",
          "format": "date-time",
          "description": "The time at which the finding was created."
        },
        "analyzedAt": {
          "type": "string",
          "format": "date-time",
          "description": "The time at which the resource-based policy that generated the finding was analyzed."
        },
        "updatedAt": {
          "type": "string",
          "format": "date-time",
          "description": "The time at which the finding was most recently updated."
        },
        "status": {
          "type": "string",
          "description": "The status of the finding."
        },
        "resourceOwnerAccount": {
          "type": "string",
          "description": "The Amazon Web Services account ID that owns the resource."
        },
        "error": {
          "type": "string",
          "description": "The error that resulted in an Error finding."
        },
        "sources": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/FindingSource"
          },
          "description": "The sources of the finding. This indicates how the access that generated the finding is granted. It is populated for Amazon S3 bucket findings."
        },
        "resourceControlPolicyRestriction": {
          "type": "string",
          "description": "The type of restriction applied to the finding by the resource owner with an Organizations resource control policy (RCP)."
        }
      },
      "required": [
        "id",
        "resourceType",
        "condition",
        "createdAt",
        "analyzedAt",
        "updatedAt",
        "status",
        "resourceOwnerAccount"
      ]
    }
  }
}