Skip to content

Instantly share code, notes, and snippets.

@maisarissi
Last active February 9, 2023 13:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save maisarissi/b3e811d959d091ed88b7f684ab9e1dd9 to your computer and use it in GitHub Desktop.
Save maisarissi/b3e811d959d091ed88b7f684ab9e1dd9 to your computer and use it in GitHub Desktop.
msgraph-dotnet-v5-rc-v1-beta-clients
InteractiveBrowserCredential interactiveBrowserCredential = new ("ClientID");
//create client for calling v1 endpoint and get my info
Microsoft.Graph.GraphServiceClient graphServiceClient = new (tokenCredential, scopes);
var userFromV1 = await graphServiceClient.Me.GetAsync();
//create client for calling beta endpoint and get my info
Microsoft.Graph.Beta.GraphServiceClient betaGraphServiceClient = new(tokenCredential, scopes);
var userFromBeta = await betaGraphServiceClient.Me.GetAsync();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment