Some people suggested the serial number others mentioned the MAC address, what I want is something that uniquely identifies an android device whether it is a phone, tablet or watch. My app itself is for wearable devices, I am supposed to make it send the location among some other data when the app is used but I need something to be able to tell the different watches apart.
Any links or resources that go on how this can be done is appreciated, but I ask for it to be something up to date because most things I found are decade old.
With the current restrictions in android Serial number and MAC address are locked down among other items that people have used for unique device id.
The recommended method is to use Instance ID but be aware that this can change so you have to have a mechanism to update it.
Another method you can use is to create a file on the device that has some unique ID in it that you can look for but the file can always be messed with by a user so you have to be aware of that too