Automation config and limits
tradingOptions.automation: Auto mode, confirm timeout, script and manual limits.
tradingOptions={{
// Lot sizes come per symbol from the datafeed's resolveSymbol; limits count those lots.
automation: {
allowAutoExecution: false, // Auto mode is hidden unless true
confirmTimeoutMs: 30_000, // Confirm cards expire after this
scriptLimits: { // Partial<RiskLimits>; unset keys keep the defaults
maxLotsPerOrder: 2,
maxPositionLots: 4,
dailyLossLimit: 25_000,
squareOffOnDailyLoss: true,
allowSymbols: ["NSE:NIFTY", "NSE:BANKNIFTY"],
},
manualLimits: { maxLotsPerOrder: 20 },
},
}}Effective limits are layered per limit: library defaults, then your config, then what the user sets in Settings → Automation. Script orders and manual orders have separate limits; the order counters are shared. The full table of limits and defaults is in Risk limits and the kill switch.
Trading hours are on by default for scripts
Script orders only pass 09:15–15:30 Asia/Kolkata, with no new entries after 15:20. A feed that runs around the clock (like the demo's mock) needs scriptLimits: { tradingHours: null }, or every order outside NSE hours is denied.