Stocks Platform for TR Capital

Stock portfolio management platform for Indian investment advisory firm

TR Capital is a portfolio management firm in India. They engaged Brainstack Technologies to build a custom web application for stock portfolio management. The platform had to handle the operational and regulatory complexity of managing client portfolios across Indian equity markets — trade import and reconciliation, corporate action processing, portfolio analytics, client reporting — inside one purpose-built system.

The engagement was prompted by a common challenge in mid-market Indian advisory firms. Enterprise platforms are designed and priced for institutional asset managers. Retail-grade tools can't handle multi-asset tracking, corporate action adjustments, or regulatory reporting. The firm needed a platform built for their specific operational reality.

Project Overview

Client: TR Capital — Portfolio management firm, India. Reference calls available under NDA for qualified prospects.
Industry: Financial Services — Investment Advisory / Wealth Management
Project: Portfolio Management web application
Broker Integration: Broker trading platform
Duration: ~6 months
Team: 3 full-stack developers, 2 QA engineers, 1 project lead

The Problem Space

Portfolio management for an Indian investment advisor is not a straightforward data-entry problem. The client specifically called out “financial complexities and flows” — and that complexity is real. Here's what a portfolio management platform in the Indian market context must handle correctly:

Indian Capital Market Structure

Indian equity markets have structural characteristics that a portfolio platform must account for natively:

  • Multi-Exchange Environment: Securities trade across multiple exchanges with different instrument identifiers and liquidity profiles. The platform needs to reconcile holdings regardless of which exchange a trade executed on.
  • Settlement Cycles: Equities and derivatives follow different settlement cycles with distinct mechanics. Any reconciliation engine needs to understand these cycles to correctly determine settled vs pending positions.
  • Corporate Actions: Indian listed companies frequently issue bonuses, stock splits, rights issues, dividends (interim and final), and undergo mergers and demergers. Each corporate action requires adjustment to quantity, cost basis, and historical return calculations across every affected client portfolio. Getting this wrong creates cascading errors in performance reporting.
  • Tax Implications: Dividend income is taxed at rates that vary by the investor's entity type. Capital gains classification (short-term vs long-term) depends on holding periods, and the tax treatment differs across instrument types.

Regulatory Requirements

Investment advisor regulations impose record-keeping and reporting obligations. An advisory firm must maintain auditable records of all investment advice, portfolio changes, fee computations, and performance reporting. This isn't optional compliance — it's a licensing requirement. Any platform built for this domain needs an immutable audit trail as a first-class design consideration, not an afterthought.

Multi-Client Complexity

An advisory firm managing portfolios for multiple clients faces a compounding complexity that retail tools don't address: the same security may be held across many client portfolios with different entry prices, quantities, holding periods, and investment mandates. Portfolio analytics — returns, attribution, risk — must be computed per-client, not in aggregate. Client reporting must reflect each client's specific performance against their specific benchmark, not a firm-wide composite.

Building a portfolio management platform for the Indian market requires understanding settlement cycles, corporate action mechanics, return computation methodology, regulatory compliance obligations, and tax computation rules that vary by investor entity type.

What We Built

The platform we delivered addresses these domain-specific requirements as a unified web application.

1. Trade Import and Reconciliation

The platform ingests trade data from the broker's trading terminal via structured file imports. A parser normalises the broker-specific export format into the platform's internal trade schema — handling instrument naming conventions, date formats, and transaction type mappings specific to the broker's export structure.

After import, an automated reconciliation routine checks imported trades against existing portfolio positions and flags discrepancies for human review. The system handles the nuances of Indian market settlement — including distinct settlement cycles for equity and derivative positions.

The parser was designed to be extensible: if the firm adds brokerage relationships in the future, new import formats can be supported through configuration rather than code changes.

2. Corporate Action Processing

Corporate actions are handled through a structured workflow. When a corporate action is entered (stock split, bonus issue, dividend, merger), the system computes the impact across all affected client portfolios — adjusting quantities, cost basis, and historical per-share metrics as required.

Critically, the system shows a preview of all changes across all affected portfolios before committing. In a multi-client environment, a single corporate action on a widely-held stock can touch dozens of portfolio records. The preview-and-confirm pattern prevents costly errors that are difficult to unwind after the fact.

Dividend processing includes tax computation based on each client's tax status, and capital gains classification tracks holding periods for short-term vs long-term determination.

3. Portfolio Analytics

The platform computes portfolio metrics at the per-holding, per-client, and aggregate levels:

  • Return Computation: Uses actual transaction dates rather than simplified period returns — essential for accurate performance measurement when clients invest and withdraw at different times (staggered purchases, partial sells, dividend reinvestments).
  • Sector and Market-Cap Allocation: Portfolio composition breakdown using standard sector classifications and market-cap tier definitions (large-cap, mid-cap, small-cap).
  • Benchmark Comparison: Portfolio returns tracked against configurable benchmarks (Nifty 50, Nifty 500, Sensex, sector indices, or custom composites) across standard reporting periods.

Historical portfolio state is preserved rather than overwritten, enabling multi-period analysis — comparing current quarter allocation and performance against prior periods, which is essential for meaningful investment review discussions with clients.

4. Client Reporting

The platform generates client-facing portfolio reports — holdings summary, performance analysis, allocation breakdown, and benchmark comparison — as formatted PDFs. Reports are configurable per client to reflect their specific mandate and benchmark.

This replaced what had been a manual, time-intensive process. The advisory team can now generate accurate, consistently formatted reports directly from the platform's live data, freeing time that was previously spent assembling reports manually.

5. Dashboard and Access Control

The platform provides role-based views appropriate to different users within the firm:

  • Investment team: Cross-portfolio positions, aggregate exposure, and allocation monitoring
  • Operations: Reconciliation status, pending corporate actions, and import exceptions
  • Restricted views: Appropriate access boundaries ensure each user sees only what their role requires

Technical Approach

Data Integrity

Financial calculations require exact decimal arithmetic. Standard floating-point representation introduces rounding errors that compound across thousands of transactions — a problem that's invisible at small scale but creates material discrepancies as transaction history grows. The platform uses precise decimal types for all monetary and quantity fields throughout the computation chain.

All timestamps are aligned with IST and exchange trading hours, with explicit handling of market holidays for settlement cycle calculations.

Security

Given the sensitivity of client financial data:

  • Role-Based Access Control with granular permissions per user role
  • Audit Logging — every significant user action logged to an append-only audit table, supporting regulatory record-keeping requirements
  • Encryption at rest and in transit for all client data, with additional segregation for PII (PAN numbers, bank details)
  • Session management with configurable timeouts and concurrent session controls

Integration

  • Broker trade file import with extensible parser framework
  • Market data ingestion for end-of-day closing prices and index levels
  • Report distribution via email with delivery tracking

Technical Summary

PlatformCustom web application for portfolio management
Broker IntegrationBroker trading platform (extensible parser framework for future brokers)
Market DataExchange closing prices, index levels, NAVs
Key CapabilitiesTrade import/reconciliation, corporate action processing, return analytics, benchmark comparison, client reporting (PDF), role-based dashboards
SecurityRBAC, audit logging, encryption at rest and in transit, session management
ComplianceDesigned for investment advisor regulatory record-keeping requirements

Client Testimonial

Despite the project's complexity involving financial complexities and flows, their engineers handled it well. Their team showed great knowledge and enthusiasm toward delivering excellent results.

— Aashish Agarwal, TR Capital

Need a Financial Services Platform?

Contact Brainstack Technologies to build domain-specific applications for portfolio management, regulatory compliance, and financial analytics.