Welcome! This is a Library Management API, designed to make managing books and users in a library super easy. Whether you’re a librarian wanting to organize the catalog or a user looking to borrow books, this project has got you covered.
Here’s what this API brings to the table:
-
User Authentication: Register and login securely using JWT tokens.
-
Role-Based Access: Users and librarians have different permissions.
-
Manage Books: Librarians can add, update, or delete books.
-
Browse & Borrow: Users can view available books and borrow them.
-
Security: Passwords are hashed using bcryptjs for safety.
-
Basically, it’s a backend that ensures every action—adding a book, borrowing a book, logging in—is handled safely, efficiently, and logically.
- Backend: Node.js + Express.js
- Language: TypeScript (compiled to JavaScript)
- Database: PostgreSQL with Prisma ORM
- Authentication: JWT + bcryptjs
- Cloud: AWS Elastic Beanstalk
- Tools: Nodemon, dotenv, Prisma CLI
The Library Management API is a backend system built to bring order, speed, and a touch of sanity to digital library operations. It manages everything — user accounts, authentication, book records, borrowing, and returns — all through clean, modular routes.
Powered by TypeScript + Express, and backed by PostgreSQL via Prisma ORM, the project ensures reliability, scalability, and developer happiness.
- Security? Enforced with JWT-based authentication and bcrypt-hashed passwords.
- Structure? Well-organized with route separation and environment-driven configuration.
- Deployment? Tuned for AWS Elastic Beanstalk, complete with Procfile, build pipeline, and environment variables.
Currently, the app is live on AWS and successfully passes health checks — though it’s still battling the legendary 502 Bad Gateway dragon.
- TypeScript + Express: Clean, scalable, and strongly typed architecture.
- Prisma ORM: Smooth database migrations and queries without SQL headaches.
- Secure Authentication: JWT tokens + hashed passwords = safer logins.
- Production-Ready Setup: Configured for AWS Elastic Beanstalk with proper Procfile & port auto-handling.
- Health Routes: Simple uptime check endpoints (
/
and/health
) for easy monitoring. - Cloud-Friendly: Environment-variable-driven setup makes it deployable almost anywhere.