My C# web api:
[HttpPost]
[Route("freeworks")]
public IHttpActionResult Post([FromBody]List<AgadoFreeWork> value)
{
and I try to test POST as XML
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<AgadoFreeWork>
<IsPublished>true</IsPublished>
....
but I am getting back
{
Message: "The request is invalid."
ModelState: {
value: [1]
0: "Error in line 1 position 23. Expecting element 'ArrayOfAgadoFreeWork' from namespace 'http://schemas.datacontract.org/2004/07/Agado.Restful.Classes'.. Encountered 'Element' with name 'ArrayOfAgadoFreeWork', namespace ''. "
-
}-
}