Can I get connected devices to Appium server?

Hello All :slight_smile:

TLDR:
Is there a way to get a list of devices which are connected to Appium server ?

In my setup I’ve multiple devices connected to my Mac but not all devices are connected to Appium server, I would like to get which device is currently connected in order to start the relevant Driver.

I’ve tried to get connected devices via ADB\iDevice for Android\iOS and then to start the Driver then catch the exception and assume that this device is not connected to Appium server.
Is there a better\creative way to get the list of devices ?

Cheers,
Liran

Anyone, please help ?

Thanks!