title: make HttpClient Request visual c# with request headers and body
body: <p>I want to make a request with HttpClient for with below format:
  Headers:</p>
  
  <pre><code>X-Requested-With: XMLHttpRequest
  User-Agent: .....  //etc.
  </code></pre>
  
  <p>Important part is request body that makes me confused:</p>
  
  <pre><code>{"jsonrpc":"2.0","method":"getPostList","id":1,"params":[[["place2",0,["10"]]],0]}
  </code></pre>
  
  <p>I made some code like this:</p>
  
  <pre><code>HttpClient h = new HttpClient();
  
  h.DefaultRequestHeaders.Add("X-Requested-With","XMLHttpRequest");
  h.DefaultRequestHeaders.Add("User-Agent", "Mozilla/5.0 (Windows NT 6.2; WOW64; rv:33.0) Gecko/20100101 Firefox/33.0");
  h.DefaultRequestHeaders.Add("Referer","http://urmia.divar.ir/browse/");
  h.DefaultRequestHeaders.Add("Pragma","no-cache");
  h.DefaultRequestHeaders.Add("Host","urmia.divar.ir");
  //h.DefaultRequestHeaders.Add("Content-Type","application/json; charset=UTF-8");
  h.DefaultRequestHeaders.Add("Connection","keep-alive");
  h.DefaultRequestHeaders.Add("Accept-Language","en-US,en;q=0.5");
  h.DefaultRequestHeaders.Add("Accept-Encoding","gzip, deflate");
  h.DefaultRequestHeaders.Add("Accept","application/json, text/javascript, */*; q=0.01");
  
  var request = new HttpRequestMessage(HttpMethod.Post, "http://urmia.divar.ir/json/");
  
  request.Content.Headers.AddWithoutValidation("jsonrpc","2.0");
  request.Content.Headers.Add("method", "getPostList");
  request.Content.Headers.Add("id", "1");
  request.Content.Headers.Add("params", "[[[\"place2\",0,[\"10\"]]],0]");
  </code></pre>
  
  <p>but it gives error for request.Content.Headers.add....</p>