Skip to content

Configuration reference

Everything is an environment variable, prefixed FLIPDESK_, loaded from backend/.env (see backend/.env.example for the copy-paste starting point) or the real environment. All values are optional — defaults work out of the box in read-only mode. Source of truth: backend/app/config.py.

Ports

VarDefaultNotes
FLIPDESK_WEB_PORT5873Vite dev server. This also drives the SSO redirect URI and CORS origin — see below.
FLIPDESK_BACKEND_PORT8743uvicorn API; Vite proxies /api + /auth here in dev.

Both are deliberately off the common defaults (not 3000/3333/5000/5173/5174/8000/8080/ 8888) to avoid clashing with other local services. Change them together — the justfile, web/vite.config.ts, and backend/app/config.py all read the same two vars, so setting one without the other (or without restarting both processes) will break the dev proxy or the SSO redirect.

ESI client

VarDefaultNotes
FLIPDESK_ESI_BASE_URLhttps://esi.evetech.net
FLIPDESK_ESI_DATASOURCEtranquility
FLIPDESK_ESI_USER_AGENTplaceholderSet this. CCP requires an identifying User-Agent (app/version (char name; contact)); a placeholder violates ESI's terms in spirit even if it doesn't 4xx.

SSO / auth

VarDefaultNotes
FLIPDESK_ESI_CLIENT_ID""From developers.eveonline.com. Until both id + secret are set the login button stays disabled.
FLIPDESK_ESI_CLIENT_SECRET""
FLIPDESK_ESI_REDIRECT_URIderivedBlank = http://localhost:{WEB_PORT}/auth/callback. Set explicitly only if the origin you log in from differs from WEB_PORT (e.g. a LAN/phone origin) — it must exactly match the Callback URL registered at developers.eveonline.com.

SSO scopes

flipdesk requests scopes to read your own market orders, wallet-relevant skills, and standings (for fee derivation), and — if you add a citadel hub — structure market access. If a login predates a scope flipdesk now needs (e.g. you added structure support after first logging in), the header shows a warning; log out and back in to re-authorize with the current scope set. Skill-ID verification runs on every login: if CCP ever remaps the Broker Relations / Accounting skill type IDs, flipdesk detects the name mismatch and falls back to placeholder fees rather than silently computing wrong numbers (me().skills_verified: false).

Market scope

VarDefaultNotes
FLIPDESK_REGION_ID10000002The Forge.
FLIPDESK_HUB_STATION_ID60003760Jita IV - Moon 4 - Caldari Navy Assembly Plant — the seeded NPC hub, always available even logged out.
FLIPDESK_CITADEL_OWNER_FEE0.0Your hub citadel's owner-set broker fee (skills don't apply at citadels — this is a manual override, not derived). SCC's 0.5% is added automatically. Leave 0.0 while the selected hub is an NPC station.

Fee placeholders (logged-out fallback)

VarDefault
FLIPDESK_DEFAULT_BROKER_FEE0.01
FLIPDESK_DEFAULT_SALES_TAX0.0337

Replaced by rates derived from your live skills + standings once logged in (see GET /api/mefees.derived).

Reprice advisor

VarDefaultMeaning
FLIPDESK_REPRICE_HYSTERESIS_PCT0.02Ignore drift smaller than this % of price — prevents flapping suggestions on sub-tick noise.
FLIPDESK_REPRICE_MIN_DRIFT_ISK1.0...or this absolute ISK, whichever gate is stricter for cheap items.
FLIPDESK_REPRICE_COOLDOWN_S60.0Don't re-suggest the same order within this window even if it drifts again.
FLIPDESK_REPRICE_MIN_MARGIN_PCT0.5A buy reprice that would drop flip margin below this → suggest cancel instead of chasing the market down.

Scanner: depth + capture threshold

VarDefaultMeaning
FLIPDESK_DEPTH_TOLERANCE_PCT0.5Aggregate order depth within this % of the best price counts toward bid_depth/ask_depth/executable_qty.
FLIPDESK_MIN_FLIP_NET_PCT0.5Legacy capture-play threshold.

Scanner: maker-flip liquidity/sanity gates

The citadel-hub edge case — quoting both sides only makes sense where the book is thick enough to actually fill both legs.

VarDefaultMeaning
FLIPDESK_MAKER_MIN_PRICE1000.0Skip dust below this ISK on either side.
FLIPDESK_MAKER_MIN_DEPTH5Minimum executable units on each side to count as a maker row.
FLIPDESK_MAKER_MAX_SPREAD_PCT100.0Wider gross spread than this = probably stale/illiquid, excluded entirely.
FLIPDESK_MAKER_THIN_SPREAD_PCT25.0Above this, UI shows the "FILL UNLIKELY" caution badge (still listed, flagged).

Price history / trend recommender (Phase 4)

Sampled by flipdesk itself, tiered: a WATCH set (board rows + your own order types) every ingest pull, the whole book once an hour (discovery tier) — ESI has no structure trade-history endpoint, so this is the only way to build a series.

VarDefaultMeaning
FLIPDESK_HISTORY_ENABLEDtrueMaster switch.
FLIPDESK_HISTORY_RETENTION_DAYS7Prune samples older than this.
FLIPDESK_HISTORY_DISCOVERY_INTERVAL_S3600Whole-book sample cadence.
FLIPDESK_HISTORY_MAX_WATCH_TYPES1000Cap on the per-pull watch set size.
FLIPDESK_TREND_LOOKBACK_HOURS6.0Window for momentum / mean-reversion calculations.
FLIPDESK_TREND_MIN_SAMPLES6Minimum samples before a type can get a recommendation.
FLIPDESK_TREND_TOP_N100
FLIPDESK_TREND_MOMENTUM_THR_PCT2.0Above this → rising signal.
FLIPDESK_TREND_DIP_THR_PCT3.0Below own mean by more than this → dip signal.
FLIPDESK_TREND_WIDE_SPREAD_PCT15.0Above this → wide (market-make) signal.
FLIPDESK_TREND_W_MOMENTUM / _W_DIP / _W_SPREAD / _W_LIQUIDITY1.0 / 1.0 / 0.5 / 0.3Ranking score weights — raise to bias the top-N toward that signal type.

Hub discovery + book cache

VarDefaultMeaning
FLIPDESK_HUB_CACHE_S300Serve a hub's orderbook from SQLite (zero ESI calls) until it's this old — a ceiling under the ESI Expires header so switching back to a recently-viewed hub doesn't re-pull the whole book.
FLIPDESK_HUB_DISCOVERY_INTERVAL_S900Run full structure discovery (what citadels your character can access) at most this often.
FLIPDESK_HUB_CORP_403_COOLDOWN_S21600After a /corporations/{id}/structures/ 403, stop retrying it for this long.

Storage

VarDefault
FLIPDESK_DB_PATHflipdesk.db

SQLite, WAL mode, disposable — it's an orderbook + price-history cache, not user data. Safe to delete any time (e.g. after a schema change breaks an old file); the next ingest cycle rebuilds it.

Released under the MIT License.