I was working on an app (server-android client) that allow user to sign in from multiple android devices. When user logged in on a device, that device will be registered on server side, but I don't know how to avoid duplicate, so I was wondering that are there any chances to uniquely identify an android device? I think Google Play and Facebook can do that.
This unique ID can be IMEI, MEID, ESN or IMSI. They can be defined as follows : IMEI for International Mobile Equipment Identity : the Unique Number to identify GSM, WCDMA mobile phones as well as some satellite phones.
Android device IDs are determined during the device's first boot. Users can access their devices' randomly generated Android IDs by downloading a free app from Google Play. These device identification numbers should remain constant for the lifetime of the device unless the user performs a factory reset.
A Mobile Device ID is a unique customer identifier used to distinguish a mobile device. It could be an IDFA (Identifier for Advertisers) or an Android Ad Id.
Most mobile devices have a unique ID, also called a Universal Unique Identifier (UUID), assigned at the time of manufacture for identification purposes. For example, iOS devices are assigned what's called a Unique Device Identifier (UDID).
There are several options available, but there is no 100% guarantee that they will always work. See the android developer blog post: http://android-developers.blogspot.in/2011/03/identifying-app-installations.html
Best method mentioned is Settings.Secure.ANDROID_ID
You can check the IMEI
or MAC
address of the device.
for IMEI
TelephonyManager.getDeviceId will work
for MAC
WifiInfo.getMacAddress will work
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With