Quantcast
Channel: Azure Active Directory forum
Viewing all articles
Browse latest Browse all 16000

Ability to filter users with onPremisesSamAccountName with Microsoft Graph API

$
0
0

I would like to have a filter on the users api of Microsoft Graph API, where I will be able to filter the users based on onPremisesSamAccountName, which is currently not available with Graph API.

We have the internal employee id to be stored with onPremisesSamAccountName variable which is present in users API of Microsoft Graph. We are trying to filter with onPremisesSamAccountName property to filter based on the internal employee id. Currently we are not able to do that with Graph API but we really need this to be workling or would be happy if we get know any possible workarounds if available

https://graph.microsoft.com/v1.0/users?$filter=onPremisesSamAccountName eq '[some-id]'&$select= userPrincipalName,displayName,department,jobTitle,companyName,onPremisesSamAccountName,....[more list of fields for select]

The expected outcome is to show the required result but the response what we got is as follows


{"error": {"code": "Request_UnsupportedQuery","message": "Unsupported or invalid query filter clause specified for property 'onPremisesSamAccountName' of resource 'User'.","innerError": {"request-id": "[request-id from request]","date": "[date on which request is made]"
        }
    }
}

Viewing all articles
Browse latest Browse all 16000

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>