Microsoft.Graph.Core 1.8.1 The ID prefix of this package has been reserved for one of the owners of this package by Prefix Reserved

.NET Standard 1.1 .NET Framework 4.5
There is a newer version of this package available.
See the version list below for details.
Install-Package Microsoft.Graph.Core -Version 1.8.1
dotnet add package Microsoft.Graph.Core --version 1.8.1
<PackageReference Include="Microsoft.Graph.Core" Version="1.8.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Microsoft.Graph.Core --version 1.8.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Microsoft.Graph.Core, 1.8.1"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install Microsoft.Graph.Core as a Cake Addin
#addin nuget:?package=Microsoft.Graph.Core&version=1.8.1

// Install Microsoft.Graph.Core as a Cake Tool
#tool nuget:?package=Microsoft.Graph.Core&version=1.8.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Microsoft Graph .NET Client Library

Build status NuGet Version

Integrate the Microsoft Graph API into your .NET project!

The Microsoft Graph .NET Client Library targets .NetStandard 1.1 and .Net Framework 4.5.

Installation via NuGet

To install the client library via NuGet:

  • Search for Microsoft.Graph in the NuGet Library, or
  • Type Install-Package Microsoft.Graph into the Package Manager Console.

Getting started

1. Register your application

Register your application to use Microsoft Graph API using one of the following supported authentication portals:

2. Authenticate for the Microsoft Graph service

The Microsoft Graph .NET Client Library does not include any default authentication implementations. Instead, the user will want to authenticate with the library of their choice, or against the OAuth endpoint directly, and built-in DelegateAuthenticationProvider class to authenticate each request. For more information on DelegateAuthenticationProvider, see the library overview

The recommended library for authenticating against AAD is ADAL.

For an example of authenticating a UWP app using the V2 Authentication Endpoint, see the Microsoft Graph UWP Connect Library.

3. Create a Microsoft Graph client object with an authentication provider

An instance of the GraphServiceClient class handles building requests, sending them to Microsoft Graph API, and processing the responses. To create a new instance of this class, you need to provide an instance of IAuthenticationProvider which can authenticate requests to Microsoft Graph.

For more information on initializing a client instance, see the library overview

4. Make requests to the graph

Once you have completed authentication and have a GraphServiceClient, you can begin to make calls to the service. The requests in the SDK follow the format of the Microsoft Graph API's RESTful syntax.

For example, to retrieve a user's default drive:

var drive = await graphClient.Me.Drive.Request().GetAsync();

GetAsync will return a Drive object on success and throw a ServiceException on error.

To get the current user's root folder of their default drive:

var rootItem = await graphClient.Me.Drive.Root.Request().GetAsync();

GetAsync will return a DriveItem object on success and throw a ServiceException on error.

For a general overview of how the SDK is designed, see overview.

The following sample applications are also available:

Documentation and resources


Install NewtonSoft.Json first if you want to use a version greater than NewtonSoft.Json 6.0.1. For example, you'll need to install NewtonSoft.Json 9.0.1 first if you want to use this to library while targeting .Net Core with standard1.0.

Install System.Runtime.InteropServices.RuntimeInformation before you install Microsoft.Graph >=1.3 if you are having an issue updating the package for a Xamarin solution. You may need to updated references to Microsoft.NETCore.UniversalWindowsPlatform to >=5.2.2 as well.


To view or log issues, see issues.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact with any additional questions or comments.

Other resources

Building library locally

If you are looking to build the library locally for the purposes of contributing code or running tests, you will need to:

  • Have the .NET Core SDK (> 1.0) installed
  • Run dotnet restore from the command line in your package directory
  • Run nuget restore and msbuild from CLI or run Build from Visual Studio to restore Nuget packages and build the project


Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT license. See Third Party Notices for information on the packages referenced via NuGet.

Product Versions
.NET net5.0 net5.0-windows net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows
.NET Core netcoreapp1.0 netcoreapp1.1 netcoreapp2.0 netcoreapp2.1 netcoreapp2.2 netcoreapp3.0 netcoreapp3.1
.NET Standard netstandard1.1 netstandard1.2 netstandard1.3 netstandard1.4 netstandard1.5 netstandard1.6 netstandard2.0 netstandard2.1
.NET Framework net45 net451 net452 net46 net461 net462 net463 net47 net471 net472 net48
MonoAndroid monoandroid
MonoMac monomac
MonoTouch monotouch
Tizen tizen30 tizen40 tizen60
Universal Windows Platform uap uap10.0
Windows Phone wpa81
Windows Store netcore netcore45 netcore451
Xamarin.iOS xamarinios
Xamarin.Mac xamarinmac
Xamarin.TVOS xamarintvos
Xamarin.WatchOS xamarinwatchos
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (27)

Showing the top 5 NuGet packages that depend on Microsoft.Graph.Core:

Package Downloads
Microsoft.Graph The ID prefix of this package has been reserved for one of the owners of this package by

