Skip to content

anusha267/bookenzy-backend

Repository files navigation

bookenzy

bookenzy is a Node.js application for user authentication and management using JWT (JSON Web Tokens). Built with TypeScript and Express, it allows users to securely register and log in.

Features

  • User registration with unique email and username
  • JWT-based authentication
  • Password hashing with bcrypt

Tech Stack

  • Node.js
  • Express
  • TypeScript
  • PostgreSQL
  • JWT
  • bcrypt
  • dotenv

Getting Started

Prerequisites

  • Node.js (v14 or higher)
  • PostgreSQL (v12 or higher)

Installation

  1. Clone the repository:
    git clone https://github.com/yourusername/bookenzy.git
    cd bookenzy
  2. Install dependencies:
Copy code
npm install
  1. Set up a .env file:
BOOKENZY_JWT_SECRET=your_secret_key
DATABASE_URL=your_database_connection_string
  1. Start the server:
npm run dev

API Endpoints

  • POST /v1/register - Register a new user
  • POST /v1/login - Log in a user

Contributing

Contributions are welcome! Please fork the repository and submit a pull request.

License

This project is licensed under the MIT License.