How kimduarte/kim works
SGP/COLOG is a vehicle-donation asset-management system being migrated from a spreadsheet and Apps Script to a website and TiDB-backed service. The evidenced import workflow sends spreadsheet rows in batches, validates the full import before writing, and then stores the records. The website homepage is explicitly a placeholder; the sampled material does not establish the future management-screen workflow. Apps Script and migration capabilities are represented only where documented; their source was not sampled.
Main entry points: importar/route.ts Import endpoint · db.ts Database connections · setup/route.ts Setup endpoint · EnviarParaOSite.gs Batch sender
Components 11
Spreadsheet import
- Batch sender
apps-script/EnviarParaOSite.gs - Apps Script interface
apps-script/PaginaCompleta.html
Site service
- Import endpoint
site/app/api/importar/route.ts - Column mapping
site/lib/colunas-veiculos.ts - Placeholder homepage
site/app/page.tsx
Database
- Database connections
site/lib/db.ts - Vehicle schema
site/db/01-criar-tabelas.sql
Initial setup
- Setup endpoint
site/app/api/setup/route.ts
Other components
- Spreadsheet operator
- Vehicle spreadsheet
- TiDB Cloud
Connections 10
- Spreadsheet operator → Vehicle spreadsheet: edits
- Vehicle spreadsheet → Batch sender: provides rows
- Batch sender → Import endpoint: sends batches
- Import endpoint → Column mapping: maps and validates
- Import endpoint → Database connections: queries and writes
- Database connections → TiDB Cloud: connects and queries
- Spreadsheet operator → Apps Script interface: uses
- Setup endpoint → Database connections: opens connection
- Setup endpoint → TiDB Cloud: creates and checks schema
- Vehicle schema → TiDB Cloud: defines tables