A cloud-based identity and access management service for securing user authentication and resource access
Use Microsoft Graph /users and filter for synced accounts: GET https://graph.microsoft.com/v1.0/users?$filter=onPremisesSyncEnabled eq true&$select=id,displayName,userPrincipalName,onPremisesSyncEnabled — this returns user objects only (not contacts/groups), and limits results to accounts currently synced from on-prem.
under the answer to mark it.