Registered app ID that was used for authorization.
The Azure AD user that has delegated Graph API permissions via the authorization process.
Terminates the connection to Microsoft 365 and cleans up utilized resources.
Azure AD tenant ID where the app that was used for authorization has been registered.
Executes a request to the specified endpoint of the Graph API.
For POST/PATCH requests, Content-Type header is set to "application/json" by default and so data parameter can simply be set to an object.
Note: depending on which Graph API endpoint is being requested, you may need to include additional permissions when connecting.
Response containing the response HTTP status code requested data (if relevant).
ApiRequestError if an error occurred when sending the request, or if the Graph API responded with an error HTTP response code.
AuthTokenExpiredError if the current access token has expired and cannot be renewed. In this instance, you must re-connect before continuing to use this API.
A type that describes the requested data. Note: Microsoft provide a large library of Graph API types via the @microsoft/microsoft-graph-types NPM package which we recommend using for specifying requested data types.
The relative Graph API endpoint being requested (e.g. /v1.0/me).
Optional httpMethod: HttpMethodThe HTTP Method to use when making the request (defaults to GET).
Optional data: anyOptionally include data in the request body (for POST/PATCH requests).
Optional headers: HeadersInitOptionally set additional request headers. Important: do not attempt to set the Authorization header manually as the API will include it automatically (as long as includeAuthorization is not set to false).
Optional includeAuthorization: booleanWhether the Authorization header will be added automatically. Defaults to 'true', set this to false when making requests to endpoints that do not expect an Authorization header.
Generated using TypeDoc
A connection to a Microsoft 365 instance.