public async Task <HttpResponseMessage> AddVeiculo(Veiculo veiculo) { HttpResponseMessage response = new HttpResponseMessage(); try { await VeiculoDAO.AddVeiculoAsync(veiculo); response.StatusCode = HttpStatusCode.OK; } catch (Exception ex) { response.Content = new ObjectContent(typeof(Exception), ex, JsonConfig.DefaultJsonMediaType); response.StatusCode = HttpStatusCode.InternalServerError; } ApiLog(response.StatusCode); return(response); }