Early version for manipulate Geo localization data trough API REST.

Overview

Backend para obtener los datos (beta)

Descripción

El servidor está diseñado para recibir y almacenar datos enviados en forma de JSON por una aplicación de Android que se ejecutará continuamente en segundo plano, como un servicio.

El JSON tiene el siguiente formato:

{
  "imei": "35xxxxxxxxx",  // IMEI estándar de 11 dígitos
  "latitude": "xx.xxxxx", // Latitud del dispositivo en formato decimal
  "longitude": "xx.xxxxx" // Longitud geográfica del dispositivo en formato decimal
}

Instalación

  • Clonar este repositorio
git clone https://github.com/victorovento/gpstracker-upr-beta.git
  • Instalar las dependencias
pip install -r requirements.txt

Recomiendo usar virtualenv: --> https://docs.python.org/3/library/venv.html

Instrucciones

Escribir en la consola:

python app.py

Debería devolver lo siguiente:

 * Serving Flask app 'app.py' (lazy loading)
 * Environment: development
 * Debug mode: off
   2021-11-12 14:52:40,321 INFO sqlalchemy.engine.Engine SELECT * FROM location WHERE location.imei = '111111111111'
   2021-11-12 14:52:40,322 INFO sqlalchemy.engine.Engine [raw sql] ()
 * Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)

Configuraciones del servidor

Puedes ajustar los parámetros del servidor a tu gusto cambiando el valor de algunas variables de entorno:

  • En db_conection.py
DB_PATH = 'sqlite:///db/location.db' # Ruta de la base de datos SQlite
TABLE_NAME = 'location' # Nombre de la tabla para guardar las ubicaciones
  • En app.py
SERVER_HOST = '127.0.0.1' # IP del servidor
SERVER_PORT = '5000' # Puerto del servidor
DEBUG = False # Trastear tanto es malo

Próximamente

  • Compatibilidad con rutas GPS
  • Agrupar los endpoints de la API en resources
  • ... etc

Documentación en construcción...

Owner
Víctor Omar Vento Hernández
Backend Software Engineer
Víctor Omar Vento Hernández
Run functions in parallel easily, with their results typed correctly!

typesafe_parmap pip install pip install typesafe-parmap Run functions in parallel safely with typesafe parmap! GitHub: https://github.com/thejaminato

James Chua 3 Nov 06, 2021
🦩 A Python tool to create comment-free Jupyter notebooks.

Pelikan Pelikan lets you convert notebooks to comment-free notebooks. In other words, It removes Python block and inline comments from source cells in

Hakan Özler 7 Nov 20, 2021
Quickly edit your slack posts.

Lightning Edit Quickly edit your Slack posts. Heavily inspired by @KhushrajRathod's LightningDelete. Usage: Note: Before anything, be sure to head ove

14 Nov 19, 2021
This script allows you to retrieve all functions / variables names of a Python code, and the variables values.

Memory Extractor This script allows you to retrieve all functions / variables names of a Python code, and the variables values. How to use it ? The si

Venax 2 Dec 26, 2021
A python program to find binary, octal and hexadecimal of a decimal.

decimal-converter This little python program can convert a decimal in to, Binary Octal Hexadecimal Needed Python 3 or later or a online python compile

Chandula Janith 0 Nov 27, 2021
Color box that provides various colors‘ rgb decimal code.

colorbox Color box that provides various colors‘ rgb decimal code

1 Dec 07, 2021
Group imports from Windows binaries

importsort This is a tool that I use to group imports from Windows binaries. Sometimes, you have a gigantic folder full of executables, and you want t

【☆ ゆう ☆ 】 15 Aug 27, 2022
A tool written in python to generate basic repo files from github

A tool written in python to generate basic repo files from github

Riley 7 Dec 02, 2021
This is a package that allows you to create a key-value vault for storing variables in a global context

This is a package that allows you to create a key-value vault for storing variables in a global context. It allows you to set up a keyring with pre-defined constants which act as keys for the vault.

Data Ductus 2 Dec 14, 2022
python package for generating typescript grpc-web stubs from protobuf files.

grpc-web-proto-compile NOTE: This package has been superseded by romnn/proto-compile, which provides the same functionality but offers a lot more flex

Roman Dahm 0 Sep 05, 2021
Automatic generator of readmes for git repositories (Includes file' listing)

Readme Generator We are bored of write the same things once and once again. We trust in the comments made inside of our files, and we decided to autom

Natalia Vera Duran 6 Jul 20, 2021
🔩 Like builtins, but boltons. 250+ constructs, recipes, and snippets which extend (and rely on nothing but) the Python standard library. Nothing like Michael Bolton.

Boltons boltons should be builtins. Boltons is a set of over 230 BSD-licensed, pure-Python utilities in the same spirit as — and yet conspicuously mis

Mahmoud Hashemi 6k Jan 04, 2023
Networkx with neo4j back-end

Dump networkx graph into nodes/relations TSV from neo4jnx.tsv import graph_to_tsv g = pklload('indranet_dir_graph.pkl') graph_to_tsv(g, 'docker/nodes.

Benjamin M. Gyori 1 Oct 27, 2021
✨ Un générateur de lien raccourcis en fonction d'un lien totalement fait en Python par moi, et en français.

Shorter Link ❗ Un générateur de lien raccourcis en fonction d'un lien totalement fait en Python par moi, et en français. Dépendences : pip install pys

MrGabin 3 Jun 06, 2021
A dictionary that can be flattened and re-inflated

deflatable-dict A dictionary that can be flattened and re-inflated. Particularly useful if you're interacting with yaml, for example. Installation wit

Lucas Sargent 2 Oct 18, 2021
A simple dork generator written in python that outputs dorks with the domain extensions you enter

Dork Gen A simple dork generator written in python that outputs dorks with the domain extensions you enter in a ".txt file". Usage The code is pretty

Z3NToX 4 Oct 30, 2022
Software to help automate collecting crowdsourced annotations using Mechanical Turk.

Video Crowdsourcing Software to help automate collecting crowdsourced annotations using Mechanical Turk. The goal of this project is to enable crowdso

Mike Peven 1 Oct 25, 2021
jfc is an utility to make reviewing ArXiv papers for your Journal Club easier.

jfc is an utility to make reviewing ArXiv papers for your Journal Club easier.

Miguel M. 3 Dec 20, 2021
Python utilities for writing cross-version compatible libraries

Python utilities for writing cross-version compatible libraries

Tyler M. Kontra 85 Jun 29, 2022
A simple tool that updates your pubspec.yaml file, of a Flutter project, without altering the structure of your file.

A simple tool that updates your pubspec.yaml file, of a Flutter project, without altering the structure of your file.

3 Dec 10, 2021