"use strict";
var __defProp = Object.defineProperty;
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
var __getOwnPropNames = Object.getOwnPropertyNames;
var __hasOwnProp = Object.prototype.hasOwnProperty;
var __export = (target, all) => {
  for (var name in all)
    __defProp(target, name, { get: all[name], enumerable: true });
};
var __copyProps = (to, from, except, desc) => {
  if (from && typeof from === "object" || typeof from === "function") {
    for (let key of __getOwnPropNames(from))
      if (!__hasOwnProp.call(to, key) && key !== except)
        __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
  }
  return to;
};
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
var commissioner_control_element_exports = {};
__export(commissioner_control_element_exports, {
  CommissionerControl: () => CommissionerControl
});
module.exports = __toCommonJS(commissioner_control_element_exports);
var import_MatterDefinition = require("../MatterDefinition.js");
var import_elements = require("../../elements/index.js");
/**
 * @license
 * Copyright 2022-2025 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
const CommissionerControl = (0, import_elements.ClusterElement)(
  { name: "CommissionerControl", id: 1873, classification: "node" },
  (0, import_elements.AttributeElement)({ name: "ClusterRevision", id: 65533, type: "ClusterRevision", default: 1 }),
  (0, import_elements.AttributeElement)({
    name: "SupportedDeviceCategories",
    id: 0,
    type: "SupportedDeviceCategoryBitmap",
    access: "R M",
    conformance: "M",
    default: 0
  }),
  (0, import_elements.EventElement)(
    { name: "CommissioningRequestResult", id: 0, access: "S M", conformance: "M", priority: "info" },
    (0, import_elements.FieldElement)({ name: "RequestId", id: 0, type: "uint64", access: "S", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "ClientNodeId", id: 1, type: "node-id", access: "S", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "StatusCode", id: 2, type: "status", access: "S", conformance: "M", constraint: "desc" }),
    (0, import_elements.FieldElement)({ name: "FabricIndex", id: 254, type: "FabricIndex" })
  ),
  (0, import_elements.CommandElement)(
    {
      name: "RequestCommissioningApproval",
      id: 0,
      access: "M",
      conformance: "M",
      direction: "request",
      response: "status"
    },
    (0, import_elements.FieldElement)({ name: "RequestId", id: 0, type: "uint64", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "VendorId", id: 1, type: "vendor-id", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "ProductId", id: 2, type: "uint16", conformance: "M" }),
    (0, import_elements.FieldElement)({ name: "Label", id: 3, type: "string", conformance: "O", constraint: "max 64" })
  ),
  (0, import_elements.CommandElement)(
    {
      name: "CommissionNode",
      id: 1,
      access: "M",
      conformance: "M",
      direction: "request",
      response: "ReverseOpenCommissioningWindow"
    },
    (0, import_elements.FieldElement)({ name: "RequestId", id: 0, type: "uint64", conformance: "M" }),
    (0, import_elements.FieldElement)({
      name: "ResponseTimeoutSeconds",
      id: 1,
      type: "uint16",
      conformance: "M",
      constraint: "30 to 120",
      default: 30
    })
  ),
  (0, import_elements.CommandElement)(
    { name: "ReverseOpenCommissioningWindow", id: 2, conformance: "M", direction: "response" },
    (0, import_elements.FieldElement)({ name: "CommissioningTimeout", id: 0, type: "uint16", conformance: "M", constraint: "desc" }),
    (0, import_elements.FieldElement)({ name: "PakePasscodeVerifier", id: 1, type: "octstr", conformance: "M", constraint: "97" }),
    (0, import_elements.FieldElement)({ name: "Discriminator", id: 2, type: "uint16", conformance: "M", constraint: "max 4095" }),
    (0, import_elements.FieldElement)({ name: "Iterations", id: 3, type: "uint32", conformance: "M", constraint: "1000 to 100000" }),
    (0, import_elements.FieldElement)({ name: "Salt", id: 4, type: "octstr", conformance: "M", constraint: "16 to 32" })
  ),
  (0, import_elements.DatatypeElement)(
    { name: "SupportedDeviceCategoryBitmap", type: "map32" },
    (0, import_elements.FieldElement)({ name: "FabricSynchronization", constraint: "0" })
  )
);
import_MatterDefinition.MatterDefinition.children.push(CommissionerControl);
//# sourceMappingURL=commissioner-control.element.js.map
