Search code examples
githubgithub-apitwo-factor-authentication

Github API - Users two factor authentication


I want to know if all users from my organization has the two factor authentication enabled. Is it possible to do via API? I searched through the v3 and v4 APIs but I can't find anything about it.

I know that I can see this information via browser but I want to know if its possible via API

Thanks.


Solution

  • You can find this information using the /members endpoint: https://developer.github.com/v3/orgs/members/#members-list.

    GitHub has probably thought about your particular use case because you can query for members that specifically have 2FA disabled:

    enter image description here