---
title: "subscribe(toAttributePaths:eventPaths:params:queue:reportHandler:subscriptionEstablished:resubscriptionScheduled:)"
framework: matter
role: symbol
role_heading: Instance Method
path: "matter/mtrbasedevice/subscribe(toattributepaths:eventpaths:params:queue:reporthandler:subscriptionestablished:resubscriptionscheduled:)"
---

# subscribe(toAttributePaths:eventPaths:params:queue:reportHandler:subscriptionEstablished:resubscriptionScheduled:)

## Declaration

```swift
func subscribe(toAttributePaths attributePaths: [MTRAttributeRequestPath]?, eventPaths: [MTREventRequestPath]?, params: MTRSubscribeParams?, queue: dispatch_queue_t, reportHandler: @escaping MTRDeviceResponseHandler, subscriptionEstablished: MTRSubscriptionEstablishedHandler?, resubscriptionScheduled: MTRDeviceResubscriptionScheduledHandler? = nil)
```
