{"id":25102941,"url":"https://github.com/khaledsaeed18/express-notes-app-with-typescript-prisma-postgresql","last_synced_at":"2025-04-19T17:53:36.540Z","repository":{"id":270762755,"uuid":"911385510","full_name":"KhaledSaeed18/Express-Notes-App-with-TypeScript-Prisma-PostgreSQL","owner":"KhaledSaeed18","description":"A simple and secure notes app built with Express.js, TypeScript, Prisma ORM, and PostgreSQL. It features JWT-based authentication, bcrypt.js for password hashing, input validation with express-validator, and request rate limiting with express-rate-limit for enhanced security and performance.","archived":false,"fork":false,"pushed_at":"2025-02-03T13:37:46.000Z","size":35,"stargazers_count":4,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-29T11:12:26.782Z","etag":null,"topics":["authentication","backend","bcryptjs","express-rate-limit","express-validator","expressjs","jsonwebtoken","middleware","nodejs","pagination","postgresql-database","prisma-orm","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/KhaledSaeed18.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":"2025-01-02T22:27:03.000Z","updated_at":"2025-02-26T22:23:23.000Z","dependencies_parsed_at":"2025-01-02T23:27:21.697Z","dependency_job_id":"98684ecf-87dd-4e84-b4b7-a91e0b7a8c55","html_url":"https://github.com/KhaledSaeed18/Express-Notes-App-with-TypeScript-Prisma-PostgreSQL","commit_stats":null,"previous_names":["khaledsaeed18/express-notes-app-with-typescript-prisma-postgresql"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KhaledSaeed18%2FExpress-Notes-App-with-TypeScript-Prisma-PostgreSQL","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KhaledSaeed18%2FExpress-Notes-App-with-TypeScript-Prisma-PostgreSQL/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KhaledSaeed18%2FExpress-Notes-App-with-TypeScript-Prisma-PostgreSQL/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/KhaledSaeed18%2FExpress-Notes-App-with-TypeScript-Prisma-PostgreSQL/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/KhaledSaeed18","download_url":"https://codeload.github.com/KhaledSaeed18/Express-Notes-App-with-TypeScript-Prisma-PostgreSQL/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249753243,"owners_count":21320679,"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":["authentication","backend","bcryptjs","express-rate-limit","express-validator","expressjs","jsonwebtoken","middleware","nodejs","pagination","postgresql-database","prisma-orm","typescript"],"created_at":"2025-02-07T21:33:57.112Z","updated_at":"2025-04-19T17:53:36.522Z","avatar_url":"https://github.com/KhaledSaeed18.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Express TypeScript Backend with Prisma\n\n[![Node.js](https://img.shields.io/badge/Node.js-339933?style=for-the-badge\u0026logo=nodedotjs\u0026logoColor=white)](https://nodejs.org/)\n[![TypeScript](https://img.shields.io/badge/TypeScript-007ACC?style=for-the-badge\u0026logo=typescript\u0026logoColor=white)](https://www.typescriptlang.org/)\n[![Express.js](https://img.shields.io/badge/Express.js-000000?style=for-the-badge\u0026logo=express\u0026logoColor=white)](https://expressjs.com/)\n[![Prisma](https://img.shields.io/badge/Prisma-3982CE?style=for-the-badge\u0026logo=Prisma\u0026logoColor=white)](https://www.prisma.io/)\n[![PostgreSQL](https://img.shields.io/badge/PostgreSQL-316192?style=for-the-badge\u0026logo=postgresql\u0026logoColor=white)](https://www.postgresql.org/)\n[![JWT](https://img.shields.io/badge/JWT-000000?style=for-the-badge\u0026logo=JSON%20web%20tokens\u0026logoColor=white)](https://jwt.io/)\n[![bcrypt](https://img.shields.io/badge/bcrypt-003A70?style=for-the-badge\u0026logo=lock\u0026logoColor=white)](https://www.npmjs.com/package/bcryptjs)\n[![Express Validator](https://img.shields.io/badge/Express_Validator-7457C2?style=for-the-badge\u0026logo=validator\u0026logoColor=white)](https://express-validator.github.io/)\n[![Rate Limit](https://img.shields.io/badge/Rate_Limit-2EA44F?style=for-the-badge\u0026logo=shield\u0026logoColor=white)](https://www.npmjs.com/package/express-rate-limit)\n[![CORS](https://img.shields.io/badge/CORS-000000?style=for-the-badge\u0026logo=cors\u0026logoColor=white)](https://www.npmjs.com/package/cors)\n\nA robust REST API backend built with Express.js, TypeScript, and Prisma ORM featuring authentication and note management.\n\n## Features\n\n- 🔐 JWT-based Authentication\n- 📝 CRUD operations for Notes\n- 🔍 Search functionality\n- 📄 Pagination support\n- ⚡ Rate limiting\n- 🔒 Password validation and security\n- 🎯 Input validation\n- 🚫 Error handling middleware\n- 📦 PostgreSQL database with Prisma ORM\n\n## Tech Stack\n\n- Node.js\n- Express.js\n- TypeScript\n- Prisma ORM\n- PostgreSQL\n- JSON Web Tokens\n- bcrypt.js\n- express-validator\n- express-rate-limit\n\n## Installation\n\n1- Clone the repository:\n\n```bash\ngit clone https://github.com/KhaledSaeed18/Express-Notes-App-with-TypeScript-Prisma-PostgreSQL.git\ncd Express-Notes-App-with-TypeScript-Prisma-PostgreSQL\n```\n\n2- Install dependencies:\n\n```bash\nnpm install\n```\n\n3- Create a .env file in the root directory:\n\n```.env\nPORT=\u003cport-number\u003e\nAPI_VERSION=v1\nBASE_URL=/api\nDATABASE_URL=postgresql://\u003cusername\u003e:\u003cpassword\u003e@localhost:5432/\u003cdatabase-name\u003e\nJWT_SECRET=your-jwt-secret-key\nJWT_REFRESH_SECRET=your-jwt-refresh-secret-key\n```\n\n4- Set up the database:\n\n```bash\nnpx prisma migrate dev   # Apply the migrations\n\nnpx prisma generate   # Generate the Prisma Client\n```\n\n5- Run the application:\n\n```bash\nnpm run dev\n```\n\n6- Production Build:\n\n```bash\nnpm run build\nnpm start\n```\n\n## API Endpoints\n\n### Base URL\n\n`http://localhost:3000/api/v1`\n\n- Authentication:\n  - `POST /api/v1/auth/signup` - Register a new user\n  - `POST /api/v1/auth/signin` - Login user\n  - `POST /api/v1/auth/refresh-token` - Refresh access token\n\n- Notes:\n  - `POST /api/v1/note/create-note` - Create a new note\n  - `GET /api/v1/note/get-notes` - Get all notes (paginated)\n  - `GET /api/v1/note/get-note/:id` - Get a specific note\n  - `GET /api/v1/note/search-notes` - Search notes (paginated)\n  - `PUT /api/v1/note/update-note/:id` - Update a note\n  - `DELETE /api/v1/note/delete-note/:id` - Delete a note\n  ","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkhaledsaeed18%2Fexpress-notes-app-with-typescript-prisma-postgresql","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkhaledsaeed18%2Fexpress-notes-app-with-typescript-prisma-postgresql","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkhaledsaeed18%2Fexpress-notes-app-with-typescript-prisma-postgresql/lists"}