Class GraphAuthClient
The graph auth client.
Namespace: Microsoft.Graph.Communications.Client.Transport
Assembly: Microsoft.Graph.Communications.Client.dll
Syntax
public class GraphAuthClient : GraphHttpClient
Constructors
GraphAuthClient(IGraphLogger, JsonSerializerSettings, HttpClient, IRequestAuthenticationProvider, ProductInfoHeaderValue, IEnumerable<IGraphProperty>)
Initializes a new instance of the GraphAuthClient class.
Declaration
public GraphAuthClient(IGraphLogger logger, JsonSerializerSettings jsonSerializerSettings, HttpClient httpClient, IRequestAuthenticationProvider authenticationProvider, ProductInfoHeaderValue userAgent, IEnumerable<IGraphProperty> defaultProperties)
Parameters
Type | Name | Description |
---|---|---|
IGraphLogger | logger | The logger. |
Newtonsoft.Json.JsonSerializerSettings | jsonSerializerSettings | The json serializer settings. |
HttpClient | httpClient | The HTTP client. |
IRequestAuthenticationProvider | authenticationProvider | The authentication provider. |
ProductInfoHeaderValue | userAgent | The user agent. |
IEnumerable<IGraphProperty> | defaultProperties | The default properties. |
Exceptions
Type | Condition |
---|---|
ArgumentNullException | If the authentication provider is null. |
Methods
SendHttpRequestAsync<T1, T2>(IGraphRequest<T1>, CancellationToken)
Declaration
protected override Task<IGraphResponse<T2>> SendHttpRequestAsync<T1, T2>(IGraphRequest<T1> graphRequest, CancellationToken cancellationToken)
where T1 : class where T2 : class
Parameters
Type | Name | Description |
---|---|---|
IGraphRequest<T1> | graphRequest | |
CancellationToken | cancellationToken |
Returns
Type | Description |
---|---|
Task<IGraphResponse<T2>> |
Type Parameters
Name | Description |
---|---|
T1 | |
T2 |