Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

list google apps accounts

How can I determine if a specific google account is a Google Apps account?

I have 2 accounts on my phone.

a normal Google acc and a Google Apps account

accountManager = AccountManager.get(getApplicationContext());
Account[] accounts = accountManager.getAccounts();
for ( int i = 0; i < accounts.length; i++ )
{
    Log.d(TAG, accounts[i].name + " - " + accounts[i].type);            
}

It prints "com.google" as type for both.

like image 652
jakk Avatar asked Jun 07 '26 10:06

jakk


1 Answers

I was wondering too, but determine based on @gmail.com or @googlemail.com as many suggested isn't accountable. Through some entrances, users can actually register a Google Account using emails other than Gmail. Try this sign-up entrance: https://accounts.google.com/newaccount?hl=en

like image 76
Tian Bai Avatar answered Jun 09 '26 00:06

Tian Bai