Does user delta query support filter query parameters?

testfestAdmin 1 Reputation point

Hi There,

I was trying to add filter query parameters in Microsoft users delta request (the URL is shown as below.)$filter=endswith(mail,'a[@](/users/na/?userId=a28c79c1-c609-48db-b55f-1783d1187afb).com')&$orderby=userPrincipalName&$count=true

However, I was getting below errors. {"error":{"code":"Request_UnsupportedQuery","message":"Unsupported Query.","innerError":{"date":"2022-11-16T00:14:46","request-id":"35fc45f9-eb26-466a-b360-9daef231392a","client-request-id":"35fc45f9-eb26-466a-b360-9daef231392a"}}}

And as I checked your official doc, seems only Object id is allowed in the filter query? Can I filter delta users by mail?

Scoping filters allow you to track changes to one or more specific users or groups by object ID. For example, the following request returns changes for the groups matching the IDs specified in the query filter.

Microsoft Graph Users API
Microsoft Graph Users API
A Microsoft API that allows you to build compelling app experiences based on users, their relationships with other users and groups, and the resources they access for example their mails, calendars, files, administrative roles, group memberships.
737 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Shivam Dhiman 5,771 Reputation points

    Hi @testfestAdmin

    As per the documentation, it supports filter but there is limited support:
    The only supported $filter expression is for tracking changes on a specific object: $filter=id+eq+{value}.
    You can filter multiple objects. For example,$filter= id eq '477e9fc6-5de7-4406-bb2a-7e5c8****' or id eq '004d6a07-fe70-4b92-add5-e6e37****'.
    There is a limit of 50 filtered objects.

    Please refer to this documentation for more details.

    Hope this helps.

    If the answer is helpful, please click Accept Answer and kindly upvote. If you have any further questions about this answer, please click Comment.

    0 comments No comments