将 Microsoft Graph Sdk 与 beta API 结合使用Use the Microsoft Graph SDKs with the beta API

默认情况下,Microsoft Graph Sdk 使用 1.0 版 microsoft Graph 终结点。The Microsoft Graph SDKs use the v1.0 Microsoft Graph endpoint by default. Sdk 可用于非生产应用程序的 beta 终结点。The SDKs can be used with the beta endpoint for non-production applications. 访问 beta 终结点的方法取决于所使用的 SDK。The method for accessing the beta endpoint depends on which SDK you are using.

重要

/betaMicrosoft Graph 中的版本下的 api 可能会发生更改。APIs under the /beta version in Microsoft Graph are subject to change. 不支持在生产应用程序中使用这些 API。Use of these APIs in production applications is not supported.

若要调用 beta API,您必须安装 " Microsoft. Graph " 程序包。In order to call the beta API, you must install the Microsoft.Graph.Beta package. 用法与 Microsoft.Graph 包相同。Usage is the same as the Microsoft.Graph package.

using Microsoft.Graph.Beta;

// Create a new instance of GraphServiceClient.
GraphServiceClient graphClient = new GraphServiceClient(...);