Exemplo n.º 1
0
        public async Task <RestResponse <T> > SendAsync <T>(HttpRequestMessage request)
        {
            try
            {
                using var response = await _client.SendAsync(request).ConfigureAwait(false);

                return(await _builder.Build <T>(response).ConfigureAwait(false));
            }
            catch (Exception e)
            {
                return(_builder.Error <T>(null, "HttpClientException", e.Message));
            }
        }