<!--
{
  "availability" : [
    "iOS: 26.0.0 -",
    "iPadOS: 26.0.0 -",
    "macCatalyst: 26.0.0 -",
    "tvOS: 16.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "DeviceDiscoveryUI",
  "identifier" : "/documentation/DeviceDiscoveryUI/DDDevicePickerViewController/endpoint",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Property",
  "symbol" : {
    "kind" : "Instance Property",
    "modules" : [
      "DeviceDiscoveryUI"
    ],
    "preciseIdentifier" : "s:So28DDDevicePickerViewControllerC17DeviceDiscoveryUIE8endpoint7Network10NWEndpointOvp"
  },
  "title" : "endpoint"
}
-->

# endpoint

A network connection endpoint for the device that a person selected.

```
@MainActor @preconcurrency var endpoint: NWEndpoint { get async throws }
```

## Discussion

Your app can asynchronously read from this property. The system populates this property when someone selects a device from the endpoint picker. If someone cancels the picker, the system throws an error.

```swift
let endpoint: NWEndpoint
do {
    endpoint = try await myEndpointPickerHandler.endpoint
} catch {
    // Someone canceled the endpoint picker view.
    return
}

// Use the endpoint here.
myDeviceConnectionManager.connectTo(endpoint: endpoint)
```

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)