Commit Graph

5 Commits

Author SHA1 Message Date
90aebbde3d feat: agregar página de debug para Metabase
All checks were successful
build-and-deploy / build (push) Successful in 41s
build-and-deploy / deploy (push) Successful in 3s
- Crear componente MetabaseCardDisplay para mostrar detalles de queries
- Crear componente MetabaseCardsTable para listar todas las queries
- Crear página /metabase-debug con vistas de tabla, cards y queries Panorama
- Agregar API routes para cards de Metabase (GET, POST, export)
- Actualizar metabase.ts para soportar API Key authentication
- Agregar configuración de Metabase API Key en nuxt.config.ts
- Documentar todos los endpoints disponibles en METABASE_API_ENDPOINTS.md
2025-10-14 01:34:56 -06:00
42c1e20ee3 fix: use Docker container name for Metabase internal communication
All checks were successful
build-and-deploy / build (push) Successful in 44s
build-and-deploy / deploy (push) Successful in 4s
Change Metabase URL from public domain to Docker container name
for proper internal network communication between containers.

Changes:
- Update default METABASE_URL to http://metabase:3000
- Docker DNS resolution works correctly with container names
- Maintains public domain fallback via environment variables

This fixes authentication issues when containers communicate
within the same Docker network.
2025-10-13 17:52:52 -06:00
244b1ae7fb fix: move Metabase credentials to runtime config
All checks were successful
build-and-deploy / build (push) Successful in 43s
build-and-deploy / deploy (push) Successful in 4s
Move hardcoded Metabase credentials to Nuxt runtime config to
allow configuration via environment variables and follow security
best practices.

Changes:
- Update server/utils/metabase.ts to use useRuntimeConfig()
- Add metabase config to nuxt.config.ts runtimeConfig
- Update .env.example with Metabase configuration template

Environment variables:
- METABASE_URL (default: https://metabase.nucleoriofrio.com)
- METABASE_EMAIL (required for authentication)
- METABASE_PASSWORD (required for authentication)
2025-10-13 17:50:21 -06:00
4b25a70b8b feat: add Metabase API integration
All checks were successful
build-and-deploy / build (push) Successful in 45s
build-and-deploy / deploy (push) Successful in 3s
Add complete integration with Metabase API to fetch data from
'facturador supabase' database.

Features:
- Server-side Metabase authentication using session tokens
- Utility functions for Metabase API requests with auto-retry
- API endpoints to proxy Metabase requests
  - GET /api/metabase/databases - List all databases
  - GET /api/metabase/tables/:databaseId - Get tables and metadata
  - POST /api/metabase/query - Execute queries against tables
- useMetabase() composable for frontend consumption
  - getDatabases() - Fetch available databases
  - getDatabaseMetadata() - Get tables and fields info
  - queryTable() - Execute queries with filters and limits
  - resultToObjects() - Helper to convert results to objects

Session tokens are cached and auto-refreshed when expired.
This enables the application to display real data from the
facturador database without using embeds or iframes.
2025-10-13 17:46:48 -06:00
47f4a20bd3 Initial Nuxt data explorer setup 2025-09-29 14:10:11 -06:00