← Dashboard

Settings

AI provider, Angel One broker credentials and risk defaults. Saved to /app/.env


Reading balances…
LIVE LOCKED
true · ack false
Changes apply immediately for most settings, because they are written to .env and also hot-applied to the running server. Exceptions are marked read-only. Secret fields show only the last 4 characters — leave them blank to keep the current value. Every field has a button to empty it, or reset it to its default if it holds a number or a switch. Nothing changes until you press Save settings.

Where this app is running

Detected automatically, then reduced to one answer: the exact five values to type into the Angel One “Add App” form for this deployment, whether that is this computer or a VPS. The detected public IP and MAC address are shown below it.

Detecting this deployment…

AI research status

What the research engine will actually use right now.

Active providergemini
Keys detectedgemini
AI researchON
Call cap / scan5
TradingAgentsON

Without a provider key the engine falls back to an offline placeholder model. Those placeholder scores are not real signals, so do not judge stock-picking quality from them.

AI usage & cost

Measured from the provider's own token counts on every call, priced with published list prices and your USD_INR_RATE. Nothing here is a guess about how many calls were made.

Loading measured AI spend…

Market data for backtesting

Download real daily price history into data/history/. Backtests are only meaningful once these files exist.

Fetching ALL symbols makes one request per symbol, so it takes a few seconds.
No fetch run yet.
SymbolRowsFirst dayLast dayFile
Loading…

Live trading safety gates

Every gate must be green before a real order can be placed.

ALLOW_LIVE_TRADING
LIVE_TRADING_ACK exact text
ANGEL_STATIC_IP_REGISTERED
ANGEL_STATIC_IP saved (the whitelisted IPv4)
Angel One credentials present

Deployment & network

Where this app is running, what the outside world sees, and which URL and IP are registered with the broker. The panel above detects these automatically; these fields are the ones you want saved.

The https:// URL this app is served from, e.g. https://trade.example.com. Leave blank and the app derives one from whatever address you are browsing on.
The public IPv4 you whitelisted in the SmartAPI portal. Saved here so the app can warn you the moment your IP drifts, which would silently start rejecting live orders.
The redirect URL registered against your API key in the portal. Recorded here so the portal value and this deployment stay in sync.
Keyless HTTPS endpoint used to discover the IP the internet sees. Clear it if you would rather not call a third party; detection then reports the IP as unverified.

Safety & realism

The master kill switch and how honestly paper fills are modelled.

Master switch for OPENING positions. Turning this off blocks new buys but still allows exits, so a halt can never trap you in a position. Persisted, so it survives a restart.
Fills are moved against you by this many basis points (1 bp = 0.01%). 5 is a realistic default for liquid NSE names. Set 0 for frictionless, optimistic fills.

AI / Research

Which AI provider rates stocks, and how many calls it may make.

Which AI provider rates stocks. "auto" uses the first provider that has a key saved.
When on, the AI rates candidates and overrides the built-in placeholder scores. When off, only the offline model is used.
Google AI Studio key (starts with AIza). Free tier available at aistudio.google.com/apikey. Stored: ••••••••cBMw · blank = keep unchanged
e.g. gemini-2.5-flash (fast/cheap) or gemini-2.5-pro (stronger).
Alternative to Gemini. Starts with sk-. Not set · blank = keep unchanged
e.g. gpt-4o-mini.
Alternative to Gemini/OpenAI. Starts with sk-ant-. Not set · blank = keep unchanged
e.g. claude-3-5-sonnet-latest.
Caps how many stocks the AI rates per research run. This is the only real driver of AI cost: each call is a fraction of a paisa, so the cap is about speed and rate limits more than money. See AI usage & cost below.
Used to show estimated AI spend in rupees. Set it to your card rate so the cost panel matches your statement.
Advanced multi-agent research. Requires the tradingagents package plus its own keys. Falls back to the simple AI rating on error.

Price feed & market data

Where live prices come from, and the historical window the Fetch fresh data button downloads. Without a feed the exit rules can never fire on their own; without real history a backtest cannot tell you anything.

