{"id":15174001,"url":"https://github.com/diego64/api-from-academy","last_synced_at":"2026-02-03T15:07:29.758Z","repository":{"id":249724772,"uuid":"832335150","full_name":"diego64/api-from-academy","owner":"diego64","description":"API whose main objective is to serve WEB applications focused on gyms so that owners can register their gyms and users can mark their presence always within a limit of 10 meters","archived":false,"fork":false,"pushed_at":"2024-08-25T00:23:18.000Z","size":521,"stargazers_count":0,"open_issues_count":1,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-30T12:29:05.040Z","etag":null,"topics":["docker","fastify","nodejs","postgresql","prisma-orm","solid","vitest","zod"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/diego64.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2024-07-22T20:11:59.000Z","updated_at":"2024-08-25T00:23:22.000Z","dependencies_parsed_at":"2024-07-23T01:12:22.130Z","dependency_job_id":"780b9ff7-dfaf-427e-bda4-be78a7904018","html_url":"https://github.com/diego64/api-from-academy","commit_stats":{"total_commits":85,"total_committers":1,"mean_commits":85.0,"dds":0.0,"last_synced_commit":"5e446c078633f45283cf3293eb9d7f7e90354d5e"},"previous_names":["diego64/api-from-academy"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/diego64/api-from-academy","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diego64%2Fapi-from-academy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diego64%2Fapi-from-academy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diego64%2Fapi-from-academy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diego64%2Fapi-from-academy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/diego64","download_url":"https://codeload.github.com/diego64/api-from-academy/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/diego64%2Fapi-from-academy/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260878282,"owners_count":23075957,"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":["docker","fastify","nodejs","postgresql","prisma-orm","solid","vitest","zod"],"created_at":"2024-09-27T11:22:48.211Z","updated_at":"2026-02-03T15:07:23.208Z","avatar_url":"https://github.com/diego64.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"img.shields.io/badge/node_logo.svg\" width=\"200\" alt=\"Node Logo\" /\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n\t\t\u003cem\u003eDeveloped with the software and tools below.\u003c/em\u003e\n\u003c/p\u003e\n\u003cp align=\"center\"\u003e\n    \u003cimg src=\"img.shields.io/badge/nodejs.svg?style=flat\u0026logo=nodejs\u0026logoColor=white\" alt=\"Node\"\u003e\n\t\t\u003cimg src=\"img.shields.io/badge/fastify.svg?style=flat\u0026logo=fastify\u0026logoColor=white\" alt=\"Fastify\"\u003e\n\t  \u003cimg src=\"img.shields.io/badge/prisma.svg?style=flat\u0026logo=prisma\u0026logoColor=white\" alt=\"Prisma\"\u003e\n    \u003cimg src=\"img.shields.io/badge/zod.svg?style=flat\u0026logo=zod\u0026logoColor=white\" alt=\"Zod\"\u003e\n    \u003cimg src=\"img.shields.io/badge/vitest.svg?style=flat\u0026logo=vitest\u0026logoColor=white\" alt=\"Vitest\"\u003e\n\u003c/p\u003e\n\n## 📍 Overview\n\nThe application aims to be an API that allows the user to schedule their day at the gym and a gym to register its unit. Remembering that you need to have `Node.js` and `docker` installed on your machine.\n\nThe application has the following rules.\n\n### 🔌 RFs (Functional Requirements)\n\n- [x] It must be possible to register;\n- [x] It must be possible to authenticate;\n- [x] It must be possible to obtain the profile of a logged-in user;\n- [x] It must be possible to obtain the number of check-ins performed by the logged-in user;\n- [x] The user must be able to obtain his/her check-in history;\n- [x] The user must be able to search for nearby gyms (up to 10km);\n- [x] The user must be able to search for gyms by name;\n- [x] The user must be able to check-in at a gym;\n- [x] It must be possible to validate a user's check-in;\n- [x] It must be possible to register a gym;\n\n### 📦 RNs (Business Rules) \n\n- [x] The user must not be able to register with a duplicate email;\n- [x] The user cannot check-in twice on the same day; - [x] The user cannot check in if he/she is not close (100m) to the gym;\n- [x] The check-in can only be validated up to 20 minutes after being created;\n- [x] The check-in can only be validated by administrators;\n- [x] The gym can only be registered by administrators;\n\n### 🧩 NFRs (Non-functional Requirements)\n\n- [x] The user's password must be encrypted;\n- [x] The application data must be persisted in a PostgreSQL database;\n- [x] All data lists must be paginated with 20 items per page;\n- [x] The user must be identified by a JWT (JSON Web Token);\n\n---\n\n## 🗂️ Repository Structure\n\n```sh\n└── api-from-academy\n    ├── .img.shields.io\n    ├── prisma\n    ├── src\n    ├── .env.example\n    ├── .eslintignore\n    ├── .eslintrc.json\n    ├── docker-compose.yml\n    ├── LICENSE\n```\n\n---\n\n### ⚙️ Installation\n\n\u003ch4\u003eFrom \u003ccode\u003esource\u003c/code\u003e\u003c/h4\u003e\n\n\u003e 1. Clone the repository:\n\u003e\n\u003e ```console\n\u003e $ git clone https://github.com/diego64/api-from-academy\n\u003e ```\n\u003e\n\u003e 2. Change to the project directory:\n\u003e ```console\n\u003e $ cd api-from-academy\n\u003e ```\n\u003e\n\u003e 3. Install the dependencies:\n\u003e ```console\n\u003e $ npm install\n\u003e ```\n\u003e 4. Install the database:\n\u003e ```console\n\u003e $ docker compose up -d\n\u003e ```\n\u003e 5. Generate the migrantios:\n\u003e ```console\n\u003e $ npx prisma migrate dev\n\u003e ```\n\u003e 6. Start the application:\n\u003e ```console\n\u003e $ npm run start:dev\n\u003e ```\n\n### 🧪 Tests\n\n\u003e Run the functional tests using the command below:\n\u003e ```console\n\u003e $ npm run test\n\u003e ```\n\u003e Run E2E tests using the command below:\n\u003e ```console\n\u003e $ npm run test:e2e\n\u003e ```\n\n---\n\n## 📄 License\n\nThis project is protected by the MIT License.\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdiego64%2Fapi-from-academy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdiego64%2Fapi-from-academy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdiego64%2Fapi-from-academy/lists"}