I have created a custom account type for two applications that I am developing. Now I am looking for a way for both apps to take advantage of this single account service. The documentation recommends the following.
One solution is to place the service in one small, special-purpose APK. When an app wishes to use your custom account type, it can check the device to see if your custom account service is available. If not, it can direct the user to Google Play to download the service. This may seem like a great deal of trouble at first, but compared with the alternative of re-entering credentials for every app that uses your custom account, it's refreshingly easy.
But I do not want to make my users download a separate APK just to be able to log in. What would be another solution that would allow both apps to have this functionality, without the burden of a separate APK?
AccountManager
binds the accounts to the first app that is installed with the account service. If that first app is deleted, all of the accounts are deleted as well. This isn't ideal, and I think the only solution is to force users to download a separate APK. – Vapid