public async Task <GraphQLHttpResponse <TResponse> > SendHttpMutationAsync <TVariable, TResponse>(GraphQLHttpRequest <TVariable> request, CancellationToken cancellationToken = default) { await Task.CompletedTask; throw new NotImplementedException(); }
public async Task <GraphQLHttpResponse <TResponse> > SendHttpQueryAsync <TVariable, TResponse>(GraphQLHttpRequest <TVariable> request, CancellationToken cancellationToken = default) { using var httpRequestMessage = this.GenerateHttpRequestMessage(request); using var httpResponseMessage = await this.httpClient.SendAsync(httpRequestMessage, cancellationToken); if (!httpResponseMessage.IsSuccessStatusCode) { throw new GraphQLHttpException(httpResponseMessage); } var bodyStream = await httpResponseMessage.Content.ReadAsStreamAsync(); return(await JsonSerializer.DeserializeAsync <GraphQLHttpResponse <TResponse> >(bodyStream, this.JsonSerializerOptions, cancellationToken)); }
public async Task <GraphQLHttpResponse <TResponse> > SendHttpQueryAsync <TResponse>(GraphQLHttpRequest request, CancellationToken cancellationToken = default) => await this.SendHttpQueryAsync <dynamic, TResponse>(request, cancellationToken);
public Task <GraphQLHttpResponse <R> > SendMutationAsync <V, R>(GraphQLHttpRequest <V> request, CancellationToken cancellationToken = default) { throw new NotImplementedException(); }