Skip to content

SSleimann/riding-api

Repository files navigation


Riding API

API to manage travels, drivers and vehicles.

Table of Contents
  1. About The Project
  2. Getting Started
  3. Usage
  4. License
  5. Contact

About The Project

RidingAPI is a REST API for a travel system. You can create a user to create travel requests. You can also with your user become a driver and accept travels. The location of the travels is placed using longitude and latitude. You can list the avaliable travels according to where you are and a radius.

(back to top)

Built With

Technologies used in this project are:

  • Python
  • PostgreSQL
  • Django
  • Celery
  • Redis

(back to top)

Getting Started

Prerequisites

Before you start, you'll need to make sure you have the following installed:

  • Docker
  • Docker Compose
  • Git

Installation

  1. Clone the repository and access it.
    git clone https://github.com/SSleimann/riding-api.git
    cd riding-api 
  2. Run the following command to build and run the containers in local:
    docker compose -f local.yml up -d

You can stop the containers by running:

docker compose -f local.yml down

(back to top)

Usage

First, you need to create a user to be able to access the other endpoints. A user is a passenger, a user can become a driver as well.

If you become a driver, in order to take travels you need to have vehicles, otherwise your status will be inactive and you will not able to take travels.

When you take a request travel, a Travel object is created, then when you want to end the travel, the driver and the passenger must confirm the confirmation order, when both have done so the travel is ended.

On the other hand, being a user you can create request travels adding your current location in latitude and longitude, when a travel is taken, you will be notified with an email. In local mode, the email backend is django.core.mail.backends.locmem.EmailBackend.

You can see the endpoints of the application in the path /api/docs/schema/swagger-ui/

(back to top)

License

This project is licensed under the GNU General Public License (GPL) version 3. See the LICENSE file for more details.

(back to top)

Contact

Sleiman Orocua - sleimanjose23@hotmail.com

Project Link: https://github.com/SSleimann/riding-api

(back to top)

Releases

No releases published

Packages

No packages published

Languages