{"id":14956695,"url":"https://github.com/saddamarbaa/node-express-mongodb-typescript-ecom-social-rest-api","last_synced_at":"2025-10-24T10:31:04.085Z","repository":{"id":44109915,"uuid":"352636164","full_name":"saddamarbaa/node-express-mongodb-typescript-ecom-social-rest-api","owner":"saddamarbaa","description":"An open-source RESTful API developed using NodeJS, Express, MongoDB and TypeScript that helps you to integrate User Authentication, E-commerce management and Social Media Post Management in your application with Filter, pagination, Sort and Search API","archived":false,"fork":false,"pushed_at":"2023-03-02T08:35:24.000Z","size":21251,"stargazers_count":52,"open_issues_count":3,"forks_count":17,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-01-29T09:44:55.554Z","etag":null,"topics":["cloundinary","expressjs","jest","jwt-authentication","mongodb-database","nodejs","supertest","swagger-ui","typescript"],"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/saddamarbaa.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":"2021-03-29T12:31:36.000Z","updated_at":"2025-01-15T18:28:42.000Z","dependencies_parsed_at":"2024-08-20T16:49:29.949Z","dependency_job_id":null,"html_url":"https://github.com/saddamarbaa/node-express-mongodb-typescript-ecom-social-rest-api","commit_stats":null,"previous_names":["saddamarbaa/node-express-mongodb-typescript-ecom-social-rest-api"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saddamarbaa%2Fnode-express-mongodb-typescript-ecom-social-rest-api","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saddamarbaa%2Fnode-express-mongodb-typescript-ecom-social-rest-api/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saddamarbaa%2Fnode-express-mongodb-typescript-ecom-social-rest-api/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saddamarbaa%2Fnode-express-mongodb-typescript-ecom-social-rest-api/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/saddamarbaa","download_url":"https://codeload.github.com/saddamarbaa/node-express-mongodb-typescript-ecom-social-rest-api/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237950820,"owners_count":19392666,"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":["cloundinary","expressjs","jest","jwt-authentication","mongodb-database","nodejs","supertest","swagger-ui","typescript"],"created_at":"2024-09-24T13:13:21.939Z","updated_at":"2025-10-24T10:30:59.739Z","avatar_url":"https://github.com/saddamarbaa.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Saddam-rest-api\n\nFree Open source REST API built with | Nodejs + Express + Mongodb ⚡️ Made with developer experience first Prettier + VSCode setup.\n\n\u003e - C.R.U.D, Filter, Paginate, Sort and Search API\n\n# Table of contents\n\n- [Author](#Author)\n- [Demo](#Demo)\n- [Technologies](#Technologies)\n- [Contributing](#Contributing)\n- [Status](#status)\n- [Features](#Features)\n- [Related Projects](#Related_Projects)\n- [Support](#Support)\n- [Feedback](#Feedback)\n- [Run Locally](#Run_Locally)\n- [API Reference](#API_Reference)\n- [Screenshots](#Screenshots)\n- [Environment Variables](#Environment)\n- [Deployment](#Deployment)\n\n# Author\n\n### \u003ca href=\"https://github.com/saddamarbaa\"\u003e@Saddam Arbaa\u003c/a\u003e\n\n# Technologies\n\n- Node.js\n- Express\n- MongoDB\n- JSON Web Token (JWT)\n- bcryptjs\n- Heroku Hosting\n\n# Demo\n\n### \u003ca href=\"https://saddam-rest-api.herokuapp.com\"\u003eLIVE API Demo\u003c/a\u003e\n\n### \u003ca href=\"https://github.com/saddamarbaa/Ecommerce-website-next.js-typeScript\"\u003eFront-End REPO\u003c/a\u003e\n\n### \u003ca href=\"https://saddam-next-ecommerce.vercel.app/\"\u003eLIVE Webside DEMO \u003c/a\u003e\n\n#### Testing Email: testverstion@gmail.com\n\n#### Testing Password: 12345test\n\n# Features\n\n##### (Users)\n\n- Complete user authentication\n- Users can sign in\n- Users can sign out\n- Users can verify email\n- Users can Change Password\n- View all products\n- View products detail\n- Filter products by category\n- Search for products\n- Add products to their basket\n- Checkout total payment\n- Checkout order page\n- Products pagination\n\n##### (Admin)\n\n- Complete Admin Authorization\n- Add products\n- Update products\n- Delete products\n- Limit Products\n- Add Users\n- Update Users\n- Delete Users\n- Update User Role\n\n# API_Reference\n\n#### Get all products\n\n```http\n  GET https://saddam-rest-api.herokuapp.com/api/v1/products\n```\n\n| Parameter  | Type     | Description           |\n| :--------- | :------- | :-------------------- |\n| `limit`    | `number` | default= 100          |\n| `category` | `string` | default= All Products |\n| `page`     | `number` | default= 1            |\n| `search`   | `string` | search string         |\n| `sortBy`   | `string` | default= createdAt    |\n| `OrderBy`  | `string` | default= desc         |\n\n#### example (Paginate - Sort - Filter - Full-text search\n\n```http\n  GET https://saddam-rest-api.herokuapp.com/api/v1/products?page=1\u0026limit=99\u0026sortBy=createdAt\u0026OrderBy=desc\u0026filterBy=category\u0026category=Sports\n  GET   https://saddam-rest-api.herokuapp.com/api/v1/products?page=2\u0026limit=99\u0026sortBy=createdAt\u0026OrderBy=desc\u0026filterBy=category\u0026category=Jewelery\n  GET   https://saddam-rest-api.herokuapp.com/api/v1/products?page=2\u0026limit=99\u0026sortBy=createdAt\u0026OrderBy=desc\u0026filterBy=category\u0026category=Books\u0026search=nodejs\n```\n\n#### Get single product\n\n```http\n  GET https://saddam-rest-api.herokuapp.com/api/v1/products/${id}\n```\n\n| Parameter | Type     | Description                          |\n| :-------- | :------- | :----------------------------------- |\n| `id`      | `string` | **Required**. Id of product to fetch |\n\n#### Add new product (Only admins)\n\n```http\n  POST https://saddam-rest-api.herokuapp.com/api/v1/admin/products\n```\n\n| Parameter      | Type     | Description                                           |\n| :------------- | :------- | :---------------------------------------------------- |\n| `name`         | `string` | **Required**. product name                            |\n| `price`        | `number` | **Required**. product price                           |\n| `description`  | `string` | **Required**. product description                     |\n| `productImage` | `img`    | **Required**. product Image                           |\n| `category`     | `string` | **Required**. product category                        |\n| `count`        | `number` | **Optional**. default value = 1                       |\n| `stock       ` | `string` | **Optional**. default value = 'in stock - order soon' |\n\n#### Update product (Only admins)\n\n```http\n  PATCH https://saddam-rest-api.herokuapp.com/api/v1/admin/products/${id}\n```\n\n| Parameter | Type     | Description                             |\n| :-------- | :------- | :-------------------------------------- |\n| `id`      | `string` | **Required**. Id of product to update   |\n| `token`   | `string` | **Required**. JWT token pass in headers |\n\n#### Delete product (Only admins)\n\n```http\n  DELETE https://saddam-rest-api.herokuapp.com/api/v1/admin/products/${id}\n```\n\n| Parameter | Type     | Description                             |\n| :-------- | :------- | :-------------------------------------- |\n| `id`      | `string` | **Required**. Id of product to delete   |\n| `token`   | `string` | **Required**. JWT token pass in headers |\n\n#### User signup\n\n```http\n  POST https://saddam-rest-api.herokuapp.com/api/v1/auth/signup\n```\n\n| Parameter         | Type      | Description   |\n| :---------------- | :-------- | :------------ |\n| `firstName`       | `string`  | **Required**. |\n| `lastName`        | `string`  | **Required**. |\n| `familyName`      | `string`  | **Optional**. |\n| `email`           | `string`  | **Required**. |\n| `password`        | `string`  | **Required**. |\n| `confirmPassword` | `string`  | **Required**. |\n| `gender`          | `string`  | **Optional**. |\n| `dateOfBirth`     | `string`  | **Optional**. |\n| `acceptTerms`     | `boolean` | **Required**. |\n| `mobileNumber`    | `number`  | **Optional**. |\n| `nationality`     | `string`  | **Optional**. |\n| `favoriteAnimal`  | `string`  | **Optional**. |\n| `address`         | `string`  | **Optional**. |\n| `bio`             | `string`  | **Optional**. |\n| `jobTitle`        | `string`  | **Optional**. |\n\n```http\n  After signup you will receive email to verify your account\n```\n\n#### User Login\n\n```http\n  POST https://saddam-rest-api.herokuapp.com/api/v1/auth/login\n```\n\n| Parameter  | Type     | Description   |\n| :--------- | :------- | :------------ |\n| `email`    | `string` | **Required**. |\n| `password` | `string` | **Required**. |\n\n#### User Verify Email\n\n```http\n  POST https://saddam-rest-api.herokuapp.com/api/v1/auth/verify-email`,\n```\n\n| Parameter | Type     | Description   |\n| :-------- | :------- | :------------ |\n| `userId`  | `string` | **Required**. |\n| `token`   | `string` | **Required**. |\n\n# Environment\n\n- To run this project, you will need to add the following environment variables to your .env file (check environment.config.js file for more examples)\n\n- MONGODB_CONNECTION_STRING\n- TOKEN_SECRET\n- WEBSITE_URL\n- API_VERSION =\"v1\"\n- JWT_EXPIRE_TIME\n- SEND_GRID_API_KEY\n- ADMIN_SEND_GRID_EMAIL\n- ADMIN_ROLE\n- ADMIN_EMAIL\n- NODE_ENV = 'development'\n- CLIENT_URL\n- ACCESS_TOKEN_SECRET_KEY\n- REFRESH_TOKEN_SECRET_KEY\n- ACCESS_TOKEN_KEY_EXPIRE_TIME\n- REFRESH_TOKEN_KEY_EXPIRE_TIME\n\n# Contributing\n\nContributions are always welcome!\n\n# Deployment\n\nTo deploy this project on Heroku Flow the Flowing documentation \u003ca href=\"https://devcenter.heroku.com/articles/deploying-nodejs\"\u003eDeploying Node.js Apps on Heroku\u003c/a\u003e\n\n# Related_Projects\n\n### Blog API built with | Nodejs + Express + Mongodb\n\n#### \u003ca href=\"https://blog-post-api-sadam.herokuapp.com\"\u003eLIVE API\u003c/a\u003e\n\n#### \u003ca href=\"https://github.com/saddamarbaa/blog-api\"\u003eAPI REPO\u003c/a\u003e\n\n#### \u003ca href=\"https://github.com/saddamarbaa/blog-post-front-end-vanillaJS\"\u003eFront-End REPO\u003c/a\u003e\n\n#### \u003ca href=\"https://saddamarbaa-blog.netlify.app/\"\u003e LIVE Webside DEMO \u003c/a\u003e\n\n### Twitter API built with | Nodejs + Express + Mongodb\n\n#### \u003ca href=\"https://twitter-clone-app-saddam.herokuapp.com/\"\u003eLIVE API Demo\u003c/a\u003e\n\n#### \u003ca href=\"https://github.com/saddamarbaa/twitter-clone-api\"\u003eAPI REPO\u003c/a\u003e\n\n#### \u003ca href=\"https://github.com/saddamarbaa/twitter-clone-app\"\u003eFront-End REPO\u003c/a\u003e\n\n#### \u003ca href=\"https://twitter-clone-saddam.netlify.app/\"\u003eLIVE Webside DEMO \u003c/a\u003e\n\n### Netflix API built with | Nodejs + Express + Mongodb\n\n#### \u003ca href=\"https://github.com/saddamarbaa/netflix-clone-api\"\u003eAPI REPO\u003c/a\u003e\n\n#### \u003ca href=\"https://nefilx-saddam.herokuapp.com/\"\u003eLIVE API Demo\u003c/a\u003e\n\n# Support\n\nFor support, email saddamarbaas@gmail.com.\n\n# Feedback\n\nIf you have any feedback, please reach out to me at saddamarbaas@gmail.com\n\nTwitter\nhttps://twitter.com/ArbaaSaddam/\n\nLinkedin.\nhttps://www.linkedin.com/in/saddamarbaa/\n\nGithub\nhttps://github.com/saddamarbaa\n\nInstagram\nhttps://www.instagram.com/saddam.dev/\n\nFacebook\nhttps://www.facebook.com/saddam.arbaa\n\n# Run_Locally\n\nClone the project\n\n```bash\nhttps://github.com/saddamarbaa/node-express-rest-api\n```\n\nGo to the project directory\n\n```bash\n  cd node-express-rest-api\n```\n\nInstall dependencies\n\n```bash\nyarn install\n# or\nnpm install\n```\n\nStart the server\n\n```bash\n  node app.js\n  or\n  nodemon app.js\n```\n\n# Status\n\nProject is: in progress I'm working on it in my free time\n\n# Screenshots\n\n## Signup Page\n\n![image](https://user-images.githubusercontent.com/51326421/168418001-ddf09448-6f3a-4d0c-9ce8-1e691666dd13.png)\n\n![image](https://user-images.githubusercontent.com/51326421/168420032-1339ad80-24e0-4f06-bb90-630256ae2973.png)\n\n## LogIn Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417978-8ad90e22-44e0-4961-aa1d-6a3ad8d235d4.png)\n\n![image](https://user-images.githubusercontent.com/51326421/168419975-7eee5c8a-d3cb-4e1f-a50f-0f01f6d85650.png)\n\n## Forgot Password Page\n\n![image](https://user-images.githubusercontent.com/51326421/168418030-7e87c64b-55ed-4c89-a899-0e9434b147bc.png)\n\n![image](https://user-images.githubusercontent.com/51326421/168419992-59d97525-031a-41d7-ba31-53ab1a75c1e6.png)\n\n![image](https://user-images.githubusercontent.com/51326421/168418079-ec2ca89d-2997-4e44-af34-4bbe2a06bf29.png)\n\n## Reset Password email Link\n\n![image](https://user-images.githubusercontent.com/51326421/168418151-aaf3a8d4-03b5-4011-aff2-7b42e53a4425.png)\n\n## Reset Password Page\n\n![image](https://user-images.githubusercontent.com/51326421/168418261-2c4cb6cb-42b6-44b3-8b98-b91da31f2252.png)\n\n![image](https://user-images.githubusercontent.com/51326421/168420074-88a7ff38-e9cc-421c-917f-3070223021fb.png)\n\n## Update Profile Page\n\n![image](https://user-images.githubusercontent.com/51326421/168419955-ca2231ab-457f-4d48-8188-025e2a931d45.png)\n\n## Home Page\n\n![image](https://user-images.githubusercontent.com/51326421/168419207-cf99c8c8-3032-4441-bbc9-2aecb7b6df78.png)\n\n## Home Page (Filter by category(Bookks))\n\n![image](https://user-images.githubusercontent.com/51326421/168419224-aa093745-8923-4c01-95b3-54897b275fde.png)\n\n## Home Page (Filter by category(Sports))\n\n![image](https://user-images.githubusercontent.com/51326421/168419258-dc20e307-92f0-4be6-903d-8312bc6ae6b2.png)\n\n## Home Page (Filter by category(Toys))\n\n![image](https://user-images.githubusercontent.com/51326421/168419286-d0912456-8aac-4d70-8693-a9923fc3af48.png)\n\n## Home Page (Filter by category(Men's clothing))\n\n![image](https://user-images.githubusercontent.com/51326421/168419300-bed584b1-db33-457e-bd91-c24a8e416473.png)\n\n## Home Page (Search Product (Jewelery))\n\n![image](https://user-images.githubusercontent.com/51326421/168419621-b392a53a-cbc4-4173-ac75-1500b68ad356.png)\n\n## Product Detail Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417430-4be9f4e9-2f3c-468d-a587-21ea0e0edafe.png)\n\n## Shopping Cart Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417498-f5ab4afa-e964-43f9-81ac-87ead9c9852d.png)\n\n## Orders Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417573-f9358b57-ba05-4ae9-a613-a034ec5230bc.png)\n\n## Admin Products Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417651-8ea633e1-13c6-4707-8127-69e6e133ff58.png)\n\n## Admin Users Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417796-0140add5-abf7-490a-9aee-094bd86754d3.png)\n\n## Admin Users Table Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417814-c7e859f3-6a79-48df-8560-0bb2de53bfc4.png)\n\n## Admin Add Product Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417851-4396ddbd-d7cb-4d50-bb78-df36b4583c8e.png)\n\n![image](https://user-images.githubusercontent.com/51326421/168419929-81f17f43-dbbd-4d80-b7fb-2d614e88b607.png)\n\n## Admin Update Product Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417887-ff0a9660-4955-474f-a87f-4f0aaeebc2e8.png)\n\n## Admin Add User Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417951-0f454bc3-fb59-42cb-b764-2059135a6043.png)\n\n![image](https://user-images.githubusercontent.com/51326421/168419886-f8be1530-7131-4625-b044-292fbc6ed3c3.png)\n\n## Admin Update User Page\n\n![image](https://user-images.githubusercontent.com/51326421/168417927-567f47b6-748e-4fc1-9ea0-a45d71f5c660.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaddamarbaa%2Fnode-express-mongodb-typescript-ecom-social-rest-api","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaddamarbaa%2Fnode-express-mongodb-typescript-ecom-social-rest-api","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaddamarbaa%2Fnode-express-mongodb-typescript-ecom-social-rest-api/lists"}