Skip to main content
World Monitor uses runtime feature toggles to enable/disable data sources without rebuilding the application. Toggles are stored in localStorage and synchronized across tabs.

Overview

Feature toggles provide:
  • Granular control over which APIs are called
  • Cost optimization by disabling unused paid APIs
  • Privacy control by disabling cloud services
  • Debugging by isolating data sources
  • Graceful degradation when API quotas are exhausted
Toggles are client-side only. Desktop users configure them in Settings. Web/cloud deployments must set environment variables.

Available Toggles

AI & Summarization

boolean
default:true
Ollama local summarizationLocal LLM provider via OpenAI-compatible endpoint (Ollama or LM Studio, desktop-first).Requires: OLLAMA_API_URL, OLLAMA_MODEL
Fallback: Falls back to Groq, then OpenRouter, then local browser model.
boolean
default:true
Groq summarizationPrimary fast LLM provider used for AI summary generation.Requires: GROQ_API_KEY
Fallback: Falls back to OpenRouter, then local browser model.
boolean
default:true
OpenRouter summarizationSecondary LLM provider for AI summary fallback.Requires: OPENROUTER_API_KEY
Fallback: Falls back to local browser model only.

Economic & Energy

boolean
default:true
FRED economic indicatorsMacro indicators from Federal Reserve Economic Data.Requires: FRED_API_KEY
Fallback: Economic panel remains available with non-FRED metrics.
boolean
default:true
EIA oil analyticsU.S. Energy Information Administration oil metrics.Requires: EIA_API_KEY
Fallback: Oil analytics cards show disabled state.
boolean
default:true
Supply Chain IntelligenceShipping rates via FRED Baltic Dry Index. Chokepoints and minerals use public data.Requires: FRED_API_KEY
Fallback: Chokepoints and minerals always available; shipping requires FRED key.

Markets & Trade

boolean
default:true
Finnhub market dataReal-time stock quotes and market data from Finnhub.Requires: FINNHUB_API_KEY
Fallback: Stock ticker uses limited free data (Yahoo Finance, CoinGecko).
boolean
default:true
WTO trade policy dataTrade restrictions, tariff trends, barriers, and flows from WTO.Requires: WTO_API_KEY
Fallback: Trade policy panel shows disabled state.

Security & Threats

boolean
default:true
Cloudflare outage radarInternet outages from Cloudflare Radar annotations API.Requires: CLOUDFLARE_API_TOKEN
Fallback: Outage layer is disabled and map continues with other feeds.
boolean
default:true
ACLED conflicts & protestsConflict and protest event feeds from ACLED.Requires: ACLED_ACCESS_TOKEN
Fallback: Conflict/protest overlays are hidden.
boolean
default:true
abuse.ch cyber IOC feedsURLhaus and ThreatFox IOC ingestion for the cyber threat layer.Requires: URLHAUS_AUTH_KEY
Fallback: URLhaus/ThreatFox IOC ingestion is disabled.
boolean
default:true
AlienVault OTX threat intelOptional OTX IOC ingestion for cyber threat enrichment.Requires: OTX_API_KEY
Fallback: OTX IOC enrichment is disabled.
boolean
default:true
AbuseIPDB threat intelOptional AbuseIPDB IOC/reputation enrichment for the cyber threat layer.Requires: ABUSEIPDB_API_KEY
Fallback: AbuseIPDB enrichment is disabled.

Tracking & Sensing

