Eine der nachfolgenden Berechtigungen ist erforderlich, um diese API aufrufen zu können. Weitere Informationen, unter anderem zur Auswahl von Berechtigungen, finden Sie im Artikel zum Thema Berechtigungen.
Berechtigungstyp
Berechtigungen (von der Berechtigung mit den wenigsten Rechten zu der mit den meisten Rechten)
Delegiert (Geschäfts-, Schul- oder Unikonto)
AccessReview.ReadWrite.All
Delegiert (persönliches Microsoft-Konto)
Nicht unterstützt
Anwendung
AccessReview.ReadWrite.All
HTTP-Anforderung
POST /identityGovernance/accessReviews/definitions/{accessReviewScheduleDefinitionId}/instances/{accessReviewInstanceId}/batchRecordDecisions
Zugriffsentscheidung für die zu überprüfende Entität. Mögliche Werte: Approve, Deny, NotReviewed, DontKnow Erforderlich.
Rechtfertigung
Zeichenfolge
Kontext der Überprüfung, die Administratoren zur Verfügung gestellt wird. Erforderlich, wenn justificationRequiredOnApproval der Einstellungseigenschaft von accessReviewScheduleDefinition ist true .
principalId
String
Wenn angegeben, werden alle accessReviewInstanceDecisionItems mit übereinstimmenden principalId-Werten in diesem Batch überprüft. Wenn nicht angegeben, werden alle accessReviewInstanceDecisionItems überprüft.
resourceId
String
Wenn angegeben, werden alle accessReviewInstanceDecisionItems mit übereinstimmenden resourceId in diesem Batch überprüft. Wenn nicht angegeben, werden alle accessReviewInstanceDecisionItems überprüft.
Antwort
Wenn die Aktion erfolgreich verläuft, wird der Antwortcode 204 No Content zurückgegeben.
POST https://graph.microsoft.com/v1.0/identityGovernance/accessReviews/definitions/e6cafba0-cbf0-4748-8868-0810c7f4cc06/instances/1234fba0-cbf0-6778-8868-9999c7f4cc06/batchRecordDecisions
Content-type: application/json
{
"decision": "Approve",
"justification": "All principals with access need continued access to the resource (Marketing Group) as all the principals are on the marketing team",
"resourceId": "a5c51e59-3fcd-4a37-87a1-835c0c21488a"
}
GraphServiceClient graphClient = new GraphServiceClient( authProvider );
var decision = "Approve";
var justification = "All principals with access need continued access to the resource (Marketing Group) as all the principals are on the marketing team";
var resourceId = "a5c51e59-3fcd-4a37-87a1-835c0c21488a";
await graphClient.IdentityGovernance.AccessReviews.Definitions["{accessReviewScheduleDefinition-id}"].Instances["{accessReviewInstance-id}"]
.BatchRecordDecisions(decision,justification,null,resourceId)
.Request()
.PostAsync();
const options = {
authProvider,
};
const client = Client.init(options);
const batchRecordDecisions = {
decision: 'Approve',
justification: 'All principals with access need continued access to the resource (Marketing Group) as all the principals are on the marketing team',
resourceId: 'a5c51e59-3fcd-4a37-87a1-835c0c21488a'
};
await client.api('/identityGovernance/accessReviews/definitions/e6cafba0-cbf0-4748-8868-0810c7f4cc06/instances/1234fba0-cbf0-6778-8868-9999c7f4cc06/batchRecordDecisions')
.post(batchRecordDecisions);
GraphServiceClient graphClient = GraphServiceClient.builder().authenticationProvider( authProvider ).buildClient();
String decision = "Approve";
String justification = "All principals with access need continued access to the resource (Marketing Group) as all the principals are on the marketing team";
String resourceId = "a5c51e59-3fcd-4a37-87a1-835c0c21488a";
graphClient.identityGovernance().accessReviews().definitions("e6cafba0-cbf0-4748-8868-0810c7f4cc06").instances("1234fba0-cbf0-6778-8868-9999c7f4cc06")
.batchRecordDecisions(AccessReviewInstanceBatchRecordDecisionsParameterSet
.newBuilder()
.withDecision(decision)
.withJustification(justification)
.withPrincipalId(null)
.withResourceId(resourceId)
.build())
.buildRequest()
.post();
//THE GO SDK IS IN PREVIEW. NON-PRODUCTION USE ONLY
graphClient := msgraphsdk.NewGraphServiceClient(requestAdapter)
requestBody := msgraphsdk.New()
decision := "Approve"
requestBody.SetDecision(&decision)
justification := "All principals with access need continued access to the resource (Marketing Group) as all the principals are on the marketing team"
requestBody.SetJustification(&justification)
resourceId := "a5c51e59-3fcd-4a37-87a1-835c0c21488a"
requestBody.SetResourceId(&resourceId)
accessReviewScheduleDefinitionId := "accessReviewScheduleDefinition-id"
accessReviewInstanceId := "accessReviewInstance-id"
graphClient.IdentityGovernance().AccessReviews().DefinitionsById(&accessReviewScheduleDefinitionId).InstancesById(&accessReviewInstanceId).BatchRecordDecisions(accessReviewScheduleDefinition-id, accessReviewInstance-id).Post(requestBody)