{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/instaclustr/json-schema/instaclustr-kafka-acl-list-v3-schema.json",
  "title": "KafkaAclListV3",
  "description": "List of access control lists for a Kafka cluster.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/instaclustr-apache-kafka-acl-v3-api-openapi.yml#/components/schemas/KafkaAclListV3",
  "required": [
    "acls",
    "clusterId",
    "userQuery"
  ],
  "type": "object",
  "properties": {
    "currentOperationStatus": {
      "$ref": "#/$defs/CurrentOperationStatus"
    },
    "acls": {
      "type": "array",
      "description": "List of ACLs for the given principal.",
      "items": {
        "$ref": "#/$defs/KafkaAclV2"
      },
      "x-terraform-field-name": "acl",
      "x-terraform-ignore-order": true
    },
    "userQuery": {
      "type": "string",
      "description": "This is the principal without the `User:` prefix.",
      "x-terraform-force-new": true
    },
    "clusterId": {
      "type": "string",
      "description": "UUID of the Kafka cluster.",
      "format": "uuid",
      "x-terraform-force-new": true
    },
    "id": {
      "type": "string",
      "description": "Instaclustr identifier for the ACL list for a principal. The value of this property has the form: [clusterId]_[principalUserQuery]\nThe user query is the principal value without the leading `User:`.",
      "readOnly": true,
      "x-terraform-force-new": true,
      "x-terraform-id": true
    }
  },
  "$defs": {
    "CurrentOperationStatus": {
      "type": "string",
      "description": "Indicates if the cluster is currently performing any operation such as being created, updated, or deleted",
      "enum": [
        "NO_OPERATION",
        "OPERATION_IN_PROGRESS",
        "OPERATION_FAILED"
      ],
      "x-insta-tf-import-hidden": true,
      "x-terraform-field-status": true
    },
    "KafkaAclV2": {
      "title": "Root Type for KafkaAclV2",
      "required": [
        "host",
        "operation",
        "patternType",
        "permissionType",
        "principal",
        "resourceName",
        "resourceType"
      ],
      "type": "object",
      "properties": {
        "principal": {
          "pattern": "^User:[a-zA-Z0-9][a-zA-Z0-9_-]*$",
          "type": "string",
          "description": "Specifies the users(s) for which this ACL applies and can include the wildcard `*`. Valid values must start with \"User:\" including the wildcard."
        },
        "permissionType": {
          "type": "string",
          "description": "Specifies whether to allow or deny the operation.",
          "enum": [
            "ALLOW",
            "DENY"
          ]
        },
        "host": {
          "type": "string",
          "description": "The IP address to which this ACL applies. It takes any string including the wildcard `*` for all IP addresses."
        },
        "patternType": {
          "type": "string",
          "description": "Indicates the resource-pattern-type",
          "enum": [
            "LITERAL",
            "PREFIXED"
          ]
        },
        "resourceName": {
          "type": "string",
          "description": "Any string that fits the resource name, e.g. topic name if the resource type is TOPIC"
        },
        "operation": {
          "type": "string",
          "description": "The operation that will be allowed or denied.",
          "enum": [
            "ALL",
            "READ",
            "WRITE",
            "CREATE",
            "DELETE",
            "ALTER",
            "DESCRIBE",
            "CLUSTER_ACTION",
            "DESCRIBE_CONFIGS",
            "ALTER_CONFIGS",
            "IDEMPOTENT_WRITE"
          ]
        },
        "resourceType": {
          "type": "string",
          "description": "Specifies the type of resource.",
          "enum": [
            "CLUSTER",
            "TOPIC",
            "GROUP",
            "DELEGATION_TOKEN",
            "TRANSACTIONAL_ID"
          ]
        }
      },
      "description": "Definition of a Kafka access control list."
    }
  }
}