public async Task <HttpResponseMessage> Post([FromBody] BatchDto batch) { try { var response = Request.CreateResponse(HttpStatusCode.OK, await logic.AddNewBatch(batch)); logger.Info("Add new batch successful"); return(response); } catch (Exception ex) { LogHelper.ErrorLogger(logger, ex); return(Request.CreateResponse(HttpStatusCode.BadRequest)); } }