How akthamh/iot-management-platform works
This is a local, interactive Python CLI for managing IoT devices and their tenant assignments. The user selects tenant or device operations in the main menu; managers validate input and coordinate catalog selection and repository operations, while repositories persist records in SQLite and expose Tenant and Device objects. Device workflows include registration, listing, search, update, deletion, catalog browsing, and tenant display; tenant workflows include registration, listing, lookup, and search. The README documents migration and foreign-key behavior. Edges reflect the excerpts and README; unsampled implementation details are not inferred.
Main entry points: main.py Menu and routing · device_manager.py Device operations · tenant_repository.py Tenant repository · database.py SQLite setup
Components 11
CLI workflows
- Menu and routing
main.py - Tenant operations
modules/tenant_manager.py - Device operations
modules/device_manager.py
Catalog and models
- Device catalog
modules/device_catalog.py - Tenant model
modules/models/tenant.py - Device model
modules/models/device.py
Persistence
- Tenant repository
modules/tenant_repository.py - Device repository
modules/device_repository.py - SQLite setup
modules/database.py
Other components
- User
- SQLite database
Connections 16
- User → Menu and routing: selects operations
README.md - Menu and routing → SQLite setup: initializes
main.py - Menu and routing → Tenant operations: routes tenant actions
main.py - Menu and routing → Device operations: routes device actions
main.py - Menu and routing → Device catalog: shows catalog
main.py - Tenant operations → Tenant repository: calls tenant queries
modules/tenant_manager.py - Tenant operations → Tenant model: displays objects
modules/tenant_manager.py - Device operations → Device repository: calls device queries
modules/device_manager.py - Device operations → Tenant repository: looks up tenants
modules/device_manager.py - Device operations → Device catalog: selects device type
modules/device_manager.py - Device operations → Device model: creates objects
modules/device_manager.py - Tenant repository → SQLite setup: opens connection
modules/tenant_repository.py - Device repository → SQLite setup: opens connection
modules/device_repository.py - Tenant repository → Tenant model: returns objects
modules/tenant_repository.py - Device repository → Device model: returns objects
modules/device_repository.py - SQLite setup → SQLite database: creates schema and connections
modules/database.py