title: odata action accepting list parameter is always null
body: <p>I have a problem with an odata controller.</p>
  
  <p>I wish to send a list of Address-objects, but the received parameter is always null.</p>
  
  <p>My end-point looks like this:</p>
  
  <pre><code>    [EnableQuery]
      public IHttpActionResult SetCoordinatesOnAddressList(IEnumerable&lt;Address&gt; addresses)
      {
          var result = addresses.Select(address =&gt; _coordinates.GetAddressCoordinates(address)).ToList();
          return Ok(result);
      } 
  </code></pre>
  
  <p>I have this set up in WebApiConfig</p>
  
  <pre><code>builder.EntityType&lt;Address&gt;().Collection
              .Action("SetCoordinatesOnAddressList")
              .ReturnsFromEntitySet&lt;Address&gt;("Addresses");
  </code></pre>
  
  <p>I am using Postman to send requests.</p>
  
  <p>My request is sent as a post-request and looks like this:</p>
  
  <pre><code>[{"StreetName":"Some street","StreetNumber":"8","ZipCode":1234,"Town":"Some town"}]
  </code></pre>
  
  <p>I have a different end-point which takes a single Address instead of an IEnumerable, and that works with the same json-request (without []), so the fields in the json are correct.</p>
  
  <p>So to sum up:
  My endpoint for an IEnumerable always receives null.
  Any ideas what might be causing it?</p>
  
  <p>Thank you.</p>
  
  <p>Edit:</p>
  
  <p>I tried changing my end-point to accept an AddressDTO instead, like this:</p>
  
  <pre><code>public IHttpActionResult SetCoordinatesOnAddressList(AddressDTO addresses)
  {
      return Ok(2);
  }
  </code></pre>
  
  <p>and this is an AddressDTO:</p>
  
  <pre><code>public class AddressDTO
  {
      public IEnumerable&lt;Address&gt; Addresses { get; set; }
  }
  </code></pre>
  
  <p>If I try to post this:</p>
  
  <pre><code>{"Addresses": [{"StreetName":"Some street","StreetNumber":"8","ZipCode":1234,"Town":"Some town"}]}
  </code></pre>
  
  <p>I get this error:</p>
  
  <pre><code>{
    "error": {
      "code": "",
      "message": "The request entity's media type 'application/json' is not supported for this resource.",
      "innererror": {
        "message": "No MediaTypeFormatter is available to read an object of type 'AddressDTO' from content with media type 'application/json'.",
        "type": "System.Net.Http.UnsupportedMediaTypeException",
        "stacktrace": "   at System.Net.Http.HttpContentExtensions.ReadAsAsync[T](HttpContent content, Type type, IEnumerable`1 formatters, IFormatterLogger formatterLogger, CancellationToken cancellationToken)\\\r\\\n   at System.Net.Http.HttpContentExtensions.ReadAsAsync(HttpContent content, Type type, IEnumerable`1 formatters, IFormatterLogger formatterLogger, CancellationToken cancellationToken)\\\r\\\n   at System.Web.Http.ModelBinding.FormatterParameterBinding.ReadContentAsync(HttpRequestMessage request, Type type, IEnumerable`1 formatters, IFormatterLogger formatterLogger, CancellationToken cancellationToken)"
      }
    }
  }
  </code></pre>