Phase 1 Architecture • AWS DynamoDB Single-Table • Mock Broker Adapter
Dhan Family Multi-Account
Trading & Risk Management
Let one authorised family trader submit batches of options orders across separately owned Dhan accounts, while each family member retains absolute risk limits and instant entry revocation.
1. Authorised Trader Flow
Create and preview multi-account options trade batches (NIFTY, BANKNIFTY, FINNIFTY, MIDCPNIFTY, SENSEX) with official exchange lot sizes, automated contract resolution, per-account lot allocations, stop-loss risk checks, and pre-authorized dispatch.
- Multi-trade batch creation with official instrument master resolution
- Server-side risk preview calculating margin, SL risk & remaining loss budget
- Atomic pre-dispatch check prevents sending orders if owner revoked access
2. Investor Controls
Each consenting family member connects their own Dhan account, sets their own maximum lots, capital, daily loss, and open exposure, and can revoke permission immediately with zero delay.
- Independent risk limits: max lots, max capital, max daily loss, max exposure
- Immediate permission revocation: atomically increments version to fence queued work
- Dhan account credentials masked and encrypted; never exposed to frontend
Safety, Regulatory & Architecture Commitments
AWS DynamoDB Single-Table
Strict schema with atomic conditional writes, strongly consistent reads on permission checks, and phone HMAC lookup.Fail-Closed Risk Policy
17 mandatory server-side checks. Orders are rejected immediately if permission, lots, capital, exposure, or daily loss limits fail.Simulation by Default
All orders in Phase 1 execute through the high-fidelity MockBrokerAdapter. Live trading requires explicit Phase 5 enablement.