You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
CreateLinkPostRequestBody in 6.2.0 defaults RetainInheritedPermissions = false #3165
When calling CreateLinkPostRequestBody to create a sharing link and RetainInheritedPermissions is not defined, it defaults to false.
This is the opposite of the behavior listed in the learn article.
Defining RetainInheritiedPermissions true or false operates as expected.
This bug doesn't appear in this repo but it does appear in the Python SDK #1536
Expected behavior
The default behavior should be to retain the items current permissions, ala RetainInheritedPermissions = true.
How to reproduce
var requestBody = new CreateLinkPostRequestBody
{
Type = "view",
Scope = "users",
ExpirationDateTime = DateTime.UtcNow.AddMinutes(10),
Recipients =
[
new() {
Email = "user@domain.com"
}
]
};
await _graph!.Drives[DriveID].Items[DriveItemID].CreateLink.PostAsync(requestBody, cancellationToken: cancellationToken).ConfigureAwait(false) ?? throw new FileNotFoundException();
//Will result in user@domain.com getting access for ten minutes but all other access will be wiped. Adding 'RetainInheritedPermissions = true,' corrects the behavior.
SDK Version
6.2.0
Latest version known to work for scenario above?
No response
Known Workarounds
Define RetainInheritedPermissions when creating a new CreateLinkPostRequestBody
Debug output
Click to expand log
```
</details>
### Configuration
_No response_
### Other information
_No response_
Activity
hp-bc commentedon Aug 5, 2026
This bug doesn't appear when making the call from Graph Explorer.
rcarde commentedon Sep 16, 2026
We have just encountered this.
Confirmed adding
RetainInheritedPermissions = truecorrects the issue and is contradictory to the documentation and possibly past behaviour.Seems to be the same issue with boolean
nullvalues defaulting tofalsehere. #3167