Web Dashboard
Web Dashboard
Section titled “Web Dashboard”The Bazaar dashboard is a React single-page app bundled directly inside the mod. It talks to an HTTP and WebSocket server embedded in the jar, so there is no separate deploy step: enable it in config/bazaar/config.conf and expose the right ports.
Enabling It
Section titled “Enabling It”In config/bazaar/config.conf:
role = "ORCHESTRATOR"
web { enabled = true port = 8080 publicBaseUrl = "https://bazaar.example.com" jwtSecret = "change-me-to-a-long-random-string" corsOrigins = [ "https://bazaar.example.com" ] linkCodeExpirySeconds = 300}Notes:
- Leave
publicBaseUrl = ""if you only need local or browser-relative access. - Set
publicBaseUrlwhen external systems need Bazaar-hosted asset URLs, such as Discord webhook embeds for item icons. - For a same-origin deployment,
corsOrigins = []is fine.
The dashboard listens on:
portfor HTTPport + 1for WebSocket
Point your reverse proxy at both. Example nginx:
location / { proxy_pass http://127.0.0.1:8080;}location /ws { proxy_pass http://127.0.0.1:8081; proxy_http_version 1.1; proxy_set_header Upgrade $http_upgrade; proxy_set_header Connection "upgrade";}Login Flow
Section titled “Login Flow”- Player runs
/bazaar linkin game. - Server returns a one-time code.
- Player enters it on the dashboard login screen.
- Dashboard exchanges the code for a JWT via
POST /api/v1/auth/link. - All subsequent requests carry the JWT in
Authorization: Bearer ....
Permissions are re-checked every request, so revoking bazaar.admin in game revokes admin UI access on the next API call.
| Route | What it shows |
|---|---|
/ | Personal hub, discovery feed, trending items, recent activity. |
/gts | GTS browse with filters, sort, and pagination. |
/ah | Auction House browse with channel selection. |
/ah/:channelId | Specific AH channel view. |
/listings/:id | Listing detail with history and similar listings. |
/analytics | Market-wide trends, price history, leaderboards, distributions. |
/profile | Your own listings, orders, collection, and transaction history. |
/profile/:uuid | Public player profile. |
/admin | Admin panel for users with bazaar.admin. |
Live Updates
Section titled “Live Updates”The dashboard subscribes to a WebSocket after login. Market events, notifications, and admin alerts update in near real time. If the socket drops, the dashboard retries and can fall back to polling.
Render Assets
Section titled “Render Assets”Bazaar’s web UI resolves render assets from the live server environment instead of shipping a fixed Pokemon snapshot.
item-rendering.confcovers item icons and item-model discovery.pokemon-rendering.confcovers Cobblemon-style Bedrock Pokemon assets: resolver JSON, poser JSON, model JSON, animation JSON, and textures.
pokemon-rendering.conf scans:
modScanDirsfor mod jars and extracted resourcesresourcePackDirsfor extracted pack roots containingassets/resourcePackArchivesfor.zipor.jarpacks scanned directly
This is what lets the dashboard render standard Cobblemon models, custom skin variants, layered emissives, animated overlays, and seasonal or server-specific resolver trees.
Dev Mode
Section titled “Dev Mode”If you’re modifying the web UI itself:
cd webnpm installnpm run devVite proxies /api/* to http://localhost:8080, so point it at a running Bazaar instance. For theme-only changes, you usually do not need dev mode: edit config/bazaar/themes/ or web-theme.conf and run /bazaar admin theme reload.
Common Issues
Section titled “Common Issues”- Dashboard loads but API requests 401. JWT expired or
jwtSecretchanged. Log in again. - WebSocket fails to connect. The reverse proxy is not forwarding
Upgradeheaders, orport + 1is blocked. - Discord webhook embeds cannot fetch Bazaar-hosted images. Set
web.publicBaseUrlto the public URL clients can reach. - Pokemon models or custom skins do not render on the dashboard. Check
pokemon-rendering.confand make sure the configured pack roots or archives contain the realassets/<namespace>/bedrock/pokemon/...andassets/<namespace>/textures/pokemon/...trees. Restart after editing. - Admin panel says “Forbidden”. The user does not have
bazaar.admin.