The Notes App API allows users to perform CRUD (Create, Read, Update, Delete) operations on notes. It also provides functionality for user account management, allowing users to create accounts and manage their notes.
Before you begin, ensure you have the following:
- Node.js and npm installed
- PostgreSql
- Clone the repository:
git clone https://github.com/MohamedAboElnaser/notes-app.git - Install dependencies:
npm install - Configure environment variables: Create a
.envfile .- Copy .env.example content to
.envfile - Add values for environment variables
you can set
DATABASE_URL,TESTING_DBandPRODUCTION_DBby the same connection string value like this format postgresql://USER:PASSWORD@HOST:PORT/DATABASE
- Copy .env.example content to
- Migrate prisma schema to the db by running this command
npm run migrateSchema
- For testing , run this command
npm test - For running app in
Developmentenvironment , run this commandnpm run start
- For running app in
Productionenvironment , run this commandnpm run start:prod
You can see postman documentation from here
The Notes App API leverages the following technologies and tools:
- Node.js: The server-side runtime environment for executing JavaScript code.
- Express.js: A minimal and flexible Node.js web application framework for building robust APIs.
- PostgreSQL: A powerful open-source relational database used for storing user accounts and notes.
- Prisma: A modern database toolkit and ORM for Node.js and TypeScript.
- JWT (JSON Web Tokens): Used for secure user authentication.
- Mailtrap (Development): A service for email testing during development. SMTP credentials can be configured in the
.envfile. - SendinBlue (Production): A cloud-based email marketing platform. Configure production email settings in the
.envfile.
- Jest: A delightful JavaScript testing framework for Node.js applications.
- Supertest: A library for testing HTTP assertions.
- Postman: Used to provide a collection for API exploration.
- Render: A cloud platform for hosting and deploying web applications.
- Git: A distributed version control system.
- GitHub: A web-based platform for version control and collaboration.
If you'd like to contribute to the project or have suggestions for improvement, please do not hesitate to make pull request
