// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.Models;
var requestBody = new DeviceConfigurationDeviceStateSummary
{
OdataType = "#microsoft.graph.deviceConfigurationDeviceStateSummary",
UnknownDeviceCount = 2,
NotApplicableDeviceCount = 8,
CompliantDeviceCount = 4,
RemediatedDeviceCount = 5,
NonCompliantDeviceCount = 7,
ErrorDeviceCount = 0,
ConflictDeviceCount = 3,
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
var result = await graphClient.DeviceManagement.DeviceConfigurationDeviceStateSummaries.PatchAsync(requestBody);
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
DeviceConfigurationDeviceStateSummary deviceConfigurationDeviceStateSummary = new DeviceConfigurationDeviceStateSummary();
deviceConfigurationDeviceStateSummary.setOdataType("#microsoft.graph.deviceConfigurationDeviceStateSummary");
deviceConfigurationDeviceStateSummary.setUnknownDeviceCount(2);
deviceConfigurationDeviceStateSummary.setNotApplicableDeviceCount(8);
deviceConfigurationDeviceStateSummary.setCompliantDeviceCount(4);
deviceConfigurationDeviceStateSummary.setRemediatedDeviceCount(5);
deviceConfigurationDeviceStateSummary.setNonCompliantDeviceCount(7);
deviceConfigurationDeviceStateSummary.setErrorDeviceCount(0);
deviceConfigurationDeviceStateSummary.setConflictDeviceCount(3);
DeviceConfigurationDeviceStateSummary result = graphClient.deviceManagement().deviceConfigurationDeviceStateSummaries().patch(deviceConfigurationDeviceStateSummary);
# Code snippets are only available for the latest version. Current version is 1.x
from msgraph import GraphServiceClient
from msgraph.generated.models.device_configuration_device_state_summary import DeviceConfigurationDeviceStateSummary
# To initialize your graph_client, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=python
request_body = DeviceConfigurationDeviceStateSummary(
odata_type = "#microsoft.graph.deviceConfigurationDeviceStateSummary",
unknown_device_count = 2,
not_applicable_device_count = 8,
compliant_device_count = 4,
remediated_device_count = 5,
non_compliant_device_count = 7,
error_device_count = 0,
conflict_device_count = 3,
)
result = await graph_client.device_management.device_configuration_device_state_summaries.patch(request_body)