Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/Danielings/Pasantia-Proyecto/llms.txt

Use this file to discover all available pages before exploring further.

The Sistema de Inventario Tecnológico is a full-stack web application built to help organizations track, manage, and audit their hardware assets. Whether you’re registering a fleet of laptops, assigning monitors to specific office floors, or reviewing a complete history of equipment changes, the system provides a centralized, role-controlled platform for every stage of the hardware lifecycle. It is powered by an Express.js backend with Firebase Firestore as the primary database, and a React + Vite frontend styled with Tailwind CSS.

What the System Does

At its core, the system gives your organization a single source of truth for all technology assets. Administrators and operators can register new equipment, assign it to precise physical locations, track individual components within a device, export full inventory reports, and rely on a tamper-evident audit log to see exactly who changed what and when. Key capabilities include:
  • Hardware registration and tracking — create, update, and decommission PCs, laptops, and standalone peripherals
  • Component-level detail — record the specific processor, RAM, storage, and motherboard inside each PC or laptop
  • Hierarchical location assignment — place every asset at an exact physical address within your organization
  • Role-based access control — three distinct user roles govern who can read, write, or administer the system
  • Serial number uniqueness — every asset across every type shares a single, transaction-backed serial index so duplicate serials are structurally impossible
  • Audit log (bitácora) — every create, update, delete, and login event is recorded automatically
  • Export to PDF or Excel — generate formatted inventory reports on demand

Asset Types

The system manages two primary equipment categories and a collection of standalone peripherals.

Computers (equipos)

Both computers types support sub-component tracking, so the internal hardware of each machine is documented alongside the device itself.
TypeCanonical NameTracked Components
DesktopPCProcesador, Memoria_RAM, Disco_Duro, Motherboard
LaptopLaptopProcesador, Memoria_RAM, Disco_Duro, Motherboard

Peripherals (perifericos)

Standalone peripherals are managed independently and do not have sub-components.
PeripheralCanonical Name
DisplayMonitor
KeyboardTeclado
Pointing deviceMouse
Network switchSwitch
PrinterImpresora
SpeakerCorneta

Location Hierarchy

Every asset is assigned to a location using a six-level hierarchy that mirrors typical organizational structures. Each level refines the physical position of the asset further.
Region
  └── Estado
        └── Ciudad
              └── Sede
                    └── Piso
                          └── Ala
For example, an asset might be located in Región Andina → Táchira → San Cristóbal → Sede Central → Piso 3 → Ala Norte. Locations are managed through dedicated API endpoints and stored in their own Firestore collections (regiones, estados, ciudades, ubicaciones).

User Roles

Access to system features is governed by three roles assigned to each user account. The role is encoded in the JWT issued at login and checked by middleware on every protected route.
RoleSpanish NamePermissions
Super AdministratorSuperadministradorFull access: manage users, assign roles, read/write all assets, view audit log, export reports
AdministratorAdministradorCreate and update assets and locations, view audit log, export reports; cannot manage user accounts or roles
ViewerVisualizadorRead-only access to inventory data and reports; cannot create, update, or delete any record

Serial Number Uniqueness

Serial numbers are the primary way to identify a physical device within the system. To prevent duplicate serials from appearing across different asset categories, the backend maintains a dedicated indices collection in Firestore. Every write that assigns a serial number runs inside a db.runTransaction() block: the transaction reads the index document, confirms the serial is absent, writes the new asset, and updates the index — all atomically. If a duplicate is detected, the entire transaction is aborted and an error is returned to the caller.

Audit Log (Bitácora)

Every significant action in the system — registering equipment, modifying a location, deleting a peripheral, user login — is automatically written to the bitacora collection in Firestore. Each entry captures the acting user, the affected resource, the type of event, and a UTC timestamp. The audit log is readable by Administradores and Superadministradores through the /api/bitacora endpoint and is surfaced in the frontend on the dedicated Bitácora page.

Export Capabilities

The /api/export router supports generating inventory snapshots in two formats:
  • PDF — produced with pdfkit, suitable for printing or archiving
  • Excel (XLSX) — produced with the xlsx library, suitable for further analysis in spreadsheet tools
The Content-Disposition header is exposed by the CORS configuration so browsers can trigger a native file download.

Explore the Docs

Quickstart

Clone the repo, configure environment variables, and make your first API call in under 10 minutes.

Equipment Management

Register and update PCs, laptops, and their internal components.

Peripherals

Manage monitors, keyboards, mice, switches, printers, and speakers.

Locations

Build and navigate the Region → Estado → Ciudad → Sede → Piso → Ala hierarchy.

Roles & Permissions

Understand what each role can and cannot do across every endpoint.

Audit Log

Browse the bitácora to trace every create, update, delete, and login event.

Build docs developers (and LLMs) love