{"id":15818806,"url":"https://github.com/fmalcher/nobodysperfect-backend","last_synced_at":"2025-04-01T05:14:22.229Z","repository":{"id":77295951,"uuid":"252865252","full_name":"fmalcher/nobodysperfect-backend","owner":"fmalcher","description":null,"archived":false,"fork":false,"pushed_at":"2020-05-06T19:39:12.000Z","size":10,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-10-06T06:20:14.142Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/fmalcher.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":"2020-04-03T23:32:42.000Z","updated_at":"2020-05-06T19:39:15.000Z","dependencies_parsed_at":null,"dependency_job_id":"89f7d874-8139-45c5-b5e9-e134b0a458cc","html_url":"https://github.com/fmalcher/nobodysperfect-backend","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fmalcher%2Fnobodysperfect-backend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fmalcher%2Fnobodysperfect-backend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fmalcher%2Fnobodysperfect-backend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/fmalcher%2Fnobodysperfect-backend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/fmalcher","download_url":"https://codeload.github.com/fmalcher/nobodysperfect-backend/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246586036,"owners_count":20801028,"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":[],"created_at":"2024-10-05T06:20:18.819Z","updated_at":"2025-04-01T05:14:22.207Z","avatar_url":"https://github.com/fmalcher.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Nobody Is Perfect Backend Server\n\nBackend server for the board game [\"Nobody is perfect\"](https://www.ravensburger.de/produkte/spiele/erwachsenenspiele/nobody-is-perfect-27225/index.html) to make it virtually playable via video conference.\nBe aware that this is a rather hacky solution that's supposed to \"just work\" and nothing more.\n\n## Installation and run\n\n* Clone this repo.\n* Install and run an instance of the [frontend application](https://github.com/fmalcher/nobodysperfect-frontend).\n\n```\nnpm i\nnpm start\n```\n\nThe server will start on the port configured in the `PORT` env var or 3000.\n\n\n## Architecture and Game State\n\nsee the [README file of the frontend application](https://github.com/fmalcher/nobodysperfect-frontend/blob/master/README.md)\n\n\n\n## Endpoints\n\nThis server offers a bunch of HTTP endpoints to send POST requests to.\nAll those change data in the `data.json` file.\nThis JSON file can be polled by the frontend to retrieve the latest data.\nFor the types used in the description, see the frontend code.\n\n| Endpoint  | Description | Body Data |\n|---|---|---|\n| `/setquestion` | Moderator submits the question | `{ question: string }` |\n| `/setanswer` | Players and moderator submit their answer. Identification is done via the `name` property. | `{ answer: GameAnswer }` |\n| `/setanswers` | Moderator overrides all answers. Used for editing the submitted answers. | `{ answers: GameAnswer[] }` |\n| `/setstate` | Moderator sets the game state, i.e. the phase the game is in. This is used by the frontend to determine what to show to the player. | `{ state: number }` |\n| `/reset` | Reset the game and set to state `0` |  |\n| `/chooseanswer` | Players choose an answer from the list. `playerName` is the name of the player itself that chooses the answer. `answerName` is the name of the player associated with the chosen answer, as this is the identifier of an answer. | `{ playerName: string, answerName: string }` |","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffmalcher%2Fnobodysperfect-backend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffmalcher%2Fnobodysperfect-backend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffmalcher%2Fnobodysperfect-backend/lists"}