{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/azure-networking-services/json-schema/azure-networking-services-base-admin-rule-schema.json",
  "title": "BaseAdminRule",
  "description": "Network base admin rule.",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/azure-networking-services-adminrules-api-openapi.yml#/components/schemas/BaseAdminRule",
  "type": "object",
  "properties": {
    "systemData": {
      "$ref": "#/$defs/systemData",
      "description": "The system metadata related to this resource.",
      "readOnly": true
    },
    "kind": {
      "$ref": "#/$defs/AdminRuleKind",
      "description": "Whether the rule is custom or default."
    }
  },
  "required": [
    "kind"
  ],
  "allOf": [
    {
      "$ref": "#/$defs/ChildResource"
    }
  ],
  "$defs": {
    "AdminRuleKind": {
      "type": "string",
      "description": "Whether the rule is custom or default.",
      "enum": [
        "Custom",
        "Default"
      ],
      "x-ms-enum": {
        "name": "AdminRuleKind",
        "modelAsString": true,
        "values": [
          {
            "name": "Custom",
            "value": "Custom",
            "description": "Custom"
          },
          {
            "name": "Default",
            "value": "Default",
            "description": "Default"
          }
        ]
      }
    },
    "ChildResource": {
      "type": "object",
      "description": "Proxy resource representation.",
      "properties": {
        "id": {
          "type": "string",
          "description": "Resource ID.",
          "readOnly": true
        },
        "name": {
          "type": "string",
          "description": "Resource name.",
          "readOnly": true
        },
        "type": {
          "type": "string",
          "description": "Resource type.",
          "readOnly": true
        },
        "etag": {
          "type": "string",
          "description": "A unique read-only string that changes whenever the resource is updated.",
          "readOnly": true
        }
      },
      "x-ms-azure-resource": true
    },
    "systemData": {
      "type": "object",
      "description": "Metadata pertaining to creation and last modification of the resource.",
      "properties": {
        "createdBy": {
          "type": "string",
          "description": "The identity that created the resource."
        },
        "createdByType": {
          "type": "string",
          "description": "The type of identity that created the resource.",
          "enum": [
            "User",
            "Application",
            "ManagedIdentity",
            "Key"
          ],
          "x-ms-enum": {
            "name": "createdByType",
            "modelAsString": true
          }
        },
        "createdAt": {
          "type": "string",
          "format": "date-time",
          "description": "The timestamp of resource creation (UTC)."
        },
        "lastModifiedBy": {
          "type": "string",
          "description": "The identity that last modified the resource."
        },
        "lastModifiedByType": {
          "type": "string",
          "description": "The type of identity that last modified the resource.",
          "enum": [
            "User",
            "Application",
            "ManagedIdentity",
            "Key"
          ],
          "x-ms-enum": {
            "name": "createdByType",
            "modelAsString": true
          }
        },
        "lastModifiedAt": {
          "type": "string",
          "format": "date-time",
          "description": "The timestamp of resource last modification (UTC)"
        }
      },
      "readOnly": true
    }
  }
}