Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
13,498 questions
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
I'm receiving user upated events from Entra via an MSGraph partner topic but it always returns all attributes from a call to GetAsDeltaGetResponseAsync, regardless of whether they have change or not.
var userChanges = await graphServiceClient.Users.Delta.GetAsDeltaGetResponseAsync((requestConfiguration) =>
{
requestConfiguration.QueryParameters.Filter = $"id eq ('{cloudData.ResourceData!.Id}')";
requestConfiguration.Headers.Add("ConsistencyLevel", "eventual");
requestConfiguration.Headers.Add("Prefer", "return=minimal");
requestConfiguration.QueryParameters.Count = true;
requestConfiguration.QueryParameters.Select = ["id,userPrincipalName,givenName,surname,displayName,mail,mailNickname,employeeId,employeeType,jobTitle,mobilePhone,officeLocation,postalCode,onPremisesSamAccountName,onPremisesUserPrincipalName,ageGroup,businessPhones,proxyAddresses,onPremisesExtensionAttributes"];
});
the return=minimal header doesn't seem to do anything and all attributes are returned fully populated even if they weren't updated in Entra. Is there a way to do a query from a notification event handler to only get the changed attributes?
In the response I see this:
"BackingStore":
{
"InitializationCompleted":false,
"ReturnOnlyChangedValues":false
},
I only want the values of the changed attributes.