---
title: "clearCredential(with:expectedValues:expectedValueInterval:completionHandler:)"
framework: matter
role: symbol
role_heading: Instance Method
path: "matter/mtrclusterdoorlock/clearcredential(with:expectedvalues:expectedvalueinterval:completionhandler:)"
---

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

## Declaration

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

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