Giter VIP home page Giter VIP logo

flightapp's Introduction

Flight application API

An application that allows users to book flights and pay for the tickets. Documentation

Build Status Coverage Status

Dependancies

Set Up

In order to run the API Application

  1. Clone this repository and create a virtual environment in a terminal shell virtualenv env and Install the dependencies pip install -r requirements.txt You could as well use pipenv. Install pipenv and run pipenv install to install the requirements

  2. Make a copy of .env-example, rename it to .env and replace the details below

        DB_NAME=your-database-name
        DB_USER=your-database-user
        DB_PASSWORD=your-password
        DB_PORT=5432
        DEBUG=True
        ALLOWED_HOSTS=.localhost
        REDIS_URL=your-url-for-redis
        EMAIL_HOST=smtp.gmail.com
        EMAIL_PORT=587
        EMAIL_HOST_USER=your-email-host-username
        EMAIL_HOST_PASSWORD=your-email-host-password
    
    
  3. Run the migrations using the dev settings file: ./manage.py migrate

  4. Run the command source .env and then run the application by running commands ./manage.py runserver

API End points

EndPoint Method Description
/api/auth/signup POST Register a user
/api/auth/signin POST Login a user
/api/v1/flights/ GET Get flights
/api/v1/flight/<flight_id>/ GET Get a specific flight
/api/v1/flight/<flight_id>/book/ POST Book a flight
/api/v1/flight/<flight_id>/payment/ POST Pay for a flight ticket

License

The project is licensed under Apache License.

flightapp's People

Contributors

solnsubuga 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.