---
title: "setActiveDatasetRequestWith(_:completion:)"
framework: matter
role: symbol
role_heading: Instance Method
path: "matter/mtrbaseclusterthreadborderroutermanagement/setactivedatasetrequestwith(_:completion:)"
---

# setActiveDatasetRequestWith(_:completion:)

Command SetActiveDatasetRequest

## Declaration

```swift
func setActiveDatasetRequestWith(_ params: MTRThreadBorderRouterManagementClusterSetActiveDatasetRequestParams, completion: @escaping @Sendable ((any Error)?) -> Void)
```

```swift
func setActiveDatasetRequestWith(_ params: MTRThreadBorderRouterManagementClusterSetActiveDatasetRequestParams) async throws
```

## Discussion

Discussion This command SHALL be used to set the active Dataset of the Thread network to which the Border Router is connected, when there is no active dataset already.
