Ejemplo n.º 1
0
        public async Task <bool> SetCommentTone(CommentTone toneUpdate)
        {
            try
            {
                var content = new StringContent(JsonSerializer.Serialize(toneUpdate), Encoding.UTF8, "application/json");
                using HttpResponseMessage result = await _client.PutAsync(_options.EndPoint, content);

                return(result.StatusCode == HttpStatusCode.NoContent);
            }
            catch (Exception)
            {
                return(false);
            }
        }
Ejemplo n.º 2
0
 public async Task <bool> SetCommentTone(CommentTone commentTone)
 {
     return(await _client.SetCommentTone(commentTone));
 }