Where live prices come from. none = manual price ticks only. replay = walk one bar per poll through data/history CSVs (great for watching exit rules fire). angel = real Angel One last-traded prices.
How often to pull fresh prices. This is what lets target, stop-loss and trailing-stop rules fire without manual ticks.
Where replay bars come from. auto prefers data/history/*.csv, then Yahoo Finance, then Alpha Vantage, then synthetic.
Default window for the Fetch fresh data buttons on Backtest and here. 400 calendar days is roughly 18 months of trading sessions.
How many daily bars to load per symbol for replay mode.
Restart from the first bar when replay runs out of history.

Notifications

Webhook, Telegram and email alerts for events that matter.

Master switch for outbound notifications. Alerts are best-effort and never interrupt trading.
Comma-separated keys: position_opened, position_closed, campaign_completed, daily_loss_limit, order_rejected, global_halt, intraday_force_exit, risk_block, warning, error.
Receives a JSON POST with app, key, level, title, message and campaign_id. Works with Slack/Discord/ntfy style endpoints.
From @BotFather. Needs NOTIFY_TELEGRAM_CHAT_ID too. Not set · blank = keep unchanged
The chat, group or channel id to post into.
e.g. smtp.gmail.com. Needs from/to addresses; set user+password to authenticate.
587 for STARTTLS (default), 465 for implicit TLS, 25 for plain.
Usually the full email address.
An app password, not your normal account password. Not set · blank = keep unchanged
Sender address.
Recipient address.

Angel One broker

Credentials and the safety gates for real-money orders.

Paper simulates fills locally. Live routes real orders to Angel One.
Master live switch. Also needs the acknowledgement text and a registered static IP.
Must be exactly: I_UNDERSTAND_LIVE_TRADING_RISK
From the Angel One SmartAPI developer portal. Stored: ••••••••h2KN · blank = keep unchanged
Your Angel One login ID, e.g. A123456.
Your Angel One trading password (not the app PIN). Stored: ••••••••0912 · blank = keep unchanged
The base32 seed behind your 2FA QR code, used to generate the 6-digit code at login. Stored: ••••••••JNN4 · blank = keep unchanged
Set true only after registering your server IP with Angel One, otherwise live orders are rejected.
Angel One symbol/token master used to resolve NSE tradingsymbols.

Risk & runtime

Defaults for new campaigns and the daily session timetable.

Pre-filled target for new campaigns. A target is a goal, never a guarantee.
Pre-filled stop loss for new campaigns.
Pre-filled daily loss cap. When hit, new buying stops and open positions are closed.
Pre-filled cap on simultaneous positions.
How often the background loop reconciles orders and checks targets. Minimum 5 seconds.
IST clock time (HH:MM) after which no new intraday position is opened. Default 14:45.
IST clock time (HH:MM) when intraday positions are squared off automatically. Default 15:05.
Comma-separated ISO dates treated as closed, e.g. 2026-01-26,2026-03-04

Dashboard access

Login protection for the web UI.

Per source IP, within the lockout window.
How long a source IP is blocked after too many failed logins.
How often the dashboard polls for updated prices and P&L. 0 disables auto-refresh.
Keep on for any internet-facing deployment. Turn off only on a trusted local machine.
HTTP Basic username.
Change this from CHANGE_ME_NOW before exposing the app. Stored: ••••••••dmin · blank = keep unchanged

System

Read-only runtime information.

Informational label reported by /health.
SQLite file path. Changing this requires editing .env and restarting, because the engine is bound at startup.

Test connections

Each test talks to the real service. The Angel One test signs in but never places an order.

No test run yet. Each test contacts the real service; the Angel One test signs in but never places an order.

Safety controls

The kill switch blocks new entries everywhere while still allowing exits, so halting can never trap you in a position.

TRADING ENABLED
Trading is enabled.

Save

Writes changed values to .env and applies them live.

Nothing saved yet.

Danger zone — clear data

These buttons delete things and cannot be undone in the app. Download a backup first — it writes every row to JSON, so nothing is lost permanently, though restoring means re-inserting rows yourself. Every button needs two clicks, and a clear is refused while positions are still open.

Stored rows
Open positions
Price history files
Safe to clear

Clearing deletes campaigns, trades, orders, research recommendations, campaign chat, events, backtest runs, AI usage records and the audit log. It never places a broker order, and it leaves .env alone unless you choose the full reset. If positions are still open the clear is refused, because deleting those rows would not close anything — it would just lose track of them. “Close positions, then clear” exits them first, and is refused entirely while live trading is enabled.

No clear run yet.