APIs under the /beta version in Microsoft Graph are subject to change. Use of these APIs in production applications is not supported. To determine whether an API is available in v1.0, use the Version selector.
Choose the permission or permissions marked as least privileged for this API. Use a higher privileged permission or permissions only if your app requires it. For details about delegated and application permissions, see Permission types. To learn more about these permissions, see the permissions reference.
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Beta.Models;
var requestBody = new EducationAssignmentSettings
{
SubmissionAnimationDisabled = true,
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Education.Classes["{educationClass-id}"].AssignmentSettings.PatchAsync(requestBody);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest major version. Current major version is $v0.*
// Dependencies
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-beta-sdk-go"
graphmodels "github.com/microsoftgraph/msgraph-beta-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewEducationAssignmentSettings()
submissionAnimationDisabled := true
requestBody.SetSubmissionAnimationDisabled(&submissionAnimationDisabled)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
assignmentSettings, err := graphClient.Education().Classes().ByEducationClassId("educationClass-id").AssignmentSettings().Patch(context.Background(), requestBody, nil)
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
EducationAssignmentSettings educationAssignmentSettings = new EducationAssignmentSettings();
educationAssignmentSettings.setSubmissionAnimationDisabled(true);
EducationAssignmentSettings result = graphClient.education().classes().byEducationClassId("{educationClass-id}").assignmentSettings().patch(educationAssignmentSettings);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
<?php
use Microsoft\Graph\Beta\GraphServiceClient;
use Microsoft\Graph\Beta\Generated\Models\EducationAssignmentSettings;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new EducationAssignmentSettings();
$requestBody->setSubmissionAnimationDisabled(true);
$result = $graphServiceClient->education()->classes()->byEducationClassId('educationClass-id')->assignmentSettings()->patch($requestBody)->wait();
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
from msgraph_beta.generated.models.education_assignment_settings import EducationAssignmentSettings
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = EducationAssignmentSettings(
submission_animation_disabled = True,
)
result = await graph_client.education.classes.by_education_class_id('educationClass-id').assignment_settings.patch(request_body)
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Beta.Models;
var requestBody = new EducationAssignmentSettings
{
GradingCategories = new List<EducationGradingCategory>
{
new EducationGradingCategory
{
DisplayName = "Lab",
PercentageWeight = 10,
},
new EducationGradingCategory
{
DisplayName = "Homework",
PercentageWeight = 80,
},
new EducationGradingCategory
{
DisplayName = "Test",
PercentageWeight = 10,
},
},
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Education.Classes["{educationClass-id}"].AssignmentSettings.PatchAsync(requestBody);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest major version. Current major version is $v0.*
// Dependencies
import (
"context"
msgraphsdk "github.com/microsoftgraph/msgraph-beta-sdk-go"
graphmodels "github.com/microsoftgraph/msgraph-beta-sdk-go/models"
//other-imports
)
requestBody := graphmodels.NewEducationAssignmentSettings()
educationGradingCategory := graphmodels.NewEducationGradingCategory()
displayName := "Lab"
educationGradingCategory.SetDisplayName(&displayName)
percentageWeight := int32(10)
educationGradingCategory.SetPercentageWeight(&percentageWeight)
educationGradingCategory1 := graphmodels.NewEducationGradingCategory()
displayName := "Homework"
educationGradingCategory1.SetDisplayName(&displayName)
percentageWeight := int32(80)
educationGradingCategory1.SetPercentageWeight(&percentageWeight)
educationGradingCategory2 := graphmodels.NewEducationGradingCategory()
displayName := "Test"
educationGradingCategory2.SetDisplayName(&displayName)
percentageWeight := int32(10)
educationGradingCategory2.SetPercentageWeight(&percentageWeight)
gradingCategories := []graphmodels.EducationGradingCategoryable {
educationGradingCategory,
educationGradingCategory1,
educationGradingCategory2,
}
requestBody.SetGradingCategories(gradingCategories)
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=go
assignmentSettings, err := graphClient.Education().Classes().ByEducationClassId("educationClass-id").AssignmentSettings().Patch(context.Background(), requestBody, nil)
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
EducationAssignmentSettings educationAssignmentSettings = new EducationAssignmentSettings();
LinkedList<EducationGradingCategory> gradingCategories = new LinkedList<EducationGradingCategory>();
EducationGradingCategory educationGradingCategory = new EducationGradingCategory();
educationGradingCategory.setDisplayName("Lab");
educationGradingCategory.setPercentageWeight(10);
gradingCategories.add(educationGradingCategory);
EducationGradingCategory educationGradingCategory1 = new EducationGradingCategory();
educationGradingCategory1.setDisplayName("Homework");
educationGradingCategory1.setPercentageWeight(80);
gradingCategories.add(educationGradingCategory1);
EducationGradingCategory educationGradingCategory2 = new EducationGradingCategory();
educationGradingCategory2.setDisplayName("Test");
educationGradingCategory2.setPercentageWeight(10);
gradingCategories.add(educationGradingCategory2);
educationAssignmentSettings.setGradingCategories(gradingCategories);
EducationAssignmentSettings result = graphClient.education().classes().byEducationClassId("{educationClass-id}").assignmentSettings().patch(educationAssignmentSettings);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
<?php
use Microsoft\Graph\Beta\GraphServiceClient;
use Microsoft\Graph\Beta\Generated\Models\EducationAssignmentSettings;
use Microsoft\Graph\Beta\Generated\Models\EducationGradingCategory;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new EducationAssignmentSettings();
$gradingCategoriesEducationGradingCategory1 = new EducationGradingCategory();
$gradingCategoriesEducationGradingCategory1->setDisplayName('Lab');
$gradingCategoriesEducationGradingCategory1->setPercentageWeight(10);
$gradingCategoriesArray []= $gradingCategoriesEducationGradingCategory1;
$gradingCategoriesEducationGradingCategory2 = new EducationGradingCategory();
$gradingCategoriesEducationGradingCategory2->setDisplayName('Homework');
$gradingCategoriesEducationGradingCategory2->setPercentageWeight(80);
$gradingCategoriesArray []= $gradingCategoriesEducationGradingCategory2;
$gradingCategoriesEducationGradingCategory3 = new EducationGradingCategory();
$gradingCategoriesEducationGradingCategory3->setDisplayName('Test');
$gradingCategoriesEducationGradingCategory3->setPercentageWeight(10);
$gradingCategoriesArray []= $gradingCategoriesEducationGradingCategory3;
$requestBody->setGradingCategories($gradingCategoriesArray);
$result = $graphServiceClient->education()->classes()->byEducationClassId('educationClass-id')->assignmentSettings()->patch($requestBody)->wait();
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
from msgraph_beta.generated.models.education_assignment_settings import EducationAssignmentSettings
from msgraph_beta.generated.models.education_grading_category import EducationGradingCategory
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = EducationAssignmentSettings(
grading_categories = [
EducationGradingCategory(
display_name = "Lab",
percentage_weight = 10,
),
EducationGradingCategory(
display_name = "Homework",
percentage_weight = 80,
),
EducationGradingCategory(
display_name = "Test",
percentage_weight = 10,
),
],
)
result = await graph_client.education.classes.by_education_class_id('educationClass-id').assignment_settings.patch(request_body)
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Beta.Models;
using Microsoft.Kiota.Abstractions.Serialization;
var requestBody = new EducationAssignmentSettings
{
AdditionalData = new Dictionary<string, object>
{
{
"gradingCategories@delta" , new List<object>
{
new UntypedObject(new Dictionary<string, UntypedNode>
{
{
"id", new UntypedString("fb859cd3-943b-4cd6-9bbe-fe1c39eace0e")
},
{
"displayName", new UntypedString("Lab Test")
},
}),
new UntypedObject(new Dictionary<string, UntypedNode>
{
{
"@odata.context", new UntypedString("https://graph.microsoft.com/beta/$metadata#gradingCategories/$deletedEntity")
},
{
"id", new UntypedString("e2a86277-24f9-4f29-8196-8c83fc69d00d")
},
{
"reason", new UntypedString("deleted")
},
}),
new UntypedObject(new Dictionary<string, UntypedNode>
{
{
"displayName", new UntypedString("Lab Practice")
},
{
"percentageWeight", new UntypedString("30")
},
}),
new UntypedObject(new Dictionary<string, UntypedNode>
{
{
"displayName", new UntypedString("Lab Theory")
},
{
"percentageWeight", new UntypedString("10")
},
}),
}
},
},
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Education.Classes["{educationClass-id}"].AssignmentSettings.PatchAsync(requestBody);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
EducationAssignmentSettings educationAssignmentSettings = new EducationAssignmentSettings();
HashMap<String, Object> additionalData = new HashMap<String, Object>();
LinkedList<Object> gradingCategoriesDelta = new LinkedList<Object>();
property = new ();
property.setId("fb859cd3-943b-4cd6-9bbe-fe1c39eace0e");
property.setDisplayName("Lab Test");
gradingCategoriesDelta.add(property);
property1 = new ();
property1.setOdataContext("https://graph.microsoft.com/beta/$metadata#gradingCategories/$deletedEntity");
property1.setId("e2a86277-24f9-4f29-8196-8c83fc69d00d");
property1.setReason("deleted");
gradingCategoriesDelta.add(property1);
property2 = new ();
property2.setDisplayName("Lab Practice");
property2.setPercentageWeight(30);
gradingCategoriesDelta.add(property2);
property3 = new ();
property3.setDisplayName("Lab Theory");
property3.setPercentageWeight(10);
gradingCategoriesDelta.add(property3);
additionalData.put("gradingCategories@delta", gradingCategoriesDelta);
educationAssignmentSettings.setAdditionalData(additionalData);
EducationAssignmentSettings result = graphClient.education().classes().byEducationClassId("{educationClass-id}").assignmentSettings().patch(educationAssignmentSettings);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
from msgraph_beta.generated.models.education_assignment_settings import EducationAssignmentSettings
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = EducationAssignmentSettings(
additional_data = {
"grading_categories@delta" : [
{
"id" : "fb859cd3-943b-4cd6-9bbe-fe1c39eace0e",
"display_name" : "Lab Test",
},
{
"@odata_context" : "https://graph.microsoft.com/beta/$metadata#gradingCategories/$deletedEntity",
"id" : "e2a86277-24f9-4f29-8196-8c83fc69d00d",
"reason" : "deleted",
},
{
"display_name" : "Lab Practice",
"percentage_weight" : 30,
},
{
"display_name" : "Lab Theory",
"percentage_weight" : 10,
},
],
}
)
result = await graph_client.education.classes.by_education_class_id('educationClass-id').assignment_settings.patch(request_body)
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Beta.Models;
var requestBody = new EducationAssignmentSettings
{
GradingSchemes = new List<EducationGradingScheme>
{
new EducationGradingScheme
{
DisplayName = "Pass/fail",
Grades = new List<EducationGradingSchemeGrade>
{
new EducationGradingSchemeGrade
{
DisplayName = "Pass",
MinPercentage = 60f,
DefaultPercentage = 100f,
},
new EducationGradingSchemeGrade
{
DisplayName = "Fail",
MinPercentage = 0f,
DefaultPercentage = 0f,
},
},
},
new EducationGradingScheme
{
DisplayName = "Letters",
Grades = new List<EducationGradingSchemeGrade>
{
new EducationGradingSchemeGrade
{
DisplayName = "A",
MinPercentage = 90f,
},
new EducationGradingSchemeGrade
{
DisplayName = "B",
MinPercentage = 80f,
},
new EducationGradingSchemeGrade
{
DisplayName = "C",
MinPercentage = 70f,
},
new EducationGradingSchemeGrade
{
DisplayName = "D",
MinPercentage = 60f,
},
new EducationGradingSchemeGrade
{
DisplayName = "F",
MinPercentage = 0f,
},
},
},
},
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.Education.Classes["{educationClass-id}"].AssignmentSettings.PatchAsync(requestBody);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
EducationAssignmentSettings educationAssignmentSettings = new EducationAssignmentSettings();
LinkedList<EducationGradingScheme> gradingSchemes = new LinkedList<EducationGradingScheme>();
EducationGradingScheme educationGradingScheme = new EducationGradingScheme();
educationGradingScheme.setDisplayName("Pass/fail");
LinkedList<EducationGradingSchemeGrade> grades = new LinkedList<EducationGradingSchemeGrade>();
EducationGradingSchemeGrade educationGradingSchemeGrade = new EducationGradingSchemeGrade();
educationGradingSchemeGrade.setDisplayName("Pass");
educationGradingSchemeGrade.setMinPercentage(60f);
educationGradingSchemeGrade.setDefaultPercentage(100f);
grades.add(educationGradingSchemeGrade);
EducationGradingSchemeGrade educationGradingSchemeGrade1 = new EducationGradingSchemeGrade();
educationGradingSchemeGrade1.setDisplayName("Fail");
educationGradingSchemeGrade1.setMinPercentage(0f);
educationGradingSchemeGrade1.setDefaultPercentage(0f);
grades.add(educationGradingSchemeGrade1);
educationGradingScheme.setGrades(grades);
gradingSchemes.add(educationGradingScheme);
EducationGradingScheme educationGradingScheme1 = new EducationGradingScheme();
educationGradingScheme1.setDisplayName("Letters");
LinkedList<EducationGradingSchemeGrade> grades1 = new LinkedList<EducationGradingSchemeGrade>();
EducationGradingSchemeGrade educationGradingSchemeGrade2 = new EducationGradingSchemeGrade();
educationGradingSchemeGrade2.setDisplayName("A");
educationGradingSchemeGrade2.setMinPercentage(90f);
grades1.add(educationGradingSchemeGrade2);
EducationGradingSchemeGrade educationGradingSchemeGrade3 = new EducationGradingSchemeGrade();
educationGradingSchemeGrade3.setDisplayName("B");
educationGradingSchemeGrade3.setMinPercentage(80f);
grades1.add(educationGradingSchemeGrade3);
EducationGradingSchemeGrade educationGradingSchemeGrade4 = new EducationGradingSchemeGrade();
educationGradingSchemeGrade4.setDisplayName("C");
educationGradingSchemeGrade4.setMinPercentage(70f);
grades1.add(educationGradingSchemeGrade4);
EducationGradingSchemeGrade educationGradingSchemeGrade5 = new EducationGradingSchemeGrade();
educationGradingSchemeGrade5.setDisplayName("D");
educationGradingSchemeGrade5.setMinPercentage(60f);
grades1.add(educationGradingSchemeGrade5);
EducationGradingSchemeGrade educationGradingSchemeGrade6 = new EducationGradingSchemeGrade();
educationGradingSchemeGrade6.setDisplayName("F");
educationGradingSchemeGrade6.setMinPercentage(0f);
grades1.add(educationGradingSchemeGrade6);
educationGradingScheme1.setGrades(grades1);
gradingSchemes.add(educationGradingScheme1);
educationAssignmentSettings.setGradingSchemes(gradingSchemes);
EducationAssignmentSettings result = graphClient.education().classes().byEducationClassId("{educationClass-id}").assignmentSettings().patch(educationAssignmentSettings);
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
<?php
use Microsoft\Graph\Beta\GraphServiceClient;
use Microsoft\Graph\Beta\Generated\Models\EducationAssignmentSettings;
use Microsoft\Graph\Beta\Generated\Models\EducationGradingScheme;
use Microsoft\Graph\Beta\Generated\Models\EducationGradingSchemeGrade;
$graphServiceClient = new GraphServiceClient($tokenRequestContext, $scopes);
$requestBody = new EducationAssignmentSettings();
$gradingSchemesEducationGradingScheme1 = new EducationGradingScheme();
$gradingSchemesEducationGradingScheme1->setDisplayName('Pass/fail');
$gradesEducationGradingSchemeGrade1 = new EducationGradingSchemeGrade();
$gradesEducationGradingSchemeGrade1->setDisplayName('Pass');
$gradesEducationGradingSchemeGrade1->setMinPercentage(60);
$gradesEducationGradingSchemeGrade1->setDefaultPercentage(100);
$gradesArray []= $gradesEducationGradingSchemeGrade1;
$gradesEducationGradingSchemeGrade2 = new EducationGradingSchemeGrade();
$gradesEducationGradingSchemeGrade2->setDisplayName('Fail');
$gradesEducationGradingSchemeGrade2->setMinPercentage(0);
$gradesEducationGradingSchemeGrade2->setDefaultPercentage(0);
$gradesArray []= $gradesEducationGradingSchemeGrade2;
$gradingSchemesEducationGradingScheme1->setGrades($gradesArray);
$gradingSchemesArray []= $gradingSchemesEducationGradingScheme1;
$gradingSchemesEducationGradingScheme2 = new EducationGradingScheme();
$gradingSchemesEducationGradingScheme2->setDisplayName('Letters');
$gradesEducationGradingSchemeGrade1 = new EducationGradingSchemeGrade();
$gradesEducationGradingSchemeGrade1->setDisplayName('A');
$gradesEducationGradingSchemeGrade1->setMinPercentage(90);
$gradesArray []= $gradesEducationGradingSchemeGrade1;
$gradesEducationGradingSchemeGrade2 = new EducationGradingSchemeGrade();
$gradesEducationGradingSchemeGrade2->setDisplayName('B');
$gradesEducationGradingSchemeGrade2->setMinPercentage(80);
$gradesArray []= $gradesEducationGradingSchemeGrade2;
$gradesEducationGradingSchemeGrade3 = new EducationGradingSchemeGrade();
$gradesEducationGradingSchemeGrade3->setDisplayName('C');
$gradesEducationGradingSchemeGrade3->setMinPercentage(70);
$gradesArray []= $gradesEducationGradingSchemeGrade3;
$gradesEducationGradingSchemeGrade4 = new EducationGradingSchemeGrade();
$gradesEducationGradingSchemeGrade4->setDisplayName('D');
$gradesEducationGradingSchemeGrade4->setMinPercentage(60);
$gradesArray []= $gradesEducationGradingSchemeGrade4;
$gradesEducationGradingSchemeGrade5 = new EducationGradingSchemeGrade();
$gradesEducationGradingSchemeGrade5->setDisplayName('F');
$gradesEducationGradingSchemeGrade5->setMinPercentage(0);
$gradesArray []= $gradesEducationGradingSchemeGrade5;
$gradingSchemesEducationGradingScheme2->setGrades($gradesArray);
$gradingSchemesArray []= $gradingSchemesEducationGradingScheme2;
$requestBody->setGradingSchemes($gradingSchemesArray);
$result = $graphServiceClient->education()->classes()->byEducationClassId('educationClass-id')->assignmentSettings()->patch($requestBody)->wait();
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph_beta import GraphServiceClient
from msgraph_beta.generated.models.education_assignment_settings import EducationAssignmentSettings
from msgraph_beta.generated.models.education_grading_scheme import EducationGradingScheme
from msgraph_beta.generated.models.education_grading_scheme_grade import EducationGradingSchemeGrade
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = EducationAssignmentSettings(
grading_schemes = [
EducationGradingScheme(
display_name = "Pass/fail",
grades = [
EducationGradingSchemeGrade(
display_name = "Pass",
min_percentage = 60,
default_percentage = 100,
),
EducationGradingSchemeGrade(
display_name = "Fail",
min_percentage = 0,
default_percentage = 0,
),
],
),
EducationGradingScheme(
display_name = "Letters",
grades = [
EducationGradingSchemeGrade(
display_name = "A",
min_percentage = 90,
),
EducationGradingSchemeGrade(
display_name = "B",
min_percentage = 80,
),
EducationGradingSchemeGrade(
display_name = "C",
min_percentage = 70,
),
EducationGradingSchemeGrade(
display_name = "D",
min_percentage = 60,
),
EducationGradingSchemeGrade(
display_name = "F",
min_percentage = 0,
),
],
),
],
)
result = await graph_client.education.classes.by_education_class_id('educationClass-id').assignment_settings.patch(request_body)
Important
Microsoft Graph SDKs use the v1.0 version of the API by default, and do not support all the types, properties, and APIs available in the beta version. For details about accessing the beta API with the SDK, see Use the Microsoft Graph SDKs with the beta API.