https://github.com/leoguilen/serveless_functions_ibge
Functions que retornam informações sobre localizações disponibilizadas pela API do IBGE, que serão reutilizadas em outros projetos
https://github.com/leoguilen/serveless_functions_ibge
functions serveles
Last synced: 3 months ago
JSON representation
Functions que retornam informações sobre localizações disponibilizadas pela API do IBGE, que serão reutilizadas em outros projetos
- Host: GitHub
- URL: https://github.com/leoguilen/serveless_functions_ibge
- Owner: leoguilen
- Created: 2020-06-06T15:33:00.000Z (almost 5 years ago)
- Default Branch: master
- Last Pushed: 2023-01-06T08:07:01.000Z (over 2 years ago)
- Last Synced: 2025-01-08T08:46:05.933Z (4 months ago)
- Topics: functions, serveles
- Language: JavaScript
- Homepage:
- Size: 934 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 15
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
IBGE Serveless Functions
This project is published in
URL Base: https://ibgefunctions.netlify.app/.netlify
/functions/estados
/functions/cidades?uf=SP
[](https://app.netlify.com/sites/ibgefunctions/deploys)
![]()
## :information_source: How To Use
To clone and run this application, you'll need [Git](https://git-scm.com), [Node.js v10.16][nodejs] or higher + [Yarn v1.13][yarn] or higher installed on your computer. From your command line:
- ### **Dev Mode**
```bash
# Clone this repository
$ git clone https://github.com/leoguilen/serveless_functions_ibge.git# Install dependencies
$ npm install# Run the app
$ npm start
```You can test in browser using url http://localhost:9000. Routes to functions:
##### **/functions/estados** - *Return all states of brazil*
```json
// http://localhost:9000/estados[
{...},
{
"id": 35,
"sigla": "SP",
"nome": "São Paulo",
"regiao": {
"id": 3,
"sigla": "SE",
"nome": "Sudeste"
}
}
]
```**/functions/cidades?uf={uf do estado}** ***- Return all cities in specific state***
```json
// http://localhost:9000/cidades?uf=SP[
{...},
{
"nome": "Adamantina"
},
]
```---
Made with ♥ by Leonardo Guilen :wave: [Get in touch!](https://www.linkedin.com/in/leonardo-guilen/)
[nodejs]: https://nodejs.org/
[npm]: https://www.npmjs.com/
[vc]: https://code.visualstudio.com/