{"id":19828544,"url":"https://github.com/eltonsantos/consuming-api","last_synced_at":"2026-04-09T08:37:22.869Z","repository":{"id":145397717,"uuid":"373626978","full_name":"eltonsantos/consuming-api","owner":"eltonsantos","description":"Consumingo API - Vídeo: Consumindo API no Front e no Back-end | CodeDrops #45 - Instrutor: Mayk Brito - Link: https://www.youtube.com/watch?v=vYlz3SmNXQQ","archived":false,"fork":false,"pushed_at":"2021-06-04T00:40:15.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-28T21:01:07.498Z","etag":null,"topics":["api","axios","cors","express","lite-server","nodejs","nodemon"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/eltonsantos.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-06-03T20:01:34.000Z","updated_at":"2021-06-04T00:40:17.000Z","dependencies_parsed_at":"2023-06-03T17:00:20.987Z","dependency_job_id":null,"html_url":"https://github.com/eltonsantos/consuming-api","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/eltonsantos/consuming-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltonsantos%2Fconsuming-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltonsantos%2Fconsuming-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltonsantos%2Fconsuming-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltonsantos%2Fconsuming-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/eltonsantos","download_url":"https://codeload.github.com/eltonsantos/consuming-api/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/eltonsantos%2Fconsuming-api/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":264763130,"owners_count":23660303,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["api","axios","cors","express","lite-server","nodejs","nodemon"],"created_at":"2024-11-12T11:16:14.541Z","updated_at":"2026-04-09T08:37:17.823Z","avatar_url":"https://github.com/eltonsantos.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n  \u003cstrong\u003eConsuming API in frontend and backend\u003c/strong\u003e\n\u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"#-technologies\"\u003eTechnologies\u003c/a\u003e\u0026nbsp;\u0026nbsp;\u0026nbsp;|\u0026nbsp;\u0026nbsp;\u0026nbsp;\n  \u003ca href=\"#-getting-started\"\u003eGetting started\u003c/a\u003e\u0026nbsp;\u0026nbsp;\u0026nbsp;|\u0026nbsp;\u0026nbsp;\u0026nbsp;\n  \u003ca href=\"#-project\"\u003eProject\u003c/a\u003e\u0026nbsp;\u0026nbsp;\u0026nbsp;|\u0026nbsp;\u0026nbsp;\u0026nbsp;\n  \u003ca href=\"#-what-was-learned\"\u003eWhat was learned?\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cbr\u003e\n\n---\n\n## 🧪 Technologies\n\nThis project was developed using the following technologies:\n\n- [Node](https://nodejs.org/)\n- [Nodemon](https://www.npmjs.com/package//nodemon)\n- [Axios](https://axios-http.com/)\n- [Express](https://expressjs.com/)\n\n## 🚀 Getting started\n\nClone the project and access the folder\n\n```bash\n$ git clone https://github.com/eltonsantos/consuming-api.git \u0026\u0026 cd consuming-api\n```\n\nFollow the steps below\n\n```bash\n# Install the dependencies\n$ npm install\n\n# Start the lite-server\n$ npx lite-server\n\n# Frontend\n$ npm run start\n\n# Backend\n$ npm run dev\n\n```\nFor lite-server access: **http://localhost:3000** and for front/back access: **http://localhost:4567**\n\n## 💻 Project\n\nSimple example of how consuming an API in frontend and backend.🥰\n\n## 🤔 What was learned?\n\n###### Escreverei essa parte em português\n\n#### Criar uma API\n- [ ] Iniciar o projeto `npm init -y`\n- [ ] Instalar as dependências `npm i express nodemon cors axios`\n- [ ] Criar uma rota para acessar a API\n- [ ] Servir a API\n- [ ] Habilitar o CORS\n- [ ] Habilitar o nodemon para reiniciar o server\n\n### frontend\n\n#### Consumir API\n- [ ] Utilizar fetch para consumir nossa API backend\n- [ ] Explicar Promise - Async/Await\n- [ ] Usar try/catch\n- [ ] Mostrar a resposta na tela\n\n### backend\n\n#### Consumir API\n- [ ] [Jsonplaceholder](https://jsonplaceholder.typicode.com/)\n- [ ] Usar axios\n- [ ] Semelhanças entre axios e fetch\n- [ ] Usar try/catch\n\n---\n\n## 👨🏻‍💻 Author\n\n\u003ch3 align=\"center\"\u003e\n  \u003cimg style=\"border-radius: 50%\" src=\"https://avatars3.githubusercontent.com/u/1292594?s=460\u0026u=0b1bfb0fc81256c59dc33f31ce344231bd5a5286\u0026v=4\" width=\"100px;\" alt=\"\"/\u003e\n  \u003cbr/\u003e\n  \u003cstrong\u003eElton Santos\u003c/strong\u003e 🚀\n  \u003cbr/\u003e\n  \u003cbr/\u003e\n\n \u003ca href=\"https://www.linkedin.com/in/eltonmelosantos\" alt=\"LinkedIn\" target=\"blank\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/-LinkedIn-blue?style=flat-square\u0026logo=Linkedin\u0026logoColor=white\" /\u003e\n  \u003c/a\u003e\n\n  \u003ca href=\"mailto:elton.melo.santos@gmail.com?subject=Olá%20Elton\" alt=\"Email\" target=\"blank\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/-Gmail-c14438?style=flat-square\u0026logo=Gmail\u0026logoColor=white\u0026link=mailto:elton.melo.santos@gmail.com\" /\u003e\n  \u003c/a\u003e\n\n\u003cbr/\u003e\n\nMade with ❤️ by Elton Santos 👋🏽 [Entre em contato!](https://www.linkedin.com/in/eltonmelosantos/)\n\n\u003c/h3\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feltonsantos%2Fconsuming-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Feltonsantos%2Fconsuming-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Feltonsantos%2Fconsuming-api/lists"}