boolean
default:true
AIS vessel trackingLive vessel ingestion via AISStream WebSocket.Requires: WS_RELAY_URL, AISSTREAM_API_KEY (web) or AISSTREAM_API_KEY only (desktop)
Fallback: AIS layer is disabled.
boolean
default:true
OpenSky military flightsOpenSky OAuth credentials for military flight data.Requires: VITE_OPENSKY_RELAY_URL, OPENSKY_CLIENT_ID, OPENSKY_CLIENT_SECRET (web) or OPENSKY_CLIENT_ID, OPENSKY_CLIENT_SECRET only (desktop)
Fallback: Military flights fall back to limited/no data.
boolean
default:true
Wingbits aircraft enrichmentMilitary flight operator/aircraft enrichment metadata.Requires: WINGBITS_API_KEY
Fallback: Flight map still renders with heuristic-only classification.
boolean
default:true
NASA FIRMS fire dataFire Information for Resource Management System satellite data.Requires: NASA_FIRMS_API_KEY
Fallback: FIRMS fire layer uses public VIIRS feed.
boolean
default:true
AviationStack flight delaysReal-time international airport delay data from AviationStack API.Requires: AVIATIONSTACK_API
Fallback: Non-US airports use simulated delay data.
boolean
default:true
ICAO NOTAM closures (Middle East)Airport closure detection for MENA airports from ICAO NOTAM data service.Requires: ICAO_API_KEY
Fallback: Closures detected only via AviationStack flight cancellation data.

Desktop Configuration

Desktop app users configure toggles via the Settings window:
  1. Open Settings (Cmd+, or Ctrl+,)
  2. Navigate to the appropriate category tab:
    • AI & Summarization
    • Economic & Energy
    • Markets & Trade
    • Security & Threats
    • Tracking & Sensing
  3. Toggle features on/off with checkboxes
  4. Status indicators show:
    • Ready — credentials configured and valid
    • Partial — some credentials missing
    • Not Ready — no credentials
Visual feedback:
  • Sidebar shows ready count per category (e.g., “3/5 ready”)
  • Overview tab shows total progress ring
  • Dot indicators: green (all ready), blue (partial), yellow (none)

Web / Cloud Configuration

Toggles are disabled in web/cloud deployments. Features are controlled by environment variables only. To disable a feature server-side, omit the required API key:
.env.local
Setting a toggle to false in localStorage has no effect in web deployments. Server-side environment variables control feature availability.

Toggle Storage

Toggles are stored in localStorage under the key worldmonitor-runtime-feature-toggles:
Cross-tab sync: Changes in one tab/window propagate to others via the storage event. The main dashboard and settings window stay synchronized.

Feature Availability Logic

A feature is available when:
  1. Toggle is true (default: all enabled)
  2. AND (Desktop only) required secrets are present and valid
Web/cloud deployments skip step 2 — credential validation happens server-side. Desktop validation:

Analytics

Toggle changes are tracked via PostHog:
Event properties:
  • feature_id — toggle name
  • enabled — new state (true/false)

Debugging

To inspect current toggle state:
To reset to defaults:

Use Cases

Reduce API Costs

Disable paid APIs you’re not using:

Privacy Mode

Disable all cloud services, use local-only:

Quota Exhausted

Temporarily disable a rate-limited API:
The dashboard falls back to Yahoo Finance and CoinGecko.

Debugging Data Issues

Isolate a problematic data source:

Default State

All toggles default to true (enabled). The system loads stored state from localStorage on startup:
First launch uses defaults. Subsequent launches restore user preferences.

Feature Dependencies

Some features have multi-secret requirements: AIS Relay (web deployment):
  • WS_RELAY_URL — relay server URL
  • AISSTREAM_API_KEY — AISStream API key
AIS Relay (desktop):
  • AISSTREAM_API_KEY only (relay runs in sidecar)
OpenSky Relay (web deployment):
  • VITE_OPENSKY_RELAY_URL — relay server URL
  • OPENSKY_CLIENT_ID — OAuth client ID
  • OPENSKY_CLIENT_SECRET — OAuth secret
OpenSky Relay (desktop):
  • OPENSKY_CLIENT_ID — OAuth client ID
  • OPENSKY_CLIENT_SECRET — OAuth secret
Desktop deployments have different requirements than web — see desktopRequiredSecrets in the feature definition.

Settings Window UI

The settings window groups toggles into 5 categories: Progress calculation:
  • Ready = toggle enabled + secrets valid
  • Total = all features in category
Sidebar shows ready count and dot indicator:
  • Green dot = all ready
  • Blue dot = partial
  • Yellow dot = none ready