-
Notifications
You must be signed in to change notification settings - Fork 214
Closed
Labels
Description
Describe the bug
Update-MgPolicyClaimMappingPolicy is not returning ClaimMappingPolicy
To Reproduce
Make sure you have an existing policy:
$policy = New-MgPolicyClaimMappingPolicy -BodyParameter $params
Then call an update on the policy:
$policyOnUpdate = Update-MgPolicyClaimMappingPolicy -ClaimsMappingPolicyId $policy.id -BodyParameter $params
Expected behavior
Should return the object, just how New-MgPolicyClaimMappingPolicy returns it
Debug Output
DEBUG: [CmdletBeginProcessing]: - Update-MgPolicyClaimMappingPolicy begin processing with parameterSet 'Update'.
DEBUG: [Authentication]: - AuthType: 'UserProvidedAccessToken', TokenCredentialType: 'UserProvidedAccessToken', ContextScope: 'Process', AppName: 'Microsoft Azure PowerShell'.
DEBUG: [Authentication]: - Scopes: [AuditLog.Read.All, Directory.AccessAsUser.All, email, openid, profile].
Confirm
Are you sure you want to perform this action?
Performing the operation "Update-MgPolicyClaimMappingPolicy_Update" on target "Call remote 'PATCH
/policies/claimsMappingPolicies/{claimsMappingPolicy-id}' operation".
[Y] Yes [A] Yes to All [N] No [L] No to All [S] Suspend [?] Help (default is "Y"): A
DEBUG: ============================ HTTP REQUEST ============================
HTTP Method:
PATCH
Absolute Uri:
https://graph.microsoft.com/v1.0/policies/claimsMappingPolicies/GUID
Headers:
FeatureFlag : 00000043
Cache-Control : no-store, no-cache
User-Agent : Mozilla/5.0,(Windows NT 10.0; Microsoft Windows 10.0.22621; en-US),PowerShell/7.3.6
Accept-Encoding : gzip
SdkVersion : graph-powershell/2.4.0
client-request-id : a9211f0e-51c0-471d-b2c5-a19bf7b96e56
Body:
{
"displayName": "Azure Claims Policy",
"definition": [
"SOMEDEF"
],
"isOrganizationDefault": false
}
DEBUG: ============================ HTTP RESPONSE ============================
Status Code:
NoContent
Headers:
Cache-Control : no-cache
Strict-Transport-Security : max-age=31536000
request-id : 05a6c4ca-f1fa-40c3-9b12-a53628056822
client-request-id : a9211f0e-51c0-471d-b2c5-a19bf7b96e56
x-ms-ags-diagnostic : {"ServerInfo":{"DataCenter":"West Europe","Slice":"E","Ring":"5","ScaleUnit":"006","RoleInstance":"AM1PEPF00027E55"}}
x-ms-resource-unit : 1
Date : Wed, 30 Aug 2023 08:08:19 GMT
Body:
DEBUG: [CmdletEndProcessing]: - Update-MgPolicyClaimMappingPolicy end processing.
Module Version
ModuleType Version PreRelease Name ExportedCommands
---------- ------- ---------- ---- ----------------
Script 2.4.0 Microsoft.Graph.Applications {Add-MgApplicationKey, Add-MgApplicationPassword,…
Script 2.4.0 Microsoft.Graph.Authentication {Add-MgEnvironment, Connect-MgGraph, Disconnect-M…
Script 2.4.0 Microsoft.Graph.Identity.SignIns {Confirm-MgRiskyServicePrincipalCompromised, Conf…
Environment Data
Name Value
---- -----
PSVersion 7.3.6
PSEdition Core
GitCommitId 7.3.6
OS Microsoft Windows 10.0.22621
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0