{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/nice/json-schema/nice-policy-instances-activity-search-response-schema.json",
  "title": "PolicyInstancesActivitySearchResponse",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/nice-policy-policyinstance-openapi.yml#/components/schemas/PolicyInstancesActivitySearchResponse",
  "type": "object",
  "properties": {
    "totalRecords": {
      "type": "number",
      "description": "Total number of records fetched"
    },
    "lastEvaluatedKey": {
      "description": "The value will be empty if records are less than 100 or its last page.",
      "type": "string"
    },
    "records": {
      "type": "array",
      "description": "List of policy instances matching the search criteria",
      "items": {
        "type": "object",
        "properties": {
          "policyId": {
            "type": "string",
            "description": "The Id of the policy"
          },
          "policyInstanceId": {
            "type": "string",
            "description": "The instanceId of the instance of the policy"
          },
          "policyName": {
            "type": "string",
            "description": "The name of the policy"
          },
          "policyType": {
            "type": "string",
            "description": "The type of the policy"
          },
          "lastModificationDate": {
            "type": "string",
            "description": "The last modification date of the policy instance"
          },
          "creationDate": {
            "type": "string",
            "description": "Policy instance creation date"
          },
          "status": {
            "description": "Possible values are PENDING_APPROVAL, SEARCHING, APPLYING_ACTION, SUCCEEDED, PARTIALLY_SUCCEEDED, FAILED, DECLINED, SUCCEEDED_WITH_ZERO_RESULTS, SEARCH_FAILED",
            "type": "string"
          },
          "summaryStatus": {
            "type": "string",
            "description": "Returned in the response only when the policy instance status is COMPLETED."
          },
          "completionDate": {
            "type": "string",
            "description": "Returned in the response only when the policy instance status is COMPLETED."
          },
          "policyInstanceNo": {
            "type": "integer",
            "format": "int32",
            "description": "Sequential number of the policy instance for recurring policies."
          }
        }
      }
    }
  }
}