A community trade registry for Prosperous Universe players. List what you sell, find what you need.
📈 Live at https://prunderground.app — no setup required, just log in with your FIO key.
Discord trading channels aren't great for finding buyers and sellers off market - messages scroll away, searches are of questionable value and not everyone wants to make an elaborate spreadsheet.
PrUnderground fixes that. Connect your FIO account, list what you're selling, and share your storefront with your corp or community. One click copies a formatted post to Discord with a link to your live listings.
PrUnderground is designed to be hosted by a community (corp, faction, trading group) as a shared registry for members. Think of it as your community's private marketplace.
You can run it just for yourself as a personal storefront, but the real value comes when your community uses it.
- FIO Integration - Login with your FIO username and API key. We pull your company info, bases, and storage locations automatically. Data syncs on login and refreshes on demand.
- Live Inventory - Link listings to your actual storage. Shows "FIO-real-time" availability (stock minus your defined reserve).
- Flexible Pricing - Set absolute prices, CX-relative prices (percentage or fixed offset from Ask), or just "Contact me" for negotiated deals. CX prices sync automatically every 30 minutes.
- Bundles - Sell multiple items together as a package at a single price. Status indicators show IN STOCK / LOW / OUT / MTO / ∞ with responsive display.
- Expiring Deals - Mark listings as specials with optional expiry dates. Expired listings auto-hide.
- Public Profiles - Shareable link to your listings page. Send it to your corp, pin it in Discord, whatever.
- Copy to Discord - One click generates a formatted message (grouped by location) ready to paste into any channel. Customize the format with your own template.
- Browse & Search - Filter by material or location. Collapsible filters with active filter pills. Multi-column sorting with visual sort builder.
- Import/Export - Backup and restore your listings and bundles as JSON. Extensible format for future integrations.
- APEX Embed Support - Embed PrUnderground in Refined PrUn's XIT WEB tiles with full authentication.
- Theme Customization - 4 color palettes (Refined PrUn, PrUn Default, High Contrast, Monochrome) × 2 tile styles (Filled, Lite). Live preview in Account Settings.
- Python 3.10+
- A FIO account with API key (users need this to log in, not required for hosting)
Note: While you can run this as a personal tool, PrUnderground is designed to be hosted by a community - a corp, faction, or trading group. The more people using the same instance, the more useful it becomes.
# Clone the repo
git clone https://github.com/Zillatron27/PrUnderground.git
cd PrUnderground
# Create virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# Install dependencies
pip install -r requirements.txt
# Copy example env and configure
cp .env.example .env
# Run the app
uvicorn app.main:app --reloadThen open http://localhost:8000 in your browser.
Copy .env.example to .env and generate secrets:
# Generate secrets (run each command and paste the output into .env)
python -c "import secrets; print(secrets.token_hex(32))"Required environment variables:
# Security secrets (generate unique values for each)
SECRET_KEY=your-secret-key-here
SESSION_SECRET=your-session-secret-here
CSRF_SECRET=your-csrf-secret-here
# Database (SQLite by default, or use PostgreSQL connection string)
DATABASE_URL=sqlite:///./prununderground.db
# FIO API (default is fine unless you're running a local FIO instance)
FIO_API_BASE=https://rest.fnar.net
If upgrading an existing installation, run any new migration scripts:
python scripts/add_bundle_tables.py
python scripts/add_cx_absolute_column.py
python scripts/encrypt_existing_keys.py # v1.0.3: Encrypt FIO API keys at rest
# v1.0.5 migrations:
python scripts/add_low_stock_threshold.py
python scripts/add_discord_template.py
python scripts/add_exchange_table.py
python scripts/add_usage_stats.py- Backend: Python, FastAPI
- Database: SQLite (easy to swap for Postgres later)
- Frontend: Jinja2 templates, HTMX, vanilla JS, APEX-inspired dark theme
- Data: FIO API for Prosperous Universe game data
- UI polish and mobile responsiveness
- User data export/import
- Bundles (multi-item packages)
- Multi-column sorting
- CX absolute offset pricing
- Mobile UI improvements
- Custom Discord templates
- CX price display with auto-sync
- Discord bot integration
- Multi-community support
Early days - feedback welcome! Open an issue or ping me on Discord.
PrUnderground fills a specific gap in the PrUn tooling ecosystem:
| Tool | Focus |
|---|---|
| Refined PrUn | In-game UI enhancements |
| FIO | Game data API |
| PRUNplanner | Empire & base planning |
| PrUnderground | Community trade coordination |
- FIO/FNAR for the API that makes this possible
- The ADI community for feedback