Skip to content

Instantly share code, notes, and snippets.

@sebastienlevert
Last active May 26, 2022 16:32
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 sebastienlevert/b360ecf0070f76754cc5008399e6f53d to your computer and use it in GitHub Desktop.
Save sebastienlevert/b360ecf0070f76754cc5008399e6f53d to your computer and use it in GitHub Desktop.
Samples for the Graph SDK Build 2022 Announcement
// Sample for .NET
var graphClient = new GraphServiceClient(credential, scopes);
var result = await graphClient.Me.Drive.GetAsync();
// Sample for Go
client := msgraphsdk.NewGraphServiceClient(adapter)
result, err := client.Me().Drive().Get()
// Sample for Javascript
const graphServiceClient = GraphServiceClient.init({ authProvider });
const result = await graphServiceClient.me.drive.get();
# Sample for CLI
mgc login --scopes User.Read Files.Read
mgc me drive get
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment