{"id":26213514,"url":"https://github.com/logic-fabric/sportsee-api","last_synced_at":"2025-10-08T22:10:08.845Z","repository":{"id":116029051,"uuid":"393613631","full_name":"logic-fabric/sportsee-api","owner":"logic-fabric","description":"Source code supplied by OpenClassrooms to be used in a project of the Front-end Developer path","archived":false,"fork":false,"pushed_at":"2021-08-07T07:39:26.000Z","size":41,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-12T09:39:38.842Z","etag":null,"topics":["openclassrooms-code"],"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/logic-fabric.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-08-07T07:32:40.000Z","updated_at":"2021-09-29T07:06:03.000Z","dependencies_parsed_at":null,"dependency_job_id":"0b30477d-04fe-4404-95d7-d3e844e945ad","html_url":"https://github.com/logic-fabric/sportsee-api","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/logic-fabric/sportsee-api","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logic-fabric%2Fsportsee-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logic-fabric%2Fsportsee-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logic-fabric%2Fsportsee-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logic-fabric%2Fsportsee-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/logic-fabric","download_url":"https://codeload.github.com/logic-fabric/sportsee-api/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/logic-fabric%2Fsportsee-api/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279000777,"owners_count":26082851,"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","status":"online","status_checked_at":"2025-10-08T02:00:06.501Z","response_time":56,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["openclassrooms-code"],"created_at":"2025-03-12T09:31:51.316Z","updated_at":"2025-10-08T22:10:08.840Z","avatar_url":"https://github.com/logic-fabric.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Project 9 - Front-end Dashboard\n\nThis repo contains all the source code to run the micro API for the sports analytics dashboard SportSee.\n\n## 1. General information\n\nTo start this project, you are free to use Docker or not. In this documentation, we will see several methods to launch the project easily.\n\n## 2. Project (**without Docker**)\n\n### 2.1 Prerequisites\n\n- [NodeJS (**version 12.18**)](https://nodejs.org/en/)\n- [Yarn](https://yarnpkg.com/)\n\nIf you are working with several versions of NodeJS, we recommend you install [nvm](https://github.com/nvm-sh/nvm). This tool will allow you to easily manage your NodeJS versions.\n\n### 2.2 Launching the project\n\n- Fork the repository\n- Clone it on your computer.\n- The `yarn` command will allow you to install the dependencies.\n- The `yarn dev` command will allow you to run the micro API.\n\n\n## 3. Project (**with Docker**)\n\n### 2.1 Prerequisites\n\n- [Docker Desktop](https://www.docker.com/products/docker-desktop)\n\n### 2.2 Starting the project\n\n- The `docker image build --no-cache -t micro-api .` command will allow you to build your image.\n- The `docker container run --name micro-api -p 3000:3000 -dt micro-api yarn` command will allow you to create your Docker container and run your image on port 3000.\n- The `docker container stop micro-api` command will allow you to stop your micro-api.\n- The `docker container rm micro-api` command will allow you to delete your micro-api container.\n\n### 2.3 Vscode and container remotes\n\nFinally, if you have VsCode, you can easily launch your project in a docker environment.\n\nYou will need the [Remote Development extension](https://marketplace.visualstudio.com/items?itemName=ms-vscode-remote.vscode-remote-extensionpack). Once you have this extension installed, just click on the `Reopen in Container` button.\n\nOnce in the container, run the `yarn dev` command.\n\n## 4. Endpoints\n\n### 4.1 Possible endpoints\n\nThis project includes four endpoints that you will be able to use: \n\n- `http://localhost:3000/user/${userId}` - retrieves information from a user. This first endpoint includes the user id, user information (first name, last name and age), the current day's score (todayScore) and key data (calorie, macronutrient, etc.).\n- `http://localhost:3000/user/${userId}/activity` - retrieves a user's activity day by day with kilograms and calories.\n- `http://localhost:3000/user/${userId}/average-sessions` - retrieves the average sessions of a user per day. The week starts on Monday.\n- `http://localhost:3000/user/${userId}/performance` - retrieves a user's performance (energy, endurance, etc.).\n\n\n**Warning, currently only two users have been mocked. They have userId 12 and 18 respectively.**\n\n### 4.2 Examples of queries\n\n- `http://localhost:3000/user/12/performance` - Retrieves the performance of the user with id 12\n- `http://localhost:3000/user/18` - Retrieves user 18's main information.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flogic-fabric%2Fsportsee-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flogic-fabric%2Fsportsee-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flogic-fabric%2Fsportsee-api/lists"}