public ActionResult <List <CidadaoViewModel> > GetCidadaoByIdProntuarioIdAgente([FromHeader] string ibge, [FromQuery] int?id_prontuario, int id_agente) { try { ibge = _config.GetConnectionString(Connection.GetConnection(ibge)); List <CidadaoViewModel> lista = _cidadaoRepository.GetCidadaoByIdProntuarioIdAgente(ibge, id_prontuario, id_agente); return(Ok(lista)); } catch (Exception ex) { var response = TrataErro.GetResponse(ex.Message, true); return(StatusCode((int)HttpStatusCode.InternalServerError, response)); } }