I am executing one SSIS package. I am trying to call one web api from that package.
My code:
IList<ESignDocumentServiceResponse> responseCollection = null;
HttpClient httpClient = new HttpClient();
httpClient.BaseAddress = new Uri(url);
HttpResponseMessage response = httpClient.GetAsync($"api/abc").Result;
responseCollection = response.Content.ReadAsAsync<IList<DocumentServiceResponse>>().Result;
But i am getting an error at line ReadAsAsync as
"Error: Download failed: Could not load file or assembly 'System.Net.Http.Formatting, Version=5.2.3.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified."
I have already added System.net.http.formatting in the project. But i am not sure why am i getting this error when i run this project.