public IHttpActionResult PostMedicamento(Medicamento medicamento) { if (!ModelState.IsValid) { return(BadRequest(ModelState)); } medicamentoService.Create(medicamento); return(CreatedAtRoute("DefaultApi", new { id = medicamento.Id }, medicamento)); }