Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get-MgBetaIdentityGovernanceAccessReviewDefinition serialization issue with parameter scope #2991

Open
William-Francillette opened this issue Oct 8, 2024 · 0 comments
Labels

Comments

@William-Francillette
Copy link

William-Francillette commented Oct 8, 2024

Describe the bug

the parameter scope retrieve the value Microsoft.Graph.Beta.PowerShell.Models.MicrosoftGraphAccessReviewScope instead of the scope details

Expected behavior

should retrieve an object as retrieved in the debug trace

  "scope": {
    "@odata.type": "#microsoft.graph.accessReviewQueryScope",
    "query": "/beta/identityGovernance/entitlementManagement/accessPackageAssignments?$filter=(accessPackageId eq '<packageid>' and assignmentPolicyId eq '<policyid>' and catalogId eq '<catalogid>')",
    "queryType": "MicrosoftGraph",
    "queryRoot": null
  },

How to reproduce

(Get-MgBetaIdentityGovernanceAccessReviewDefinition -AccessReviewScheduleDefinitionId < id >).scope

SDK Version

2.24.0

Latest version known to work for scenario above?

No response

Known Workarounds

using invoke-mggraphrequest

Debug output

Click to expand log ``` DEBUG: ============================ HTTP REQUEST ============================

HTTP Method:
GET

Absolute Uri:
https://graph.microsoft.com/beta/identityGovernance/accessReviews/definitions/

Headers:
FeatureFlag : 00000043
Cache-Control : no-store, no-cache
User-Agent : Mozilla/5.0,(Windows NT 10.0; Microsoft Windows 10.0.22631; en-GB),PowerShell/7.4.5
Accept-Encoding : gzip
SdkVersion : graph-powershell-beta/2.24.0
client-request-id : 867b2885-b1ae-4cef-ba04-1b64bc600619

Body:

DEBUG: ============================ HTTP RESPONSE ============================

Status Code:
OK

Headers:
Vary : Accept-Encoding
Strict-Transport-Security : max-age=31536000
request-id : af126007-4c9d-415e-9ace-9a597947ba89
client-request-id : 867b2885-b1ae-4cef-ba04-1b64bc600619
x-ms-ags-diagnostic : {"ServerInfo":{"DataCenter":"UK South","Slice":"E","Ring":"5","ScaleUnit":"000","RoleInstance":"LN2PEPF000114C9"}}
Link : https://developer.microsoft-tst.com/en-us/graph/changes?$filterby=beta,PrivatePreview:customData&from=2021-06-01&to=2021-07-01;rel="deprecation";type="text/html",https://developer.microsoft-tst.com/en-us/graph/changes?$filterby=beta,PrivatePreview:customData&from=2021-06-01&to=2021-07-01;rel="deprecation";type="text/html",https://developer.microsoft-tst.com/en-us/graph/changes?$filterby=beta,PrivatePreview:customData&from=2021-06-01&to=2021-07-01;rel="deprecation";type="text/html"
deprecation : Thu, 03 Jun 2021 23:59:59 GMT
sunset : Sat, 03 Jun 2023 23:59:59 GMT
odata-version : 4.0
Date : Tue, 08 Oct 2024 15:38:02 GMT

Body:
{
"@odata.context": "https://graph.microsoft.com/beta/$metadata#identityGovernance/accessReviews/definitions/$entity",
"id": "",
"displayName": "package - DSC - policy with access review",
"createdDateTime": "2022-11-22T18:55:08.5175414Z",
"lastModifiedDateTime": "2022-11-23T00:00:41.0384578Z",
"status": "InProgress",
"descriptionForAdmins": "",
"descriptionForReviewers": "",
"customDataProvider": null,
"customData": null,
"createdBy": {
"id": "",
"displayName": "",
"type": null,
"userPrincipalName": ""
},
"scope": {
"@odata.type": "#microsoft.graph.accessReviewQueryScope",
"query": "/beta/identityGovernance/entitlementManagement/accessPackageAssignments?$filter=(accessPackageId eq '< redacted >' and assignmentPolicyId eq '< redacted >' and catalogId eq '< redacted >')",
"queryType": "MicrosoftGraph",
"queryRoot": null
},
"instanceEnumerationScope": {
"@odata.type": "#microsoft.graph.accessReviewQueryScope",
"query": "/beta/identityGovernance/entitlementManagement/accessPackageAssignmentPolicies/)",
"queryType": "MicrosoftGraph",
"queryRoot": null
},
"reviewers": [
{
"query": "/v1.0/users/",
"queryType": "MicrosoftGraph",
"queryRoot": null
}
],
"backupReviewers": [],
"fallbackReviewers": [],
"settings": {
"mailNotificationsEnabled": true,
"reminderNotificationsEnabled": true,
"justificationRequiredOnApproval": true,
"defaultDecisionEnabled": true,
"defaultDecision": "Deny",
"instanceDurationInDays": 25,
"autoApplyDecisionsEnabled": true,
"recommendationsEnabled": true,
"recommendationLookBackDuration": null,
"decisionHistoriesForReviewersEnabled": false,
"recurrence": {
"pattern": {
"type": "absoluteMonthly",
"interval": 3,
"month": 0,
"dayOfMonth": 0,
"daysOfWeek": [],
"firstDayOfWeek": "sunday",
"index": "first"
},
"range": {
"type": "noEnd",
"numberOfOccurrences": 0,
"recurrenceTimeZone": null,
"startDate": "2022-11-23",
"endDate": "9999-12-31"
}
},
"applyActions": [],
"recommendationInsightSettings": []
},
"stageSettings": [],
"additionalNotificationRecipients": []
}

DEBUG: [CmdletEndProcessing]: - Get-MgBetaIdentityGovernanceAccessReviewDefinition end processing.

</details>


### Configuration

_No response_

### Other information

_No response_
@William-Francillette William-Francillette added status:waiting-for-triage An issue that is yet to be reviewed or assigned type:bug A broken experience labels Oct 8, 2024
@timayabi2020 timayabi2020 added Status: Needs Investigation and removed status:waiting-for-triage An issue that is yet to be reviewed or assigned labels Oct 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants