Platform Market Data
Optional Fallback
Platform market data is an optional server-side fallback for users who have not connected a personal Alpaca account. It is backed by the Alpaca Broker API and is only enabled when the platform team configures credentials and feature flags.
Where It Applies
Section titled “Where It Applies”Platform-served bars are available only on these app surfaces:
| Surface | What it enables |
|---|---|
| Algo Lab | Load historical bars and run Pine strategy backtests without a personal Alpaca connection |
| Backtest vs Alerts | Load the optional price chart bars without a personal Alpaca connection |
If the fallback is disabled, both pages keep the previous behavior and ask the user to connect Alpaca before loading market bars.
What It Does Not Replace
Section titled “What It Does Not Replace”You still need your own Alpaca connection for:
- Alerts vs Fills fill-review analysis
- Trade fills and account synchronization
- Portfolio data
- Live SIP or premium feed entitlements
- Crypto or unsupported asset classes
- Any workflow that depends on your personal broker account
Admin Configuration
Section titled “Admin Configuration”The server reads these optional variables:
| Variable | Purpose |
|---|---|
ALPACA_BROKER_API_KEY | Broker API partner key |
ALPACA_BROKER_API_SECRET | Broker API partner secret |
ALPACA_BROKER_ENV | sandbox or production |
ALPACA_BROKER_DATA_FEED | Accepted for compatibility, but forced to iex |
ALPACA_BROKER_MAX_REQUESTS_PER_MINUTE | Shared server-side throttle |
ENABLE_PLATFORM_MARKET_DATA | Master kill switch |
ENABLE_PLATFORM_MARKET_DATA_BACKTEST_LAB | Enables the Algo Lab surface |
ENABLE_PLATFORM_MARKET_DATA_BACKTEST_VS_ALERTS | Enables the Backtest vs Alerts surface |
Use the master flag and per-surface flags together. Keeping credentials blank or any relevant flag set to false preserves the old connect-Alpaca behavior.