using System; using System.Collections.Generic; using System.Linq; using System.Net.Http.Headers; using System.Text; using System.Threading.Tasks; namespace Servicios.API { public class Persona { private readonly HttpClient _httpClient; public Persona() { _httpClient = new HttpClient() { BaseAddress = new Uri("http://localhost:46647/api/Persona") }; _httpClient.DefaultRequestHeaders.Accept.Clear(); _httpClient.DefaultRequestHeaders.Accept.Add(new MediaTypeWithQualityHeaderValue("application/json")) } } }