Giter VIP home page Giter VIP logo

hotelscapeapi's Introduction

HotelScape

Overview

HotelScape is created for hotel administrators and receptionists who want to effectively manage the typical hotel workflow.
Full documentation is available here: https://tyaroshko.github.io/hotel-api/

Database Design

Database Design

Software Requirements

  • Python3
  • PostgreSQL and GUI tool for viewing the databases
    (pgAdmin4, OmniDB, DBeaver or any other of your choice)
  • Browser (preferably Google Chrome)
  • IDE (preferably VS Code or JetBrains PyCharm) or text editor to play around with the code

Create a virtual environment

python3 -m venv venv
source venv/bin/activate

Install Poetry and necessary dependencies

pip install poetry
poetry install

Connect PostgreSQL via .env file

Create a .env file with all your environment variables.
It should look like this:

POSTGRES_USER = "user"
POSTGRES_PASSWORD = "password"
POSTGRES_SERVER = "localhost"
POSTGRES_DATABASE = "database"
POSTGRES_TEST_DATABASE = "test-database"
ALGORITHM = "algorithm"
JWT_SECRET_KEY = "jwt_secret_key"
JWT_REFRESH_SECRET_KEY = "jwt_refresh_secret_key"

Create migrations via Alembic

alembic revision --autogenerate     # To create a new revision
alembic upgrade head                # To upgrade your db
alembic downgrade head              # You can always downgrade in case something goes wrong

Test the API via Swagger UI

Run the API using Uvicorn:

uvicorn main:app --reload

and head to http://127.0.0.1:8000/docs

hotelscapeapi's People

Contributors

tyaroshko avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.