---
title: "keySetWrite(with:expectedValues:expectedValueInterval:completionHandler:)"
framework: matter
role: symbol
role_heading: Instance Method
path: "matter/mtrclustergroupkeymanagement/keysetwrite(with:expectedvalues:expectedvalueinterval:completionhandler:)"
---

# keySetWrite(with:expectedValues:expectedValueInterval:completionHandler:)

## Declaration

```swift
func keySetWrite(with params: MTRGroupKeyManagementClusterKeySetWriteParams, expectedValues expectedDataValueDictionaries: [[String : Any]]?, expectedValueInterval expectedValueIntervalMs: NSNumber?, completionHandler: @escaping @Sendable ((any Error)?) -> Void)
```

```swift
func keySetWrite(with params: MTRGroupKeyManagementClusterKeySetWriteParams, expectedValues expectedDataValueDictionaries: [[String : Any]]?, expectedValueInterval expectedValueIntervalMs: NSNumber?) async throws
```
