Every example uses only tools that NSE MCP actually exposes. Run them interactively on the Examples page
(npm run dev → http://localhost:5180/#/examples), where each one shows the live response, a visual view,
the raw JSON-RPC and TypeScript/Python/curl code. LAST_TRADING_DAY below stands for the most recent weekday (yyyy-MM-dd).
What are we trying to achieve? Before showing “live” numbers, check when NSE last refreshed its caches.
Which tools?
cm_get_data_status (CM Market Live) — When the live gainers/losers cache was last refreshed from NSE (every 5 min).cm_get_allstocks_status (CM Market Live) — When the live all-stocks cache was last refreshed (every 1 min) and how many securities are in each segment.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "cm_get_data_status",
"arguments": {}
}
}
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "cm_get_allstocks_status",
"arguments": {}
}
}
How to interpret the response
Use it in your app: Call these once when your app starts and show a “data as of …” badge. Warn users if lastCrawled is older than ~15 minutes during market hours.
What are we trying to achieve? Count advancing vs declining stocks for a trading day.
Which tool?
get_market_breadth (NSE Bhavcopy) — Advances, declines, unchanged and A/D ratio for a trading day. A/D > 1.5 ≈ bullish, < 0.7 ≈ bearish.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_market_breadth",
"arguments": {
"date": "LAST_TRADING_DAY"
}
}
}
How to interpret the response
Use it in your app: Call it for the last 10–20 trading days to chart breadth over time — the Insights page does exactly that.
What are we trying to achieve? Show the latest price, change, intraday range and 52-week range for RELIANCE.
Which tool?
cm_get_stock_quote (CM Market Live) — Near-real-time quote for one exact symbol: LTP, OHLC, change, volume, 52-week range and 30-day change.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "cm_get_stock_quote",
"arguments": {
"symbol": "RELIANCE"
}
}
}
How to interpret the response
Use it in your app: Use the exact NSE symbol. If users type company names, resolve them first with nse_lookup_symbol.
What are we trying to achieve? A user types “HDFC” — which NSE tickers match?
Which tools?
nse_lookup_symbol (NSE Bhavcopy) — Find exact NSE tickers from a partial name. Returns tickers only — the cheapest way to resolve a symbol.search_symbols (NSE Bhavcopy) — Like lookup, but each match includes last close, % change and last trading date (delisted symbols show an old date).Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "nse_lookup_symbol",
"arguments": {
"query": "HDFC"
}
}
}
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "search_symbols",
"arguments": {
"query": "HDFC"
}
}
}
How to interpret the response
Use it in your app: Back an autocomplete box with nse_lookup_symbol and show search_symbols details on hover.
What are we trying to achieve? Chart TCS’s daily OHLCV for the last 3 months.
Which tool?
get_stock_history (NSE Bhavcopy) — Up to 3 months of daily candles per call. Chain calls with next_end_date to go further back (5 years available).Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_stock_history",
"arguments": {
"symbol": "TCS",
"months": 3,
"endDate": "today"
}
}
}
How to interpret the response
Use it in your app: Loop: call with endDate=”today”, then with each next_end_date until you have enough rows. De-duplicate dates at chunk boundaries.
What are we trying to achieve? Get RELIANCE’s close on a specific date (e.g. a purchase date).
Which tool?
get_ltp_by_date (NSE Bhavcopy) — The close price for a symbol on a given date (or the previous trading day). Returns a bare number.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_ltp_by_date",
"arguments": {
"symbol": "RELIANCE",
"date": "2026-01-01"
}
}
}
How to interpret the response
Use it in your app: Useful for “what is my holding worth vs the day I bought it” calculations — parse the text as a number.
What are we trying to achieve? End-of-day OHLC and % change for a whole watchlist.
Which tool?
get_bulk_quote (NSE Bhavcopy) — Latest end-of-day OHLC, % change and volume for up to 50 symbols in one call.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_bulk_quote",
"arguments": {
"symbols": [
"RELIANCE",
"TCS",
"INFY",
"HDFCBANK",
"ICICIBANK",
"SBIN"
]
}
}
}
How to interpret the response
Use it in your app: Prefer this over N separate calls for daily summaries or portfolio valuation.
What are we trying to achieve? Rank the NIFTY 50 constituents by today’s % change.
Which tool?
nse_get_market_movers (CM Market Live) — The primary “who is moving today” tool: sorted top N gainers and losers across all securities or one index.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "nse_get_market_movers",
"arguments": {
"indexName": "NIFTY",
"limit": 10
}
}
}
How to interpret the response
Use it in your app: Poll every 5 minutes at most — that is how often NSE refreshes this cache.
What are we trying to achieve? Find the top losers for a historical session and avoid misreading splits/bonuses as crashes.
Which tool?
get_top_movers (NSE Bhavcopy) — Top N gainers (“gain”) or losers (“loss”) for any trading day in the last 5 years.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_top_movers",
"arguments": {
"date": "LAST_TRADING_DAY",
"n": 10,
"direction": "loss"
}
}
}
How to interpret the response
Use it in your app: For each loser below −20%, call get_corporate_actions(symbol, date, date) and label confirmed events instead of showing them as losses.
What are we trying to achieve? Which stocks saw the most money change hands in the last session?
Which tool?
get_top_by_volume (NSE Bhavcopy) — Top N stocks by traded quantity (“volume”) or turnover (“value”) for a date.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_top_by_volume",
"arguments": {
"date": "LAST_TRADING_DAY",
"n": 15,
"sortBy": "value"
}
}
}
How to interpret the response
Use it in your app: Show both rankings side by side — the difference is itself informative.
What are we trying to achieve? Compare INFY’s recent volume with its 30-day average.
Which tool?
get_volume_analysis (NSE Bhavcopy) — Average/max/min volume over N days, spike days (>2× average) and the last 5 sessions vs average.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_volume_analysis",
"arguments": {
"symbol": "INFY",
"days": 30
}
}
}
How to interpret the response
Use it in your app: Combine with nse_get_market_movers to flag movers on unusual volume — see “Unusual volume” on the Insights page.
What are we trying to achieve? Is HINDALCO trading above its 50-day SMA?
Which tools?
moving_average (NSE Bhavcopy) — SMA of closing prices over the last N trading days. Returns a bare number.cm_get_stock_quote (CM Market Live) — Near-real-time quote for one exact symbol: LTP, OHLC, change, volume, 52-week range and 30-day change.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "moving_average",
"arguments": {
"symbol": "HINDALCO",
"days": 50
}
}
}
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "cm_get_stock_quote",
"arguments": {
"symbol": "HINDALCO"
}
}
}
How to interpret the response
Use it in your app: For a full SMA/EMA/RSI series, fetch history and compute locally (shared/analytics.ts) — the Insights page shows how.
What are we trying to achieve? How far is TCS from its 52-week high and low?
Which tool?
get_52_week_high_low (NSE Bhavcopy) — 52-week extremes with dates, and where the last close sits inside that range.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_52_week_high_low",
"arguments": {
"symbol": "TCS"
}
}
}
How to interpret the response
Use it in your app: Great for screeners: call for a list of symbols and sort by position_in_range_pct.
What are we trying to achieve? Rank TCS, INFY, WIPRO and HCLTECH by return and drawdown.
Which tool?
compare_stocks (NSE Bhavcopy) — Return % and max drawdown for up to 10 symbols over 1–24 months, ranked best to worst.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "compare_stocks",
"arguments": {
"symbols": [
"TCS",
"INFY",
"WIPRO",
"HCLTECH"
],
"months": 6
}
}
}
How to interpret the response
Use it in your app: Up to 10 symbols and 1–24 months per call. Check corporate actions for each symbol if a result looks extreme.
What are we trying to achieve? List corporate actions for RELIANCE over the last 5 years.
Which tool?
get_corporate_actions (NSE Bhavcopy) — Splits, bonuses, dividends and other events with ex-dates and a price adjustment factor.Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "get_corporate_actions",
"arguments": {
"symbol": "RELIANCE",
"fromDate": "",
"toDate": ""
}
}
}
How to interpret the response
Use it in your app: Apply the factors to get_stock_history output to build an adjusted price series — shared/analytics.ts has adjustForCorporateActions().
What are we trying to achieve? List live prices for SME-segment stocks.
Which tool?
cm_get_sme_stocks (CM Market Live) — Live data for SME platform stocks (series SM, ST).Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "cm_get_sme_stocks",
"arguments": {
"limit": 25,
"symbolFilter": ""
}
}
}
How to interpret the response
Use it in your app: symbolFilter is a prefix match; limit is capped at 500.
What are we trying to achieve? See the non-equity instruments traded in the CM segment.
Which tool?
cm_get_bond_stocks (CM Market Live) — Everything that is not equity/SME/call-auction: bonds, G-secs, SGBs, InvITs/REITs, T-bills…Request (JSON-RPC tools/call):
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "cm_get_bond_stocks",
"arguments": {
"limit": 25,
"symbolFilter": "SGB"
}
}
}
How to interpret the response
Use it in your app: Use the series column to group instruments by type.
These live in server/src/analytics/recipes.ts and are exposed at /api/recipes/*.
| Recipe | Tools composed | Analytics added | API |
|---|---|---|---|
| Stock deep dive | cm_get_stock_quote, get_corporate_actions, get_52_week_high_low, chained get_stock_history |
split/bonus back-adjustment, SMA 20/50, EMA 20, RSI 14, volatility, drawdown, gap detection | GET /api/recipes/deep-dive?symbol=RELIANCE&months=6 |
| Movers × unusual volume | nse_get_market_movers + get_volume_analysis per mover |
relative volume and session-pace projection | GET /api/recipes/unusual-volume?index=NIFTY&limit=10 |
| Breadth trend | get_market_breadth for each recent weekday |
holiday de-duplication, sentiment label | GET /api/recipes/breadth?days=10 |
| Peer comparison | compare_stocks, get_bulk_quote, get_corporate_actions per symbol |
flags splits/bonuses inside the window | GET /api/recipes/peers?symbols=TCS,INFY&months=6 |
Verified live on 2026-10-06: a 24-month RELIANCE deep dive found a raw −49.76% “crash” on 2024-10-28,
matched it to the 1:1 bonus (factor 0.5) from get_corporate_actions, and produced a continuous adjusted series.
With ANTHROPIC_API_KEY set, the AI agent demo page sends your question to Claude together with all 26 tool
definitions from tools/list. Claude decides which NSE tools to call; the backend executes them over MCP and
returns the results until Claude answers. Try: “Show me today’s top gainers with unusually high volume.”