Skip to content

mugberto/vacations-booking-back-end

Repository files navigation

Vacations booking back-end

"Vacations booking back-end" project is a Rails API application which provide the API endpoints for creating/removing different destinations by admin users and creating reservations by other logged users. We were using Swagger to create API documentation. You can check it here - API documentation. image

Live demo link

Demo link

Kanban board

Link to Kanban board

Kanban boad setup screenshoot: Kanban-board-screenshot

The final member number of this project is: 5!

Built With

  • Ruby on Rails
  • Postgres
  • Rspec
  • Swagger

Getting Started

To get a local copy up and run the app, follow these simple example steps.

Prerequisites

  • Ruby > 2.7.3
  • Rails > 6.1.4.1
  • Postgres > 14.0

Setup

Clone the repository with:

git clone [email protected]:mugberto/vacations-booking-back-end.git

or download ZIP file

Install

To install all dependencies, run:

bundle install

Create database and seed the data

rails db:create
rails db:migrate
rails db:seed

Usage

To run the server, in the project directory, run:

rails s

Endpoints

If you are using the app localy

{defaultHost} = http://localhost:3000

If you are using deployed app

{defaultHost} = https://booking-vacations.herokuapp.com
  • Create a new user: POST {defaultHost}/api/v1/users
  • Authenticates the user: POST {defaultHost}/api/v1/users/sign_in
  • Creates a new destination: POST {defaultHost}/api/v1/destinations
  • Retreives destinations: GET {defaultHost}/api/v1/destinations
  • Removes destination: DELETE {defaultHost}/api/v1/destinations/{id}
  • Creates a new reservation: POST {defaultHost}/api/v1/reservations
  • Retreives reservations: GET {defaultHost}/api/v1/reservations
  • Removes a reservation: DELETE {defaultHost}/api/v1/reservations/{id}

Tests

To test endpoins please run:

rails rswag

To test the models please run:

rspec --exclude-pattern "spec/{requests}/**/*_spec.rb"

Testing in browser

If you prefere do testings in graphic environment, in your browser open

{defaultHost}/api-docs/index.html

and follow the instructions in the API documentation.

Front-end app

This app should run together with vacations-booking-front-end application. Open the vacations-booking-front-end repo and install it localy to complete the full-stack application.

👤👤 Authors

👤 Aleksandar Ivezic

👤 Vo Thi Quynh Yen

👤 Hubert MUGABO

👤 Igor Koloski

👤 Daniel Maina

🤝 Contributing

Contributions, issues, and feature requests are welcome!

Feel free to check the issues page.

Show your support

Give a ⭐️ if you like this project!

Acknowledgments

📝 License

This project is MIT licensed.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages