schemas/policy-definition.schema.json

{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "title": "FPAC Policy Definition",
  "type": "object",
  "required": [
    "$schema",
    "name",
    "properties"
  ],
  "properties": {
    "$schema": {
      "type": "string"
    },
    "name": {
      "type": "string",
      "minLength": 1
    },
    "metadata": {
      "type": "object",
      "properties": {
        "pacOwnerId": {
          "type": "string",
          "minLength": 1,
          "description": "Deprecated legacy field, accepted but ignored. Policies inherit management from their containing Policy Set.",
          "deprecated": true
        }
      },
      "additionalProperties": false
    },
    "properties": {
      "type": "object",
      "required": [
        "displayName",
        "parameters",
        "policy",
        "conditions",
        "effects"
      ],
      "properties": {
        "displayName": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "parameters": {
          "type": "object",
          "additionalProperties": {
            "type": "object",
            "required": [
              "type"
            ],
            "properties": {
              "type": {
                "type": "string"
              },
              "metadata": {
                "type": "object"
              }
            },
            "additionalProperties": false
          }
        },
        "policy": {
          "type": "string"
        },
        "conditions": {
          "type": "array",
          "items": {
            "type": "object"
          }
        },
        "effects": {
          "type": "array",
          "items": {
            "type": "object"
          }
        }
      },
      "additionalProperties": false
    }
  },
  "additionalProperties": false
}