Skip to content

locate_device

Toggle the LED locate beacon on a device.

Side effects:

  • The physical device flashes its status LED until on=False is sent (or it reboots). Helpful for finding which physical AP or switch maps to a controller record.
  • No traffic impact.
  • Mutates controller state. Use dry_run=True to preview the change without applying.
locate_device(mac="aa:bb:cc:00:00:01", on=True)
Parameter Type Required Default Description
mac string yes Device MAC address (from list_devices).
on boolean no true True (default) starts the flash; False stops it.
controller string no “default” Name of the UniFi controller to target. Defaults to "default".
dry_run boolean no false Preview the change without applying it. Returns the predicted change set.