I'm developing an Android app where users must be able to authenticate and then make calls to the YouTube Data API.
I have no problems authenticating the users with their main account, using Google Sign-In everything is easy and user friendly, both for me and the users.
The problem is that some Google services (eg Google+ and YouTube) allow a single Google account to have multiple related accounts (linked accounts) (eg multiple Google+ pages or multiple YouTube channels).
Unfortunately seems that Google Sign-In doesn't consider this use case. Every user is forced to log into their main account. In my scenario this is a serious problem. It means that some users won't be able to log into their secondary YouTube channels.
The only solution I have so far is to use the web-based authentication process. But this is obviously worst in terms of user experience and also means that I must handle everything by myself, with a WebView-based solution.
I've already built a small library that does everything, but Google recommends to use the provided Client libraries for a lot of good reasons. The problem is that all their client libraries have the same problem in Android. (The Google API Client Library for Java relies on the AccountManager for Android, therefore has the same problem of Google Sign-In)
Does anyone know if I'm missing something? is there a native way to authenticate the user secondary accounts? or am I forced to use the web-based authentication?
The same problem was addressed in a 3 years old YouTube blog post, is it possible that there's no solution yet?
Apparently at the moment there is no other way to solve this problem. Here is the link to the library I'm building, in case someone else will have the same issue. https://github.com/PierfrancescoSoffritti/GoogleWebOAuth
Hopefully Google will solve the issue in the future.