restsharp/RestSharp — pull request #573 by davidgrupp (2014-10-04 00:15:53+00:00)
Title: Added clearer comments for RestRequest.AddBody and additional RestRequest.AddJsonBody and RestRequest.AddXmlBody

It can be unintuitive that you need to first specify the RequestFormat is JSON to have the RestRequest serialize data to JSON. This leads to hard to debug HTTP responses saying that the JSON format is incorrect because by default the data is serialized to XML. This is further compounded by endless suggestions on popular forums and message boards that you manually need to set the ‘Content-Type’ header to be ‘application/json’ making this a difficult product to use out of the box.