Forum Discussion
notepadapp
Jul 16, 2024Copper Contributor
Graph - Access Review
I've been trying to modify my create access review script to include an email address to the NotificationRecipientScope. Need to specify at end of review, send notification to mailto:email address re...
sdtslmn
Jul 16, 2024MCT
maybe the following can help you
$notifRecipients = @(
@{
notificationTemplateType = "CompletedAdditionalRecipients"
recipients = @(
@{
"@odata.type" = "#microsoft.graph.accessReviewNotificationRecipientScope"
notificationRecipients = @(
@{
"@odata.type" = "#microsoft.graph.user"
emailAddress = "email address removed for privacy reasons"
}
)
}
)
}
)
# Example Access Review Creation
New-AzureADMSAccessReview -ReviewId <ReviewId> -Settings @{
autoApplyDecisionsEnabled = $false
instanceDurationInDays = 30
mailNotificationsEnabled = $true
recurrenceSettings = @{
pattern = @{ type = "weekly"; interval = 1 }
range = @{ type = "endDate"; endDate = "2024-12-31T23:59:59Z" }
}
reviewers = @(
@{ "@odata.type" = "#microsoft.graph.userSet"; id = "<UserId>" }
)
additionalNotificationRecipients = $notifRecipients
}
- notepadappJul 16, 2024Copper ContributorThanks for your help, unfortunately I get error 400 - bad request.