ProtoShelf Documentation
ProtoShelf is a comprehensive inventory management system designed for electronics enthusiasts, makers, and professionals to organize and track their electronic components efficiently.
Component Tracking
Track quantities, costs, and specifications of electronic components with detailed information and custom categories.
Smart Organization
Organize components in bins and units with visual layouts that match your physical storage system.
WLED Integration
Visual component location with LED strip integration for easy finding in large storage systems.
Getting Started
Download
Download the ProtoShelf zip file from releases
Extract
Extract the zip file to your desired folder
Run
Double-click protoshelf.exe to start
http://localhost:3001
For Developers
If you want to modify or contribute to ProtoShelf, you'll need the development environment:
Prerequisites
- Go 1.23.4+
- Node.js 16+ and npm
- Git
Build Commands
Key Features
Component Management
Track Components
- Component name and description
- Quantity tracking
- Cost and purchase information
- Datasheet and order links
- Custom category assignments
Organization
- Bin-based storage system
- Unit layouts with visual positioning
- Custom categories with inputs
- Search and filter capabilities
Storage Units & Bins
Organize your components using a hierarchical system of units and bins:
Units
Physical storage containers (drawers, boxes) with configurable layouts and optional WLED integration for visual location assistance.
Bins
Individual compartments within units that can hold multiple components with precise positioning and sizing.
WLED Integration
Connect LED strips to your storage units for visual component location:
- Configure WLED IP addresses for each unit
- Visual highlighting of component locations
- Matrix-based LED positioning
- Remote LED control via network
First Time Setup
๐ Configuration File
ProtoShelf uses a configuration file to manage settings. The default configuration file is located in the root of the ProtoShelf directory and is named server.yaml. You can edit this file to customize your ProtoShelf server settings.
Default Configuration (server.yaml):
database:
autobackup: true # Enable automatic backups of the database
backupinterval: 24 # Backup interval in hours
maxbackups: 7 # Maximum number of backups to keep
sqlite:
path: data/sqlite/protoshelf.db # Path to the SQLite database file
logging:
format: text # Log format (text or json)
level: debug # Log level (debug, info, warn, error)
file: true # Enable logging to file other than console
server:
port: 80 # Port on which the server will run
๐ Setting the JWT Secret Environment Variable
โ ๏ธ Important: To keep your ProtoShelf server secure, you must set a JWT_SECRET environment variable before running the application. This secret is used to sign and verify authentication tokens.
Windows Setup
Step 1: Generate JWT Secret
In your ProtoShelf directory, run the batch file:
generate_jwt_secret.bat
Step 2: Set Environment Variable (Temporary)
You will see an output with a key. Copy the command and run it in your terminal:
set JWT_SECRET=your-generated-secret
Step 3: Set Environment Variable (Permanent - Optional)
To set the JWT_SECRET variable permanently:
- 1. Open Start Menu and search for "Environment Variables"
- 2. Click Edit the system environment variables
- 3. In the System Properties window, click Environment Variables...
- 4. Under User variables, click New...
- 5. Enter
JWT_SECRETas the variable name - 6. Paste your generated secret as the value
- 7. Click OK to save
Linux Setup
Step 1: Generate JWT Secret
In your ProtoShelf directory, run the shell script:
./generate_jwt_secret.sh
Step 2: Set Environment Variable (Temporary)
Copy the command from the output and run it:
export JWT_SECRET="your-generated-secret"
Step 3: Set Environment Variable (Permanent)
Add the export line to your shell profile:
# For bash users:echo 'export JWT_SECRET="your-generated-secret"' >> ~/.bashrc# For zsh users:echo 'export JWT_SECRET="your-generated-secret"' >> ~/.zshrc๐ Opening ProtoShelf for the First Time
Once you have set up the configuration file and the JWT secret, you can start your ProtoShelf server and access it in your web browser.
๐ Admin Account Setup: When you run the ProtoShelf server for the first time, you will be taken to a setup page where you can create an admin account. This account will have full access to manage your ProtoShelf server.
Step 1: Launch ProtoShelf
Double-click protoshelf.exe (Windows) or run the executable (Linux). The app will start and appear in your system tray.
Step 2: Open the Interface
Right-click the ProtoShelf icon in your system tray and select "Open ProtoShelf" or visit http://localhost (or the port you configured)
Step 3: Complete Initial Setup
Follow the setup wizard to create your admin account and configure initial settings
Step 4: Set Up Your Storage
Navigate to the "Units" tab to create your first storage unit (drawer, box, cabinet, etc.)
How to Use ProtoShelf
Managing Storage Units & Bins
Creating Units
- Go to the "Units" page
- Click "Add Unit"
- Enter a name (e.g., "Resistor Drawer", "IC Cabinet")
- Set the number of columns for your layout
- Optionally add WLED IP for LED integration
- Click "Save"
Adding Bins to Units
- Click on a unit to view its layout
- Click "Add Bin"
- Enter a label (e.g., "1kฮฉ Resistors", "ATmega328")
- Position and size the bin in the grid
- Save your changes
- Use descriptive names for units (e.g., "Passive Components Drawer 1")
- Keep bin labels specific (value, part number, or description)
- Group similar components in the same unit
- Use the visual layout to match your physical storage
Managing Components
Adding Components
- Go to the "Inventory" page
- Click "Add Component"
- Fill in component details:
- Name: Component identifier
- Quantity: How many you have
- Category: Type of component
- Cost: Price per unit
- Description: Additional details
- Datasheet Link: Link to specs
- Order Link: Where to buy more
- Assign to bins for physical location
- Save the component
Managing Inventory
- Update Quantities: Click on a component and modify the quantity as you use parts
- Search & Filter: Use the search bar to quickly find components
- Edit Details: Click the edit icon to update information
- Find Location: Use the locate feature to highlight where a component is stored
- Reorder Tracking: Use the order link when quantities get low
- Include part numbers in component names for easy identification
- Use consistent naming conventions (e.g., "Resistor 1kฮฉ 1/4W")
- Add datasheet links for quick reference during projects
- Keep order links updated for easy reordering
- Update quantities immediately after using components
Categories & Custom Fields
Using Categories
Categories help organize components by type and can include custom input fields specific to that category.
- Resistors: Value, tolerance, wattage
- Capacitors: Value, voltage rating, type
- ICs: Part number, package, function
- Connectors: Pin count, type, pitch
Custom Input Fields
Each category can have custom fields that appear when adding components of that type.
WLED Integration (Optional)
Connect LED strips to your storage units for visual component location. Perfect for quickly finding components in large storage systems.
Setup Process
- Install WLED on ESP32/ESP8266 controllers
- Mount LED strips around your storage units
- Configure WLED with your network settings
- In ProtoShelf, edit your unit and add the WLED IP address
- Test the connection using the locate feature
Using the Locate Feature
- Click "Locate" next to any component
- The corresponding bin area will light up
- Great for finding components in dim lighting
- Especially useful in large storage systems
Backup & Data Management
Manual Backup & Restore
Creating Backups
- Go to the "Settings" page
- Click "Create Backup"
- A JSON file will be downloaded automatically
- Store this file safely (cloud storage, external drive)
Restoring from Backup
- Go to the "Settings" page
- Click "Import Data"
- Select your backup JSON file
- Confirm the import process
Setting Up Automatic Backups
ProtoShelf can automatically create backups of your database at regular intervals.
Configuration
Edit the server.yaml file in your ProtoShelf directory:
Backup Schedule Options
"1h"- Every hour"6h"- Every 6 hours"24h"- Daily (recommended)"168h"- Weekly
Managing Automatic Backups
Viewing Available Backups
Use the Settings page to:
- View all automatic backups with timestamps
- Restore from any backup point
- See backup file sizes and creation dates
Backup Storage Location
Automatic backups are stored in: data/sqlite/backups/
- Always test restore procedures with backup files
- Store manual backups in multiple locations (cloud, external drive)
- Export data before major changes or updates
- Check backup logs periodically to ensure automation is working
Workflow Tips & Best Practices
Recommended Workflow
1. Plan Your Layout
- Sketch your physical storage
- Group similar components
- Consider frequency of use
- Plan for growth
2. Set Up Digital Structure
- Create units first
- Add bins to match physical layout
- Test the visual arrangement
- Configure WLED if using
3. Populate Inventory
- Start with most-used components
- Use consistent naming
- Add detailed specifications
- Include purchase information
Pro Tips for Efficient Management
Organization Strategies
- By Type: All resistors in one unit, capacitors in another
- By Project: Group components for specific projects together
- By Value: Organize components by value ranges within types
- By Frequency: Keep commonly used parts easily accessible
Maintenance Habits
- Update Immediately: Change quantities as soon as you use components
- Regular Audits: Periodically verify digital vs. physical inventory
- Reorder Alerts: Set mental triggers for low-quantity components
- Document Projects: Note which components were used for what
Power User Features
Keyboard Shortcuts & Speed
- Use the search bar for quick component lookup
- Bookmark frequently accessed component pages
- Use browser tabs for multiple views
- Set up quick access toolbar bookmarks
Advanced Organization
- Use component descriptions for search keywords
- Include alternative part numbers in names
- Use consistent abbreviations (e.g., "uF" vs "ยตF")
- Tag seasonal or project-specific components
API Reference
Components API
Locations API
Backup API
Other APIs
Configuration
Server Configuration
ProtoShelf uses a YAML configuration file located at server.yaml in your installation directory.
database:
autobackup: true # Enable automatic backups of the database
backupinterval: 24 # Backup interval in hours
maxbackups: 7 # Maximum number of backups to keep
sqlite:
path: data/sqlite/protoshelf.db # Path to the SQLite database file
logging:
format: text # Log format (text or json)
level: debug # Log level (debug, info, warn, error)
file: true # Enable logging to file other than console
server:
port: 80 # Port on which the server will run
Database Settings
- autobackup: Enable automatic database backups
- backupinterval: Hours between automatic backups
- maxbackups: Maximum number of backup files to retain
- sqlite.path: Path to the SQLite database file
Server & Logging
- server.port: Web interface port (default: 80)
- logging.level: debug, info, warn, error
- logging.format: text or json
- logging.file: Enable file logging
Backup & Restore
Export Data
Export your entire inventory as a JSON file for backup or migration purposes.
GET /export
Downloads a complete backup as protoshelf_backup.json
Import Data
Import data from a previously exported JSON file. This will upsert (insert or update) all data.
POST /import
Accepts JSON data to restore inventory
Automated Backups
POST /backup/create
Create a manual backup
GET /backup/list
List all available backups
POST /backup/restore
Restore from a specific backup file
Important Note
Always create a backup before performing major operations. The import function will overwrite existing data with matching IDs.