Skip to content

Instantly share code, notes, and snippets.

@ceoashon
ceoashon / test.md
Created May 14, 2026 20:52 — forked from Mahdi451/test.md
tests

Below is a Detailed Product Requirements Document (PRD) for building the Position Tracker microservice in TypeScript (Node.js). The document covers system architecture, data flows, error handling, logging, and code samples separated into core modules for clarity. Each section is numbered and includes steps, edge cases, and instructions to add error checks, comments, and logging.


1. Overview

The Position Tracker is a standalone microservice that:

  1. Connects to the Tradovate WebSocket API for real-time market data and order updates.
  2. Processes updates and maintains trading positions (market, limit, and stop orders) with risk management (stop-loss, take-profit).