Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I check if a user has 2-factor authentication enabled via Google Admin SDK APIs

I am using the Google Admin SDK APIs to manage users (create/update) in our organization's Google apps account. We allow users to optionally use the 2-factor authentication feature and I'd like to be able to determine if an account has it enabled or not when one of our internal support reps looks up their account. Looking over the docs at https://developers.google.com/admin-sdk/directory/v1/reference/users, I do not see any attributes that would indicate this setting.

Is there another way for me to check if it is enabled via an API?

like image 632
Phillip Avatar asked Oct 20 '14 17:10

Phillip


People also ask

Can a Google admin turn off 2-step verification for user?

Note: You can't turn off 2SV for a user if their account is suspended. If 2SV is enforced across your organization, the option to turn off 2SV for an individual user is disabled.


1 Answers

Saw an answer from an old Stackoverflow post:

Find all Google Apps users not using two-factor authentication

You can actually find that information via Reports API of Admin SDK: https://developers.google.com/admin-sdk/reports/v1/reference/usage-ref-appendix-a/users-accounts

Hope this helps!

like image 74
Emily Avatar answered Oct 22 '22 14:10

Emily