{"id":18309721,"url":"https://github.com/codeuino/social-platform-donut-backend","last_synced_at":"2025-04-05T17:32:59.763Z","repository":{"id":40783983,"uuid":"211138816","full_name":"codeuino/social-platform-donut-backend","owner":"codeuino","description":"Donut API:","archived":false,"fork":false,"pushed_at":"2023-01-24T00:52:03.000Z","size":1751,"stargazers_count":24,"open_issues_count":82,"forks_count":57,"subscribers_count":4,"default_branch":"development","last_synced_at":"2025-03-21T08:34:35.192Z","etag":null,"topics":["expressjs","hacktoberfest","jest","jwt","mongodb","morgan","nodejs"],"latest_commit_sha":null,"homepage":"http://donut-api-prod.codeuino.org/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/codeuino.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"open_collective":"donut"}},"created_at":"2019-09-26T16:53:28.000Z","updated_at":"2024-08-25T02:12:37.000Z","dependencies_parsed_at":"2023-02-13T06:45:53.138Z","dependency_job_id":null,"html_url":"https://github.com/codeuino/social-platform-donut-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/codeuino%2Fsocial-platform-donut-backend","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeuino%2Fsocial-platform-donut-backend/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeuino%2Fsocial-platform-donut-backend/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/codeuino%2Fsocial-platform-donut-backend/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/codeuino","download_url":"https://codeload.github.com/codeuino/social-platform-donut-backend/tar.gz/refs/heads/development","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247375614,"owners_count":20929065,"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":["expressjs","hacktoberfest","jest","jwt","mongodb","morgan","nodejs"],"created_at":"2024-11-05T16:12:17.092Z","updated_at":"2025-04-05T17:32:54.751Z","avatar_url":"https://github.com/codeuino.png","language":"JavaScript","funding_links":["https://opencollective.com/donut"],"categories":[],"sub_categories":[],"readme":"# social-platform-donut-backend\n\n\u003cp align=\"center\"\u003e\n    \u003ca href=\"https://travis-ci.org/codeuino/social-platform-donut-backend\" alt=\"BuildInfo\"\u003e\n        \u003cimg src=\"https://travis-ci.org/codeuino/social-platform-donut-backend.svg?branch=master\" /\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://codecov.io/gh/codeuino/social-platform-donut-backend\"\u003e\n        \u003cimg src=\"https://codecov.io/gh/codeuino/social-platform-donut-backend/branch/master/graph/badge.svg\" /\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://opencollective.com/donut\"\u003e\n        \u003cimg src=\"https://img.shields.io/opencollective/all/donut?logo=Open-Collective\u0026label=financial+contributors\" /\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://github.com/codeuino/social-platform-donut-backend/issues\"\u003e\n        \u003cimg alt=\"GitHub issues\" src=\"https://img.shields.io/github/issues/codeuino/social-platform-donut-backend?style=plastic\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://github.com/codeuino/social-platform-donut-backend/blob/master/LICENSE\"\u003e\n        \u003cimg alt=\"GitHub license\" src=\"https://img.shields.io/github/license/codeuino/social-platform-donut-backend\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://www.codefactor.io/repository/github/devesh-verma/social-platform-donut-backend\"\u003e\n        \u003cimg src=\"https://www.codefactor.io/repository/github/devesh-verma/social-platform-donut-backend/badge\" alt=\"CodeFactor\" /\u003e\n    \u003c/a\u003e\n\u003c/p\u003e\n\n\n## Prerequisite: \n\nThese are the requirement that should be installed locally on your machine.\n\n- Node.js\n- MongoDB\n- Redis\n\n\n## How to setup node.js on your machine?\n\n- Move to: [link](https://nodejs.org/en/download/) choose the operating system as per your machine and start downloading and setup by clicking recommended settings in the installation wizard.\n\n## How to setup MongoDB on your machine?\n\n- Move to: [link](https://docs.mongodb.com/manual/administration/install-community/) look at the left sidebar and choose the operating system according to your machine. Then follow the steps recommended in the official docs.\n\n```\nNote: You can also use the MongoDB servers like Mlab or MongoDB Cluster server\n```\n\n## How to setup redis on your machine?\n\n- Follow the steps provided in the [link](https://auth0.com/blog/introduction-to-redis-install-cli-commands-and-data-types/) to install redis on your operating system\n\n## How to set up this project locally?\n\n- Move to: https://github.com/codeuino/social-platform-donut-backend\n- Fork the repo \n- Clone the repo using: \n```sh\n    git clone https://github.com/codeuino/social-platform-donut-backend.git\n```\n- Now move to the project directory on your machine.\n```\n    cd social-platform-donut-backend\n```\n- Now use ```git checkout development``` to move to the development branch.\n- Install all the dependencies using:\n```sh\nnpm install \n```\n- Run the development server using:\n```sh\nnpm run dev\n```\n- Now the server is running on PORT 5000 or the PORT mentioned in the environment **.env.dev** variables\n\n```\nNote: Setup the environment variables as mentioned below\n```\n\n\n## Run unit test\nUse the given below command to run all the unit test cases.\n```\nnpm run test\n```\n\n\n## What are the environment variables required to run the project locally on a machine?\n- Follow these steps to set the environment variable for development:\n- Move to the root directory of the project and open **.env.dev** (for development) or **.env.test** (for testing)\n- PORT = 5000\n- NODE_ENV = \"development\"\n- JWT_SECRET=\"\u003cYOUR SECRET KEY\u003e\"\n- DATABASE_URL=\"\u003cYOUR DB URL\u003e\"\n- SENDGRID_API_KEY = '\u003cYOUR SENDGRID API KEY\u003e'\n- SOCKET_PORT = 8810\n\nNote: To get **SENDGRID_API_KEY** follow the Sendgrid official [docs](https://sendgrid.com/docs/ui/account-and-settings/api-keys/#creating-an-api-key)\n\n## Workflow (After setup)\n\nMust follow the steps to use the platform:\n1. Create an organization -  [API](https://docs.codeuino.org/donut-social-networking-platform/rest-apis/organization-api#create-an-organization)\n2. Register as an admin - [API](https://docs.codeuino.org/donut-social-networking-platform/rest-apis/post-api#create-a-user)\n3. Now login and use the features implemented - [API](https://docs.codeuino.org/donut-social-networking-platform/rest-apis/post-api#login-user)\n4. To know more about features please go through the docs - [Docs](https://docs.codeuino.org/donut-social-networking-platform/rest-apis/post-api)\n\n```\nNOTE: Please make sure when you setup for the first time your database is empty.\n```\n\n\n## Allowed HTTPs requests:\n\u003cpre\u003e\nPOST    : To create resource \nPATCH   : To Update resource\nGET     : Get a resource or list of resources\nDELETE  : To delete resource\n\u003c/pre\u003e\n\n## Description Of Donut API Server Responses:\n\u003ctable\u003e\t\n    \u003ctr\u003e\n        \u003cth\u003eCode\u003c/th\u003e\t\n        \u003cth\u003eName\u003c/th\u003e\n        \u003cth\u003eDetails\u003c/th\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e200\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eOK\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003ethe request was successful.\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e201\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eCreated\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003ethe request was successful and a resource was created.\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e204\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eNo Content\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003ethe request was successful but there is no representation to return (i.e. the response is empty).\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e400\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eBad Request\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003ethe request could not be understood or was missing required parameters.\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e401\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eUnauthorized\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003eauthentication failed or user doesn't have permissions for requested operation.\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e403\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eForbidden\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003eaccess denied.\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e404\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eNot Found\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003eresource was not found.\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e405\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eMethod Not Allowed\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003erequested method is not supported for resource.\u003c/td\u003e\n    \u003c/tr\u003e\n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e409\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eConflict\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003eresourse with given id already exist.\u003c/td\u003e\n    \u003c/tr\u003e  \n    \u003ctr\u003e\n        \u003ctd\u003e\u003ccode\u003e429\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003e\u003ccode\u003eToo many requests\u003c/code\u003e\u003c/td\u003e\n        \u003ctd\u003esent too many requests to the server in short span of time\u003c/td\u003e\n    \u003c/tr\u003e    \n\u003c/table\u003e\n\u003cbr\u003e\u003c/br\u003e\n\n## Contributing 💻\nWe are happy to see you here and we welcome your contributions towards Donut-Platform.\nContributions are not limited to coding only, you can help in many other ways which includes leaving constructive feedback to people's Pull Request threads also.\n\nDonut platform also provides an extensive list of issues, some of them includes labels like good-first-issue, help-wanted. You can take a look at good-first-issue issues if you are new here but you are free to choose any issue you would like to work on.\n\nIf there's no issue available currently, you can setup the project locally and find out the bugs/new features and open issues for that and discuss the bugs or features with the project maintainers or admins.\n\nAfter choosing an issue and doing changes in the code regarding that, you can open up a Pull Request (PR) to development branch to get your work reviewed and merged!","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodeuino%2Fsocial-platform-donut-backend","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodeuino%2Fsocial-platform-donut-backend","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodeuino%2Fsocial-platform-donut-backend/lists"}