var client = new RestClient("https://example.com/DataService/CustomerData/GetCustomerActivityDailySummary"); ServicePointManager.Expect100Continue = true; ServicePointManager.DefaultConnectionLimit = 9999; ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12; var certFile = Path.Combine(@"D:\myproject\", "certificate1.pfx"); X509Certificate2 certificate = new X509Certificate2(certFile, "12345678)"); client.ClientCertificates = new X509CertificateCollection() { certificate }; client.Proxy = new WebProxy(); var restrequest = new RestRequest(Method.POST); restrequest.AddHeader("Cache-Control", "no-cache"); restrequest.AddHeader("Accept", "application/json"); restrequest.AddHeader("Content-Type", "application/json"); restrequest.AddParameter("here i have added the request parameter",ParameterType.RequestBody); IRestResponse response = client.Execute(restrequest);
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)