How to List Users With MFA Enrollments
This article explains how to retrieve a list of all users and their corresponding Multi-Factor Authentication (MFA) enrollments by using the Management API.
- Multi-Factor Authentication (MFA)
- Management API
To obtain a list of users and their MFA enrollment status, use the Management API.
-
Retrieve the first user enrollment by calling the
GET /api/v2/users/{id}/enrollmentsendpoint. This action must be performed for eachuser_id. -
The API response contains the MFA enrollment information for the specified user. By default, phone numbers in the response are obfuscated.
-
To view the complete, unobfuscated phone numbers, navigate to the tenant settings and set the
disable_management_api_sms_obfuscationflag to true.
{
"flags": {
"disable_management_api_sms_obfuscation": true
}
}