Skip to content

EquipReserve simplifies equipment management, enabling users to reserve and track availability effortlessly, optimizing resource utilization and enhancing user experience.

License

Notifications You must be signed in to change notification settings

Tharuneshwarv/EquipReserve

Repository files navigation

EquipReserve API

EquipReserve is a reservation system API that allows users to manage equipment reservations efficiently. This README provides comprehensive information on setting up, running, and using the EquipReserve API.

Table of Contents

Installation

  1. Clone the repository:

    git clone https://github.com/abneribeiro/EquipReserve.git
    cd EquipReserve
  2. Install dependencies:

    npm install
  3. Set up environment variables:

    Create a .env file in the root directory and add the following variables:

    PORT=3000
    MONGODB_URI=mongodb://localhost/equipreserve

    Modify MONGODB_URI based on your MongoDB configuration.

  4. Run the application:

    npm start

Usage

EquipReserve API is accessible at http://localhost:3000 by default. You can use tools like Postman or curl to interact with the API.

Routes

Users

  • Create a new user:

    POST /api/user
  • Get all users:

    GET /api/user
  • Get a user by ID:

    GET /api/user/:userId
  • Update a user:

    PUT /api/user/:userId
  • Delete a user:

    DELETE /api/user/:userId

Equipment

  • Create new equipment:

    POST /api/equipment
  • Get all equipment:

    GET /api/equipment
  • Get equipment by ID:

    GET /api/equipment/:equipmentId
  • Update equipment:

    PUT /api/equipment/:equipmentId
  • Delete equipment:

    DELETE /api/equipment/:equipmentId

Reservations

  • Create a new reservation:

    POST /api/reservation
  • Get all reservations:

    GET /api/reservation
  • Get a reservation by ID:

    GET /api/reservation/:reservationId
  • Update a reservation:

    PUT /api/reservation/:reservationId
  • Delete a reservation:

    DELETE /api/reservation/:reservationId

Testing

To run tests using Jest, use the following command:

npm test

Contributing

  1. Fork the repository.
  2. Create a new branch for your feature or fix: git checkout -b feature-name.
  3. Commit your changes: git commit -m 'Add feature'.
  4. Push to the branch: git push origin feature-name.
  5. Submit a pull request.

License

This project is licensed under the GNU GENERAL PUBLIC LICENSE.

About

EquipReserve simplifies equipment management, enabling users to reserve and track availability effortlessly, optimizing resource utilization and enhancing user experience.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published