I've been banging my head against the wall for the past couple of hours, here's what we're trying to do: a method expects a primitive/simple type as the request body. Originally we tried with a boolean, but that didn't work so we tried with string and object. Same thing.
Here's the server-side code
[OperationContract]
[WebInvoke(UriTemplate = "/foo/{foo_id}/bar", Method = "POST", ResponseFormat=WebMessageFormat.JSON)]
string G(string foo_id, string content);
And here's the request in Fiddler:
Header:
User-Agent: Fiddler
Host: localhost
Content-Type: 'application/json',
Content-Length: 19
Body:
"hello_world"
We tried to wrap "hello_world"
in a json object, like {"content":"hello_world"} but no luck.
Any thoughts?