Get Device Unique Id
To obtain the UDID of your device, you can follow these steps:
- Connect your device to your computer using a USB cable.
- Open your terminal or command prompt.
- Run the command
idevice_id -l
to obtain the ID of the connected device. This command will list the connected device's ID. - Run the command
ideviceinfo -u [device ID obtained in step 3]
. Replace[device ID obtained in step 3]
with the actual device ID. - Look for the
UniqueDeviceID:
field in the output. The UDID will be displayed next to it.
Alternatively, you can use the following one-line command to achieve the same result:
ideviceinfo -u $(idevice_id -l) | awk '/UniqueDeviceID:/ {print $2}'
This command combines the previous steps into a single command, making it more convenient to obtain the UDID of your device.
Using either method, you will be able to retrieve the UDID of your device for further use or reference.