Microsoft Graph Client Library allows you to call Office 365, Azure AD and other Microsoft services through a single unified developer experience.

Microsoft.Graph.Auth The ID prefix of this package has been reserved for one of the owners of this package by

Microsoft Graph Authentication Library implements authentication functionality used by Microsoft Graph Client Library. It provides a set of OAuth scenario-centric providers that implement Microsoft.Graph.IAuthenticationProvider and uses Microsoft Authentication Library (MSAL) to handle access token acquisition and storage.

Microsoft.Graph.Beta The ID prefix of this package has been reserved for one of the owners of this package by

Microsoft Graph beta client library allows you to target the Microsoft Graph /beta endpoint. You can call Office 365, Azure AD and other Microsoft services through a single unified developer experience.


PnP Framework contains the PnP Provisioning engine and a ton of extension methods that will make you more productive while developing for Microsoft 365.

Microsoft.Graph.Communications.Core The ID prefix of this package has been reserved for one of the owners of this package by

Microsoft Graph Communications Client Core Library - This library builds on the Microsoft.Graph SDK to provide better support for the Communications APIs.

GitHub repositories (16)

Showing the top 5 popular GitHub repositories that depend on Microsoft.Graph.Core:

Repository Stars
SharePoint / Office 365 Developer Patterns and Practices - Archived older solutions. Please see for updated guidance
Free open source office suite with business productivity tools: document and project management, CRM, mail aggregator.
SharePoint PnP PowerShell CmdLets
A cloud storage provider plugin for KeePass Password Safe
Microsoft Graph Client Library for .NET!
Version Downloads Last updated
3.0.0-preview.6 205 5/20/2022
3.0.0-preview.5 1,080 5/4/2022
3.0.0-preview.4 1,291 4/13/2022
3.0.0-preview.3 94 4/12/2022
3.0.0-preview.2 665 4/1/2022
3.0.0-preview.1 754 3/22/2022
2.0.8 534,951 2/18/2022
2.0.7 962,436 12/16/2021
2.0.6 97,084 12/2/2021
2.0.5 1,740,803 9/1/2021
2.0.4 21,615 8/24/2021
2.0.3 190,708 8/17/2021
2.0.2 116,949 8/11/2021
2.0.1 73,426 8/5/2021
2.0.0 220,398 7/22/2021
2.0.0-preview.14 1,859 7/7/2021
2.0.0-preview.13 21,771 6/18/2021
2.0.0-preview.12 25,433 6/7/2021
2.0.0-preview.11 40,275 5/7/2021
2.0.0-preview.10 17,487 4/21/2021
2.0.0-preview.9 15,870 4/1/2021
2.0.0-preview.8 28,928 3/17/2021
2.0.0-preview.7 402 3/2/2021
2.0.0-preview.6 250 2/24/2021
2.0.0-preview.5 144 2/24/2021
2.0.0-preview.4 4,213 1/6/2021
2.0.0-preview.3 17,522 4/29/2020
2.0.0-preview.2 1,686 4/9/2020
2.0.0-preview.1 13,682 3/9/2020
1.25.1 3,048,475 3/25/2021
1.25.1-preview.2 139 3/25/2021
1.25.1-preview.1 160 3/25/2021
1.25.0 155,696 3/25/2021
1.25.0-preview.2 172 3/20/2021
1.25.0-preview.1 381 3/17/2021
1.24.0 1,739,010 1/19/2021
1.24.0-preview.1 187 1/14/2021
1.23.0 1,562,932 11/26/2020
1.22.0 2,063,820 10/7/2020
1.22.0-preview.2 249 10/6/2020
1.22.0-preview.1 270 7/28/2020
1.21.0 1,513,904 7/28/2020
1.21.0-preview.1 2,910 6/19/2020
1.20.1 3,361,433 3/31/2020
1.20.0 2,799,029 2/5/2020
1.19.0 2,120,703 12/11/2019
1.18.0 1,018,679 10/10/2019
1.17.0 736,403 8/15/2019
1.16.0 95,168 7/3/2019
1.15.0 1,550,460 5/1/2019
1.14.1 111,318 3/29/2019
1.14.0 744,961 3/25/2019
1.12.0 1,047,202 10/31/2018
1.11.0 287,741 9/19/2018
1.10.0 379,765 7/6/2018
1.9.0 843,633 5/3/2018
1.8.1 202,403 3/23/2018
1.7.0 177,492 12/14/2017
1.6.2 155,154 9/26/2017
1.6.1 66,423 8/24/2017
1.6.0 35,707 8/8/2017
1.5.0 233,296 6/12/2017
1.4.0 222,080 5/10/2017
1.3.1 50,962 4/3/2017
1.3.0 193,125 11/8/2016
1.2.1 122,915 9/27/2016
1.1.1 8,662 8/8/2016
1.1.0 1,537 8/6/2016

March 2018 Release Summary (version 1.8.0)

     New features
     * Update Json.NET dependency to include 11.x