/HandyHub-BackEnd

This application helps homeowners to connect with specialized home service providers. It provides a platform for homeowners to find and hire professionals for various home services.

Primary LanguageRubyMIT LicenseMIT


HandyHome Hub App Back-end (API)

๐Ÿ“— Table of Contents

โš™๏ธ "HandyHome Hub" Backend

**HandyHome Hub Back-End" is a Ruby on Rails application that serves as a RESTful API. It utilizes PostgreSQL as its database. This API serves as the server-side component for booking appointments with home service providers, making it easy for users to schedule services such as house cleaning, plumbing, or any other home-related tasks.

๐Ÿ–ฅ๏ธIntegration with Front-End

This back-end project is designed to seamlessly integrate with its counterpart front-end project ๐Ÿ‘‰๐ŸฝAppointment-capstone-frontend. The front-end, built with React.js and Redux, consumes the API provided by this back-end to provide a user-friendly interface for booking appointments.

๐Ÿ›  Built With

Tech Stack

Ruby
Rails
RSpec
PostgreSQL
Swagger

Key Features

  • User authentication: Users can log in to the website using their username.
  • User authorization: Users can only access their own appointments.
  • Viewing home services: Users can see a list of available home services with details.
  • Appointment booking: Users can book appointments with service providers.
  • Services management: Service providers ("admin" users) can create, edit, and delete services.

(back to top)

๐Ÿš€ Live Demo

  • Enjoy the live version of the API with its front-end counterpart here

(back to top)

๐Ÿ’ป Getting Started

Prerequisites

In order to run this project you need the following installed locally:

 gem install ruby
 gem install rails
  • Linux:
  sudo sh -c 'echo "deb http://apt.postgresql.org/pub/repos/apt $(lsb_release -cs)-pgdg main" > /etc/apt/sources.list.d/pgdg.list'
  wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -
  sudo apt-get update
  sudo apt-get -y install postgresql

Setup

  1. Clone the repository:
  git clone https://github.com/lincoln1883/Appointment-capstone-backend.git
  1. Install the dependencies:
  run bundle install

Usage

  1. Create a master key file in the config folder and add the master key to it. This key is used to decrypt the credentials.yml.enc file. You can use the following command to generate the key:
  1. Remove config/master.key and config/credentials.yml.enc if they exist.
  2. Run in the terminal: EDITOR=code rails credentials:edit 
  3. Close the editor that opens.
  4. This command will create a new master.key and credentials.yml.enc
   if they do not exist.
  1. Configure the database.yml file with your database credentials
    development:
        <<: *default
        database: your_database_name
        username: your_username
        password: your_password
        port: 5432
         
    test:
        <<: *default
        database: your_database_name
        username: your_username
        password: your_password
        port: 5432
  1. Set up the database
  rails db:create
  rails db:migrate
  1. Start the server in your favorite terminal:
  rails server
  1. Review the API documentation here: Swagger API Documentation

Tests

You can run tests with the following command:

  rspec
  1. Front End: To install the front-end of this project, please visit the Appointment-capstone-frontend repository and follow the instructions in the README.md file.

(back to top)

๐Ÿ‘ฅ Authors (in alphabetical order)

๐Ÿ‘ค Cosmos Hagan

๐Ÿ‘ค Ibrahim Hossain

๐Ÿ‘ค Jorge Camargo

๐Ÿ‘ค Lincoln Gibson

๐Ÿ‘ค Moyasi Ginko

(back to top)

๐Ÿ“ˆ Kanban Board

The project's kanban board is available here

You can see a screenshoot of the initial state of the board below:

Kanban Board

(back to top)

๐Ÿ”ญ Future Features

  • Add categories to services
  • Add payment processing
  • Add user profiles
  • Add user reviews and ratings

(back to top)

๐Ÿค Contributing

Contributions, issues, and feature requests are welcome!

Feel free to check the issues page.

(back to top)

โญ๏ธ Show your support

  • If you like this project please give it a โญ๏ธ!

(back to top)

๐Ÿ™ Acknowledgments

(back to top)

๐Ÿ“ License

This project is MIT licensed.

(back to top)