title: Pass List object to C# Web Api POST
body: <p>I am trying to pass a List to my Web API but I keep getting a null value. I am converting the list in to a string before passing it to the API. Any ideas how can I bind it correctly?  </p>
  
  <pre><code>public async Task&lt;ReturnViewModel&gt; ModContactsAsync(List&lt;ContactsDTO&gt; Contacts)
   {
       ReturnViewModel vm = new ReturnViewModel();
  
      var postContactsUri = new UriBuilder(AppConfig.ServiceUrlBase);
  
      //Converts object into a string
      var jsonObject = new JavaScriptSerializer().Serialize(Contacts);
  
  
      postContactsUri.Path = string.Format(POST_CONTACTS_API_PATH, jsonObject);
      //Calls API
      var response = await _httpClient.PostAsync(postContactsUri.ToString());
  
      return vm;
  }
  </code></pre>
  
  <p>POST - API CALL List prod is null</p>
  
  <pre><code>[HttpPost]
  [Route("contacts/Save")]
  [ResponseType(typeof(ReturnMessage))]
  public async Task&lt;IHttpActionResult&gt; ModContacts([FromBody] List&lt;ContactsDTO&gt; prods)
  {
      try
      {
          await Task.Delay(10);
  
          return Ok();
      }
      catch (Exception ex)
      {
          throw new PropertyPortalWebApiException(HttpStatusCode.InternalServerError, "Contact information does not exist.", ex);
      }
    }
  </code></pre>