Giter Site home page Giter Site logo

back-end's Introduction

Consultify API

Technologies

  • Passport
  • JWT
  • Nodemailer
  • Mongoose
  • Knex
  • Express
  • Bcrypt
  • Cors
  • MongoDB
  • PostgresSQL

We chose these technologies because together we determined that they were the best for each problem we needed to solve.

We use two databases, the main one is that of postgresql and the secondary one is that of mongodb, we did it this way because the info that we keep in the non-relational database, we did not need it to have a relationship with the data that we already had storing in relational database.

ERD

drawSQL-export-2021-07-13_19_56

Endpoints

Users

Get all users

  GET /api/user
Parameter Type Description
Headers: Authorization Bearer {token} Requerido Token del usuario debe enviarse por headers

Get one user by id

  GET /api/user/${id}
Parameter Type Description
Headers: Authorization Bearer ${token} Requerido Token del usuario debe enviarse por headers
id string Requerido. Id del usuario a consultar

Sign up

  POST /api/user
Parameter Type Description
name string Requerido. user's name
phone_number number Requerido. user's phone number
country_id string Requerido. country where the user lives
payment_method_id string Requerido. user's payment method
password string Requerido. user's password
role_id string Requerido. user's role id
email string Requerido. user's email

Update a user

  PUT /api/user
Parameter Type Description
Headers: Authorization Bearer {token} Requerido Token del usuario debe enviarse por headers
name string user's name
phone_number number user's phone number
country_id string country where the user lives
payment_method_id string user's payment method
password string user's password
role_id string user's role id
email string user's email

Login user

  POST /api/user/login
Parameter Type Description
email string Requerido. user's email
password string Requerido. user's password

Metadata

Get all metadata from users

  GET /api/metadata
Parameter Type Description

Send user's metadata

  POST /api/metadata/
Parameter Type Description
language string idioma del usuario
platform string plataforma que usa el usuario
typeConnection string tipo de coneccion del usuario
isMobile boolean indica si el usuario esta desde un celular
clientName string nombre del navegador
clientType string tipo de navegador
clientVersion string version del navegador
deviceBrand string marca del dispositivo
deviceModel string modelo del dispositivo
deviceType string tipo de dispositivo
osName string nombre del sistema operativo
osPlatform string tipo del sistema operativo
osVersion string version de sistema operativo

back-end's People

Contributors

juansacdev avatar rubdevs avatar edanfesi avatar

Stargazers

Denisse Rivas avatar

Forkers

iqrivas

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.