We are planning to build an Android app which interacts with a web service. To save the users from the pain of the registration process we were thinking if we could just use the paired Google account of the device as the login key. After all, you cannot download the app from the market without having a Google account.
The requirement guidelines are (not hard requirements)
1) if the user accesses the service outside Android e.g. in web browser we can use the same login
2) if the user swaps the device, removes the app, etc. the data can be retrieved again when the user reinstalls the app
3) the user would not need to type username/password/password again combo when starting the app for the first time
What platform services Android offers for this? What kind of process it is to have an app paired with a Google Account? Any gotchas, like 2 week timeouts which Facebook prefers to do.
What's the relevant documentation and any tutorials?
Thanks!
1) The AccountManager (gdocs) allows to add and "use" (google) accounts on the device (Those that are listed in the settings). Go to 34:00 in the google io talk Android Pro Tips there small introduction. Actually all tips in this session are great.
2) With a SharedPreferencesBackupHelper the settings of your app will be backed up online and automatically restored after a device switch. The preferences are tied to a google account. This service is useful for small amounts of data - some preferences. The data is as secure as the google account or the device and I think it's not encrypted.
3) see 1)