PayTM Interview HLD Round || Interview Experience || Senior Software Engineer
Summary
I interviewed for a Senior Software Engineer role at PayTM and completed a high‑level design (HLD) round that focused on building a system to stream live market prices and handle stock orders.
Full Experience
Got a call from PayTm HR for direct HLD round for senior-software engineer role. And if clear this round then have to do home-assignement and one more Managerial round.
HLD Interview Question
-
- Design the system that receives the exchange tick stream (NSE/BSE: peak ~1M ticks/second across ~5,000 instruments) and delivers live prices to 5M concurrently connected app users, each watching a watchlist of ~20 instruments. Freshness target: user sees a price at most ~500 ms old.
-
- User buy/sell stocks - place order -> app routes to exchange -> app shows the positions, holdings
Kind of Groww/Zerodha kind of platform.
My Answer
Follow the Hello-Interview Pattern to explain the things.
Functional Requirements
- User can buy/sell stocks.
- User can watch the live prices of stocks.
- User can create a watchlist and add at max 20 stocks.
- User can check for status of their orders which they make.
Non-Functional Requirements
- System should be scalable to handle 5M concurrent DAU.
- Latency to make orders (buy/sell) should be <300ms.
- Availability >> Consistency (Eventual Consistency)
- System make sure that Buy order and sell order bus be trigger at required triggered point which you set.
Core Entities
- User
- Stock
- Orders (OrderType: BUY|SELL)
- Stock-Exchange
- WatchList
API's
- User buy/sell (order)
POST: /v1/stocks/stockId -> Order Information
Payload:
{
stockExchnage: NSE/BSE,
orderType: BUY/SELL
no_of_shares: <<>>,
trigger_price:
at_market_price: true/false
}
- User can see the stocks
GET: /v1/stocks/stockId -> Stock Information
- User can create a watchList
POST: /v1/watchList -> watchlist
Payload:
{
name: <<>>,
stocks: [<ticker-symbol>],
}
- User can see the watchlist
GET: /v1/watchlist/watchListId -> WatchList
- Check the status of the order
GET: /v1/orders/orderId -> Order along with status
HLD: Main challenge is to deliever the live prices to user when they open the particular stock. I am confused how should i get the data from stock-exchange. And didn't do much to explain it, though i use redis-pub-sub to push live prices to the customer via Server Sent events.
For order updates, expecting web-hooks would be available when particular order is success and provide the update. Service is callback url for Stock-exchange when any order is confirmed. Apart from that cron-job as reconcilation job (second-option), which will run when market timing ends and check if any order status is still shows PENDING and make a batch call to stock-exchange to get the status information.

Interview Questions (2)
Design a real‑time market data streaming system
Design the system that receives the exchange tick stream (NSE/BSE: peak ~1M ticks/second across ~5,000 instruments) and delivers live prices to 5M concurrently connected app users, each watching a watchlist of ~20 instruments. Freshness target: user sees a price at most ~500 ms old.
Design a stock trading platform with order flow
User buy/sell stocks - place order -> app routes to exchange -> app shows the positions, holdings. The platform is similar to Groww/Zerodha.