{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/harness/main/json-schema/harness-github-com-harness-hce-saas-graphql-server-pkg-database-mongodb-security-governance-rule-schema.json",
  "title": "github_com_harness_hce-saas_graphql_server_pkg_database_mongodb_security_governance.Rule",
  "x-generated": "2026-10-04",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/harness-chaosguard-rules-api-openapi.yml#/components/schemas/github_com_harness_hce-saas_graphql_server_pkg_database_mongodb_security_governance.Rule",
  "type": "object",
  "required": [
    "conditionIds",
    "name",
    "ruleId",
    "timeWindows",
    "userGroupIds"
  ],
  "properties": {
    "conditionIds": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "description": {
      "type": "string"
    },
    "isEnabled": {
      "type": "boolean"
    },
    "name": {
      "type": "string"
    },
    "ruleId": {
      "type": "string"
    },
    "tags": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "timeWindows": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/security_governance.TimeWindow"
      }
    },
    "userGroupIds": {
      "type": "array",
      "items": {
        "type": "string"
      }
    }
  },
  "$defs": {
    "security_governance.Recurrence": {
      "type": "object",
      "required": [
        "type"
      ],
      "properties": {
        "spec": {
          "$ref": "#/$defs/security_governance.RecurrenceSpec"
        },
        "type": {
          "type": "string",
          "enum": [
            "Yearly",
            "Monthly",
            "Daily",
            "Weekly",
            "None"
          ]
        }
      }
    },
    "security_governance.RecurrenceSpec": {
      "type": "object",
      "properties": {
        "until": {
          "type": "integer"
        },
        "value": {
          "description": "set if recurrenceType is Monthly",
          "type": "integer"
        }
      }
    },
    "security_governance.TimeWindow": {
      "type": "object",
      "required": [
        "startTime",
        "timeZone"
      ],
      "properties": {
        "duration": {
          "type": "string"
        },
        "endTime": {
          "type": "integer"
        },
        "recurrence": {
          "$ref": "#/$defs/security_governance.Recurrence"
        },
        "startTime": {
          "type": "integer"
        },
        "timeZone": {
          "type": "string"
        }
      }
    }
  }
}