---
inputType: CA10__CaAwsSnapshot__c
importExtracts:
  - file: "/types/CA10__CaAwsSnapshot__c/object.extracts.yaml"
testData:
  - file: "test-data.json"
conditions:
  - status: "INAPPLICABLE"
    currentStateMessage: "The snapshot is not completed."
    check:
      NOT_EQUAL:
        left:
          EXTRACT: "CA10__state__c"
        right:
          TEXT: "completed"
  - status: "INCOMPLIANT"
    currentStateMessage: "EBS Snapshot is 90 days old or more."
    remediationMessage: "Consider deleting or archiving the old snapshot."
    check:
      IS_BEYOND_LAST_DAYS:
        offsetDays: 90
        arg:
          EXTRACT: "CA10__startTime__c"
otherwise:
  status: "COMPLIANT"
  currentStateMessage: "EBS snapshot is less than 90 days old."
