Spycall/ManageAssets
An inventory and asset management system that allows businesses to track, register, monitor, and manage their physical and digital assets across departments and branches, with on-chain transparency via StarkNet for critical events like asset acquisition, transfer, and disposal.
ManageAssets - Unified Inventory and Asset Management System
A comprehensive asset management system with blockchain transparency via StarkNet for critical events like asset acquisition, transfer, and disposal.
Features
- Asset Registration & Management: Complete lifecycle management with QR codes and digital tracking
- Inventory Management: Real-time stock tracking with low inventory alerts
- Multi-Branch Support: Manage assets across multiple locations
- Assignment & Ownership: Track asset assignments to employees and departments
- Maintenance Scheduling: Preventive and corrective maintenance tracking
- Check-in/Check-out System: Temporary asset usage tracking with QR scanning
- Audit Trail & StarkNet Integration: Immutable blockchain records for critical events
- Role-Based Access Control: Fine-grained permissions system
- Comprehensive Reporting: Asset distribution, depreciation, and performance analytics
Tech Stack
- Frontend: Next.js 14 (App Router), TypeScript, TailwindCSS, shadcn/ui
- Backend: NestJS, TypeORM, PostgreSQL
- Blockchain: StarkNet (Cairo 1.0) for on-chain transparency
- Authentication: JWT with role-based access control
- Real-time: WebSockets for notifications
- File Storage: Local storage with cloud integration support
Prerequisites
- Node.js 18+ and npm
- PostgreSQL 14+
- Docker and Docker Compose (optional)
- StarkNet account (for blockchain features)
Quick Start with Docker
-
Clone the repository:
```bash
git clone https://github.com/yourusername/manageassets.git
cd manageassets
``` -
Create environment files:
```bash
cp backend/.env.example backend/.env
cp frontend/.env.example frontend/.env
``` -
Start the application:
```bash
docker-compose up -d
```
The application will be available at:
- Frontend: http://localhost:3000
- Backend API: http://localhost:3001
- API Documentation: http://localhost:3001/api/docs
Manual Setup
Backend Setup
-
Navigate to the backend directory:
```bash
cd backend
``` -
Install dependencies:
```bash
npm install
``` -
Set up the database:
```bash
Create a PostgreSQL database named 'manageassets'
createdb manageassets
```
- Configure environment variables:
```bash
cp .env.example .env
Edit .env with your database credentials and other settings
```
-
Run database migrations:
```bash
npm run migration:run
``` -
Seed the database (optional):
```bash
npm run seed
``` -
Start the development server:
```bash
npm run start:dev
```
Frontend Setup
-
Navigate to the frontend directory:
```bash
cd frontend
``` -
Install dependencies:
```bash
npm install
``` -
Configure environment variables:
```bash
cp .env.example .env
Edit .env with your API URL
```
- Start the development server:
```bash
npm run dev
```
StarkNet Setup (Optional)
-
Navigate to the StarkNet directory:
```bash
cd starknet
``` -
Install Scarb (Cairo package manager):
```bash
curl --proto '=https' --tlsv1.2 -sSf https://docs.swmansion.com/scarb/install.sh | sh
``` -
Build contracts:
```bash
scarb build
``` -
Deploy contracts:
```bash
./scripts/deploy.sh
``` -
Update backend .env with deployed contract addresses
Default Credentials
After seeding the database, you can use these credentials:
- Admin: admin@manageassets.com / admin123
- Manager: manager@manageassets.com / manager123
- Employee: john@manageassets.com / john123
Project Structure
```
manageassets/
├── frontend/ # Next.js frontend application
│ ├── app/ # App router pages
│ ├── components/ # React components
│ ├── lib/ # Utilities and API client
│ └── public/ # Static assets
├── backend/ # NestJS backend application
│ ├── src/
│ │ ├── assets/ # Asset management module
│ │ ├── auth/ # Authentication module
│ │ ├── inventory/ # Inventory management module
│ │ ├── maintenance/ # Maintenance tracking module
│ │ ├── branches/ # Multi-branch support
│ │ ├── audit/ # Audit trail module
│ │ └── starknet/ # StarkNet integration
│ └── uploads/ # File storage
└── starknet/ # Cairo smart contracts
├── src/ # Contract source files
└── scripts/ # Deployment scripts
```
API Documentation
The API documentation is available at http://localhost:3001/api/docs when the backend is running.
Key Features Documentation
Asset Management
- Register assets with detailed information
- Generate and print QR codes
- Track asset lifecycle from acquisition to disposal
- Assign assets to users or departments
- Transfer assets between branches
Inventory Management
- Track consumable items with quantity-based management
- Set reorder points and receive low stock alerts
- Record stock transactions with full history
- Generate inventory valuation reports
Maintenance Tracking
- Schedule preventive maintenance
- Log repairs and associated costs
- Track asset downtime and performance
- Generate maintenance cost reports
Blockchain Integration
- Immutable audit trail for critical events
- On-chain proof of asset ownership
- Transparent asset lifecycle tracking
- Optional NFT-like certificates for high-value items
Reporting & Analytics
- Asset distribution heatmaps
- Depreciation calculations and forecasts
- Maintenance vs expense trends
- Performance and downtime analytics
- Custom report generation
Contributing
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'Add some amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
License
This project is licensed under the MIT License - see the LICENSE file for details.
Support
For support, email support@manageassets.com or open an issue in the GitHub repository.
Acknowledgments
- Built with Next.js, NestJS, and StarkNet
- UI components from shadcn/ui
- Icons from Lucide React