Giter VIP home page Giter VIP logo

origin-backend-take-home-assignment's Introduction

Insurance Quote API

This project was made as a response to Origin's backend challenge.

Instalation

To run this project locally, you need to have installed Vagrant and VirtualBox.

Additionaly, you must git clone this repository to your machine, if you want to make any changes to the code.

Usage

Running the project

To run this project locally, in a Vagrant container, navigate to the folder that contains the project through your Terminal and call vagrant up. This should run the project's virtual-machine. To open the shell on it, run vagrant ssh.

Once the shell is open, navigate to the /vagrant folder and use the command source venv3.8/bin/activate if you want to activate the virtual environment. Note that if you don't do that and try to make changes on the code, you might get dependency and python version conflicts or other errors.

To install all dependencies on the virtual environment, run pip3 install -r requirements.txt.

Running tests

Once inside the image's shell, run python manage.py test.

Django commands

Just some useful Django commands for anyone working on this project:

Create new Django app

python manage.py startapp your_app_name

Start Django development server (local)

python manage.py runserver 0.0.0.0:8000

Create database migrations file

python manage.py makemigrations

Run migrations

python manage.py migrate

Support

If any doubts/bugs/existential angst come from using this project, please contact me (Pat).

Contributing

If you feel like contributing to this project, just open a PR, tag me and I will review and integrate any relevant changes.

Thanks! (:

Authors

Currently, the only person who worked on this project is me (Pat).

Strategy and technical decisions

I was planning to write about all the technical decisions I made along the project here, but due to lack of time, I am leaving this as a technical debt too. If you have any questions about this topic or about the code, please ask me directly and I will gladly answer.

Technical debt

  • Adapt models' structures to Django's format
  • Include validation in the serializers to not accept the request if the car and home fields are not in the request;
  • Add more tests
  • Add token authentication
  • Take credentials off the settings file
  • Add data persistence (DB logic)
  • Write strategy and technical decisions

origin-backend-take-home-assignment's People

Contributors

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