Skip to main content

ETL para extraer, transformar y cargar datos de charts de spotify en S3

Project description

Track Flow / Flujo de Seguimiento

ES / Español 🇪🇸

track-flow es una librería modular en Python diseñada para implementar un pipeline ETL completo, ideal para flujos de trabajo donde se requiere extracción, transformación y carga de datos de forma eficiente y reutilizable.


🚀 Características

  • Extracción desde APIs externas (por ejemplo, Spotify)
  • Transformación de datos en DTOs
  • Almacenamiento en formato Parquet
  • Carga en Amazon S3 u otros destinos
  • Configuración flexible mediante variables de entorno
  • Uso como librería o desde línea de comandos

⚙️ Variables de entorno necesarias

Debes definir un archivo .env en la raíz de tu proyecto con las siguientes variables:

# Claves AWS
AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=

# Bucket de destino
AWS_BUCKET_SONG_NAME=

# Datos a procesar
TRACK_LIST=2U3UUpx6ocHXgvcXmq0YBw  # ID de playlist o track de Spotify

#CLIENT AND CLIENT SECRET SPOTIFY 

CLIENT_ID_SPOTIFY= 
CLIENT_SECRET_SPOTIFY=

# Directorio de salida local
ETL_OUTPUT_DIR=output

📦 Instalación

pip install track-flow

💻 Uso básico

Como script:

trackflow

Como módulo de Python:

from track_flow.main import main

main()

🧠 Requisitos

  • Python >= 3.9
  • Tener configurado el archivo .env
  • Acceso válido a la API de Spotify y AWS

🪪 Licencia

MIT © Facu Vega
https://github.com/facuvegaingenieer


EN / English 🇬🇧

track-flow is a modular Python library that implements a full ETL pipeline, ideal for workflows requiring robust data extraction, transformation, and loading in a reusable and configurable way.


🚀 Features

  • Extraction from external APIs (e.g., Spotify)
  • Data transformation into DTOs
  • Storage as Parquet files
  • Upload to Amazon S3 or other destinations
  • Environment-based configuration
  • Usable as a library or from the command line

⚙️ Required Environment Variables

You must define a .env file at the root of your project with the following variables:

# AWS credentials
AWS_ACCESS_KEY_ID=
AWS_SECRET_ACCESS_KEY=
AWS_DEFAULT_REGION=

# S3 Bucket
AWS_BUCKET_SONG_NAME=

# Data to extract
TRACK_LIST=2U3UUpx6ocHXgvcXmq0YBw  # Playlist or track ID from Spotify

# Local output directory
ETL_OUTPUT_DIR=output

📦 Installation

pip install track-flow

💻 Basic Usage

As CLI:

trackflow

As a Python module:

from track_flow.main import main

main()

🧠 Requirements

  • Python >= 3.9
  • Valid .env file
  • Access to Spotify and AWS

🪪 License

MIT © Facu Vega
https://github.com/facuvegaingenieer

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

track_flow-0.1.8.tar.gz (8.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

track_flow-0.1.8-py3-none-any.whl (9.2 kB view details)

Uploaded Python 3

File details

Details for the file track_flow-0.1.8.tar.gz.

File metadata

  • Download URL: track_flow-0.1.8.tar.gz
  • Upload date:
  • Size: 8.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for track_flow-0.1.8.tar.gz
Algorithm Hash digest
SHA256 4afc5ded12c39228d71559ea46abc6e485563e6145a6e3c07f8ea3181dd3a944
MD5 7b6f52ed70024d26503cb608a6149864
BLAKE2b-256 05d77b14fe917926a247bcb9f74b57aa669c17d5122894195650037e57738d9b

See more details on using hashes here.

File details

Details for the file track_flow-0.1.8-py3-none-any.whl.

File metadata

  • Download URL: track_flow-0.1.8-py3-none-any.whl
  • Upload date:
  • Size: 9.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for track_flow-0.1.8-py3-none-any.whl
Algorithm Hash digest
SHA256 9be58e19190151479e7480d47d9da536b910d7840c6ecd4f4738fbb4e219610f
MD5 6129a4fb3cafa05771e83962b539d9b0
BLAKE2b-256 c134947eca2a2e79b7c9b2f4c4731e3c0c0ae746005493b0301820c6c030b331

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page