ITeamsTurnContext.GetAppGraphClient(String) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Creates a Microsoft.Graph.GraphServiceClient authenticated with an app-only (application) token, using the token connection resolved for the current turn.
public Microsoft.Graph.GraphServiceClient GetAppGraphClient(string graphBaseUrl = "https://graph.microsoft.com/v1.0");
abstract member GetAppGraphClient : string -> Microsoft.Graph.GraphServiceClient
Public Function GetAppGraphClient (Optional graphBaseUrl As String = "https://graph.microsoft.com/v1.0") As GraphServiceClient
Parameters
- graphBaseUrl
- String
The base URL for the Microsoft Graph API. Defaults to "https://graph.microsoft.com/v1.0".
Returns
A Microsoft.Graph.GraphServiceClient authenticated with an app-only token.
Remarks
Unlike GetGraphClient(String, String), this method uses application permissions, so the caller must specify the target resource in the request path (for example client.Users["{userId}"]...). No configuration beyond the agent's existing token connection is required.