(uf)
| 53 | }); |
| 54 | |
| 55 | export const getContiesByUf = async (uf) => { |
| 56 | const { data } = await axios.get(`${URL_UF}/${uf}/municipios`); |
| 57 | |
| 58 | return data.map((item) => ({ |
| 59 | nome: item.nome, |
| 60 | codigo_ibge: `${item.id}`, |
| 61 | })); |
| 62 | }; |
| 63 | |
| 64 | // reference: https://servicodados.ibge.gov.br/api/docs/agregados?versao=3#api-Variaveis-agregadosAgregadoPeriodosPeriodosVariaveisVariavelGet |
| 65 | export const getUfEstimatePopulationByCode = async (uf) => { |