---
title: "startDiscovery(session:)"
framework: DeviceDiscoveryExtension
role: symbol
role_heading: Instance Method
platforms: [iOS 16.0+, iPadOS 16.0+, macOS 13.0+]
path: "devicediscoveryextension/dddiscoveryextension/startdiscovery(session:)"
---

# startDiscovery(session:)

Begins the extension’s device discovery process.

## Declaration

```swift
func startDiscovery(session: DDDiscoverySession)
```

## Parameters

- `session`: An object that reports discovery events.

## Discussion

Discussion The system controls the discovery process using this function by calling it when AVRoutePickerView displays. You code your extension to search the local network or paired Bluetooth devices for a third-party device of interest that you want the system to include in the picker.

## See Also

### Controlling discovery

- [stopDiscovery(session:)](devicediscoveryextension/dddiscoveryextension/stopdiscovery(session:).md)
