Search code examples
azureazure-active-directorymicrosoft-graph-apiazureportaldelta

Azure Active Directory Group Delta API


I am using the Azure Active Directory Group API for my tenant to list all the groups. I am using GET DELTA

https://learn.microsoft.com/en-us/graph/api/group-delta?view=graph-rest-1.0&tabs=http

GET https://graph.microsoft.com/v1.0/groups/delta?$select=resourceBehaviorOptions,groupTypes,membershipRuleProcessingState,mail,visibility,displayName,mailEnabled,createdDateTime,creationOptions,proxyAddresses,securityIdentifier,resourceProvisioningOptions,id,securityEnabled,mailNickname,members

According to the documentation, this call when I make for the first time should give me all the meta-data related to groups and in the end it should give me a "delta-link". This delta link when called later would just give the changes that have been made in the meta-data of group since then.

However during the first call only when I should be getting all the meta-data, I am getting resources with annotations @removed. According to my understanding I should get the changes only when I call the delta link and not for the first time when I am getting all the data

I wanted to know if this is a feature (Microsoft returns @removed for groups which were removed let's day 10 days ago). Or this is a bug?


Solution

  • I have tested this in my Lab and its same for me as well while making a call GET /groups/delta it provides me with a nextlink and it also provides the users I had removed few days back from a group as well.

    So, the remove made earlier are shown first response and in nextlink which is expected as per the Microsoft documentation : The @removed object can be returned in the initial delta query response and in tracked (deltaLink) responses and the new changes that were made after the delta call can be tracked in the delta link response.

    Reference: Use delta query to track changes in Microsoft Graph data - Microsoft Graph | Microsoft Docs

    group: delta - Microsoft Graph v1.0 | Microsoft Docs

    Sample testing using Graph explorer:

    1. Setting up the delta call, In response I get all the details of my Groups and a nextlink for more details, until finally I get the deltalink.

    enter image description here

    1. I have created a user into the group after initial response.

    enter image description here

    1. In deltalink response , I get the detail of the user added.

    enter image description here