{"id":19378099,"url":"https://github.com/apalm112/fsjs-course-rating-api-express","last_synced_at":"2026-04-12T18:03:30.531Z","repository":{"id":125159255,"uuid":"149678639","full_name":"apalm112/FSJS-Course-Rating-API-Express","owner":"apalm112","description":"A REST API using Express. The API will provide a way for users to review educational courses: users can see a list of courses in a database; add courses to the database; and add reviews for a specific course. This project uses REST API design, Node.js, and Express to create API routes, along with Mongoose and MongoDB for data modeling, validation, and persistence.","archived":false,"fork":false,"pushed_at":"2019-04-25T10:34:43.000Z","size":78,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2025-01-07T05:27:05.674Z","etag":null,"topics":["express","mongodb","mongoose","node-js","rest-api"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/apalm112.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":"2018-09-20T22:37:26.000Z","updated_at":"2019-04-25T10:34:45.000Z","dependencies_parsed_at":null,"dependency_job_id":"9662062a-e827-44b9-9762-c1d64d9f2eb8","html_url":"https://github.com/apalm112/FSJS-Course-Rating-API-Express","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/apalm112%2FFSJS-Course-Rating-API-Express","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/apalm112%2FFSJS-Course-Rating-API-Express/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/apalm112%2FFSJS-Course-Rating-API-Express/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/apalm112%2FFSJS-Course-Rating-API-Express/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/apalm112","download_url":"https://codeload.github.com/apalm112/FSJS-Course-Rating-API-Express/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240511294,"owners_count":19813237,"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":["express","mongodb","mongoose","node-js","rest-api"],"created_at":"2024-11-10T09:04:48.129Z","updated_at":"2026-04-12T18:03:25.482Z","avatar_url":"https://github.com/apalm112.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FSJS Project #11: Course-Rating-API-Express\nThis project uses REST API design, Node.js, and Express to create API routes, along with Mongoose and MongoDB for data modeling, validation, and persistence.  \nThe API will provide a way for users to:\n* add a new user\n* review educational courses: users can see a list of courses in a database;\n* add courses to the database;\n* add reviews for a specific course.\n\n\n## Installation\n\n##### Ensure that you have MongoDB installed on your local machine.\n\n##### Get the REST API Running:\n\n* Clone the repo:\n\n\t`git clone git@github.com:apalm112/FSJS-Course-Rating-API-Express.git`\n\n* `cd` into the project folder \u0026 install dependencies:\n\n\t`$ npm i`\n\n* Run:\n\n\t`$ mongod`\n\n* Load the seed-data by opening a separate terminal tab, `cd` to the `src/database/seed-data` folder \u0026 run the commands:\n\n```\n$ mongoimport --db api --collection users --type=json --jsonArray --file users.json\n\n$ mongoimport --db api --collection reviews --type=json --jsonArray --file reviews.json\n\n$ mongoimport --db api --collection courses --type=json --jsonArray --file courses.json\n```\n\n* To run the API locally, in a new terminal tab enter:\n\n\t`$ npm start` or `nodemon`\n\n* Now you can use Postman to test the API routes, such as `GET localhost:5000/api/courses`.\n\n* POST a new user enter the data in this format:\n\n```JSON\n{\n\t\"fullName\": \t    \"Bob Jones\",\n\t\"emailAddress\":     \"bob@aol.com\",\n\t\"password\": \t    \"password\"\n}\n```\n\n* POST a new review in this format, with valid email \u0026 password in Postmans Basic Auth:\n\n```json\n{\n\t\"rating\":     4,\n\t\"review\":   \"Here is a new review, such wow.\"\n}\n```\n\n* POST a new course\n\n```json\n{\n    \"reviews\": [],\n    \"title\": \"New Course Title\",\n    \"description\": \"Lorem gibson euro-pop narrative Tessier-Ashpool rain realism human RAF assassin carbon sign shanty town sub-orbital ICE Tokyo.\",\n    \"estimatedTime\": \"12 hours\",\n    \"materialsNeeded\": \"A Dungeon Master and lots of other stuff\",\n    \"steps\": [\n        {\n            \"stepNumber\": 1,\n            \"title\": \"D\u0026D Financing with Blockchain\",\n            \"description\": \"Collect gold pieces.\"\n        }\n    ]\n}\n```\n\n* Run the Tests in the console:\n\n`cd` into `test/`\n\n`$ npm test`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fapalm112%2Ffsjs-course-rating-api-express","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fapalm112%2Ffsjs-course-rating-api-express","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fapalm112%2Ffsjs-course-rating-api-express/lists"}