L’une des autorisations suivantes est nécessaire pour appeler cette API. Pour plus d’informations, notamment sur la façon de choisir les autorisations, voir Autorisations.
Type d’autorisation
Autorisations (de celle qui offre le plus de privilèges à celle qui en offre le moins)
// Code snippets are only available for the latest version. Current version is 5.x
// Dependencies
using Microsoft.Graph.DeviceManagement.Reports.GetHistoricalReport;
var requestBody = new GetHistoricalReportPostRequestBody
{
Name = "Name value",
Select = new List<string>
{
"Select value",
},
Search = "Search value",
GroupBy = new List<string>
{
"Group By value",
},
OrderBy = new List<string>
{
"Order By value",
},
Skip = 4,
Top = 3,
Filter = "Filter value",
};
// To initialize your graphClient, see https://learn.microsoft.com/en-us/graph/sdks/create-client?from=snippets&tabs=csharp
await graphClient.DeviceManagement.Reports.GetHistoricalReport.PostAsync(requestBody);
// Code snippets are only available for the latest version. Current version is 6.x
GraphServiceClient graphClient = new GraphServiceClient(requestAdapter);
com.microsoft.graph.devicemanagement.reports.gethistoricalreport.GetHistoricalReportPostRequestBody getHistoricalReportPostRequestBody = new com.microsoft.graph.devicemanagement.reports.gethistoricalreport.GetHistoricalReportPostRequestBody();
getHistoricalReportPostRequestBody.setName("Name value");
LinkedList<String> select = new LinkedList<String>();
select.add("Select value");
getHistoricalReportPostRequestBody.setSelect(select);
getHistoricalReportPostRequestBody.setSearch("Search value");
LinkedList<String> groupBy = new LinkedList<String>();
groupBy.add("Group By value");
getHistoricalReportPostRequestBody.setGroupBy(groupBy);
LinkedList<String> orderBy = new LinkedList<String>();
orderBy.add("Order By value");
getHistoricalReportPostRequestBody.setOrderBy(orderBy);
getHistoricalReportPostRequestBody.setSkip(4);
getHistoricalReportPostRequestBody.setTop(3);
getHistoricalReportPostRequestBody.setFilter("Filter value");
graphClient.deviceManagement().reports().getHistoricalReport().post(getHistoricalReportPostRequestBody);
Voici un exemple de réponse. Remarque : l’objet de réponse illustré ici peut être tronqué à des fins de concision. Toutes les propriétés sont renvoyées à partir d’un appel réel.
Bientôt disponible : Tout au long de 2024, nous allons supprimer progressivement GitHub Issues comme mécanisme de commentaires pour le contenu et le remplacer par un nouveau système de commentaires. Pour plus d’informations, consultez https://aka.ms/ContentUserFeedback.