Skip to content
Data & third-party APIs

Data & third-party APIs

Exactly where every number comes from, and how we use it.

17 sections · Educational and screening only — the app places no orders

Overview

Algo Py stores no market data of its own. It reads from a few public third-party endpoints — no account or API key required — caches the answers for a few minutes, and renders them. On a typical page load the app makes zero live calls (results are precomputed and cached); charts fetch on demand when you open one.

The sample responses below are illustrative (shortened, with example values) to show the shape of the data — they are not live output.

Upstox — historical candles (OHLC)

Used for: the Earnings Insight Tracker, Stage 2 Earnings Breakout, Trend Titans, Pullback Pro, Coil Hunter, Gap & Go, ETF Theme Rotation, the Drawdown Radar, Phoenix Radar and the IPO Breakout screen — every price candle behind them: the charts, the moving averages, breakouts and levels. Auth: none (public candle endpoint). Adjustments: NSE history is split/bonus-adjusted; BSE history is not, which is why dual-listed stocks are analysed on their NSE series.

GET Endpoint
api.upstox.com/v3/historical-candle/{instrument_key}/{unit}/{interval}/{to_date}/{from_date}
Sample response
{
  "status": "success",
  "data": {
    "candles": [
      ["2026-07-10T00:00:00+05:30", 278.0, 278.95, 267.3, 275.8, 2969311, 0]
      // [ timestamp, open, high, low, close, volume, open_interest ] — newest first
    ]
  }
}

Moneycontrol — earnings calendar, market cap, movers & most active

Used for: which companies report results on a given day, each company's market capitalisation, today's top gainers & losers, and the most active stocks by turnover and volume on NSE and BSE. Auth: none (browser-style headers). Earnings are fetched one day at a time and paged through fully so busy days are not silently truncated; the movers and most-active lists are read live from Moneycontrol's public market-stats pages and cached ~15 minutes. Moneycontrol is used (rather than the exchanges' own APIs or Yahoo) because it is reachable from a server and covers both exchanges.

GET Endpoint
api.moneycontrol.com/mcapi/v1/earnings/get-earnings-data?indexId=All&page=1&startDate=2026-07-11&endDate=2026-07-11
Sample response
{
  "data": {
    "list": [
      {
        "companyName": "Example Industries Ltd",
        "nseId": "EXAMPLE", "bseId": "500000",
        "marketCap": 12345.67,          // in ₹ crore
        "resultDate": "11 Jul"
      }
    ]
  }
}

A third Moneycontrol host is also called: priceapi.moneycontrol.com, once per unresolved company, to map their internal id to the real NSE/BSE ticker. It covers names our own instrument master misses — new listings, and L&T-vs-LT style variants. If it fails we simply do not resolve that symbol; nothing is guessed.

Moneycontrol — the four fundamentals screens

Used for: Annual Alpha, Quarterly Alpha, the Enterprise Value Model and Ten Pillars — the screens that read a company's reported statements rather than its price. Auth: none. All four share one ISIN→id map and are rebuilt monthly; the price each one needs is joined fresh from the weekly quotes snapshot at serve time, so a page load makes no calls yet the P/E, target and call stay weekly-fresh.

Annual Alpha also reads Moneycontrol: each company's five-year yearly results (Basic EPS, consolidated where reported, with face value for split adjustment) from the financials feed, its bonus history for bonus adjustment, and its live price from the price feed. Each stock is mapped to Moneycontrol's internal id by ISIN (a self-verifying lookup — a symbol match can return the wrong company), and that map is refreshed monthly. The yearly-results snapshot is rebuilt monthly (annual EPS lands ~once a year), while the price is joined fresh from the weekly quotes snapshot at serve time — so a page load makes no calls, yet the P/E and target stay weekly-fresh.

Quarterly Alpha reads the same Moneycontrol source at the quarterly frequency: each company's last five quarters of Basic EPS (the "before extraordinary" figure, consolidated where reported) from the classic quarterly-results feed, plus the same face value, bonus history and live price. It reuses Annual Alpha's ISIN→id map, and — like Annual Alpha — the snapshot is rebuilt monthly while the price is joined fresh weekly at serve.

Enterprise Value Model reads a different Moneycontrol feed — the quarterly-earning ratios and balance-sheet APIs — for each company's five years of enterprise value, EV/EBITDA, long-term borrowings and equity capital (consolidated where reported, standalone otherwise). It reuses Annual Alpha's ISIN→id map and live price; the snapshot is rebuilt monthly while the price (and so the target and call) is joined fresh weekly at serve.

Ten Pillars reads the Moneycontrol quarterly-earning balance-sheet, cash-flow, ratios and profit-loss APIs for each company's statements, its promoter pledge % and sector P/E from Tickertape, and the live price — running ten fundamental checks into one Positive / Negative / Neutral scorecard. It reuses Annual Alpha's ISIN→id map; the snapshot is rebuilt monthly while the price (and the three price-based pillars) refresh with the weekly quotes at serve. Per-statement it takes whichever of consolidated / standalone is the most recently reported.

Yahoo Finance — gap-filling fallback

Used for: filling the occasional missing candle when the primary source is short a day. It is a fallback only — the primary source always wins, and every fallback bar passes an anti-fabrication check (a bar on a market holiday, or with zero volume, is rejected) so we never invent a candle.

GET Endpoint
query1.finance.yahoo.com/v8/finance/chart/EXAMPLE.NS?interval=1d&range=1y
Sample response
{
  "chart": { "result": [ {
    "timestamp": [ 1752... ],
    "indicators": { "quote": [ {
      "open": [278.0], "high": [278.95], "low": [267.3],
      "close": [275.8], "volume": [2969311]
    } ] }
  } ] }
}

NSE — F&O bhavcopy (options end-of-day)

Used for: the F&O Momentum Watchlist and the Bank Nifty Strike Radar. One file per day holds every contract's OHLC, strike, call/put, expiry, underlying price, open interest and volume — stock options for the watchlist, index options (Bank Nifty) for the Strike Radar. Auth: none (a browser-style header). Page loads never touch NSE — both are precomputed from this file each evening and served as a snapshot.

GET File
nsearchives.nseindia.com/content/fo/BhavCopy_NSE_FO_0_0_0_{YYYYMMDD}_F_0000.csv.zip
Sample row (one option contract)
FinInstrmTp=STO  TckrSymb=EXAMPLE  OptnTp=PE  StrkPric=500
XpryDt=2026-07-31  UndrlygPric=486.5
OpnPric=8.1  HghPric=17.4  LwPric=7.9  ClsPric=16.8   // premium doubled off its low
TtlTradgVol=42000  OpnIntrst=180000

NSE — bulk & block deals (who bought and sold, by name)

Used for: the Bulk & Block Deals page. One file per day lists every large disclosed trade with the client's name, quantity and price. Auth: none (a browser-style header). Page loads never touch NSE — each day's file is merged into a committed snapshot, because the file holds only the latest session.

Why this and not "FII activity per stock": daily FII/DII figures are published only as market-wide totals, so no source can tell you what FIIs bought in a specific stock today. Bulk/block deals are the only per-stock trades disclosed with a name — and that name may be a foreign fund, a mutual fund, an HNI or a proprietary desk.

GET File
nsearchives.nseindia.com/content/equities/{bulk,block}.csv
Sample row
Date,Symbol,Security Name,Client Name,Buy/Sell,Quantity Traded,Trade Price
17-JUL-2026,EXAMPLE,Example Industries Limited,SOME CAPITAL LLP,BUY,742500,30.43

Tickertape — shareholding pattern (the institutional stake)

Used for: the Shareholding Pattern page and the sector classification behind Coil Hunter's within-sector relative strength (which sector each stock belongs to). How much of each company FIIs, DIIs, promoters and the public own, quarter by quarter. Auth: none. One request per company, so it is fetched offline, rate-limited, and served as a snapshot — a page load never touches it. Companies are matched by ISIN, the same key used for market cap.

Companies file this once a quarter (and it can land ~45 days late), so it is the slowest datapoint here. It is a share of equity, not rupees, and a rising FII stake is not a buy signal.

Tickertape's fund endpoints also power Compare Funds: one monthly screener call over Tickertape's ~5,800-fund universe builds a directory of ~1,800 funds across every asset class — equity, debt, hybrid, gold/silver, international and other (growth plans) — with every ratio behind the scoring (returns, AUM, expense, alpha, beta, Sharpe, benchmark name, and for debt the yield), and a per-fund holdings call — made live only when you open a fund — gives its sector mix and, for debt and hybrid, its credit-rating split (which the credit-risk score is built from). Growth plans only.

BSE — corporate actions (dividends, splits, bonus, buybacks)

Used for: the Corporate Actions page, and by Gap & Go to screen out ex-split / ex-bonus / ex-rights days — a share that halves on a 1:1 bonus looks exactly like a giant gap, so those dates are vetoed and can never register as a real gap. Every dividend, stock split, bonus issue, rights issue, buyback and merger, with its ex-date, record date and payment date — straight from the exchange the companies file with. Auth: none. Fetched live and cached ~15 minutes: ex-dates move daily, and a stale calendar would show a “last day to buy” that has already passed.

A corporate action belongs to the company, not to one exchange, so a BSE filing applies to the NSE line of the same stock — we match them by ISIN. The dividend yield and the “buy by” date are our own calculations: the yield is the payout against the last close, and “buy by” is the last trading session before the ex-date (a plain “ex-date minus one day” lands on a weekend or holiday about a third of the time).

GET Endpoint
api.bseindia.com/BseIndiaAPI/api/DefaultData/w?ddlcategorys=E&strSearch=S&Fdate={from}&TDate={to}
Sample row
{
  "scrip_code": 500325,
  "short_name": "EXAMPLE",
  "Purpose": "Final Dividend - Rs. - 5.5000",
  "Ex_date": "10 Aug 2026",       // we derive: buy by 07 Aug (the Friday)
  "RD_Date": "11 Aug 2026",
  "payment_date": "20 Aug 2026"
}

Upstox — the trading-holiday calendar

Used for: the Market Holidays page, and — far more importantly — every date calculation on this site. When a screen says "15 sessions after the result" it means fifteen days the market was actually open, not fifteen days on a wall calendar. Auth: none.

It is also what lets a screen tell a missing candle apart from a closed market. A day with no price is normal on a holiday and a data problem on a trading day, and only the calendar knows which.

⚠️ It covers the current year only. Ask about any other year and the answer degrades to "weekends only", which over-counts trading days but never hides a session — safe for date arithmetic, and deliberately not trusted for calling a day's data missing. If the fetch fails entirely we fall back to weekends-only in memory and log it loudly, but never save that degraded answer.

GET Endpoint
api.upstox.com/v2/market/holidays

Upstox candles — the 52-week highs & lows

Used for: the 52-Week Highs & Lows page — each stock's highest and lowest close over the last 252 trading sessions, computed from the same daily candles every other screen here runs on. Auth: none.

It used to come from NSE's own published file, and that stopped working. nsearchives.nseindia.com publishes a single CSV covering the whole market, already adjusted for splits and bonuses — cheaper and more authoritative than computing it ourselves. But that host blocks datacenter IPs: first it killed the live version on our server, and from August 2026 it began timing out from the scheduled job too. So the extremes are now worked out from Upstox daily candles, which the job can reach.

The numbers still match. Upstox's NSE history is itself split- and bonus-adjusted, so a 1:10 split does not print a high ten times too large. A stock needs at least 200 sessions of history to have a real 52-week extreme at all; younger listings are left out rather than shown against a partial year.

Built in our scheduled job and committed, never on a page load. ⚠️ A run that comes back with too little data writes nothing — the previous good snapshot keeps serving, because a half-empty 52-week page reads as "these are the only stocks near their highs".

NSE publishes such a file; BSE has no equivalent. A 52-week extreme belongs to the company, so the BSE page shows the same figures for companies that are also BSE-listed (matched by ISIN) and says so on the page.

GET Endpoint
api.upstox.com/v3/historical-candle/{instrument_key}/days/1/{to_date}/{from_date}

The retired source, for the record: nsearchives.nseindia.com/content/CM_52_wk_High_low_{DDMMYYYY}.csv — still published, still correct, simply unreachable from a datacenter.

AMFI — mutual fund NAVs

Used for: the MF X-Ray. The Association of Mutual Funds in India publishes the daily NAV of every scheme in the country as one plain text file. Auth: none. ~1.6 MB, ~14,200 schemes, of which about 1,481 are the Growth Direct/Regular pairs the screen can actually compare.

Growth plans only. An IDCW (dividend-paying) plan pays money out, which moves its NAV base — ranking those alongside Growth plans returned a fund at “4.18×” that had simply paid out a lot. And about 324 rows publish NAV 0.0000: that is real data, not an error — a segregated (side-pocketed) portfolio holding defaulted debt. Those are skipped, never “fixed” to a number.

The history is distilled, not mirrored. AMFI's historical report runs to roughly 66 MB per quarter, so instead of storing it we keep one NAV per scheme per month for ten years. That is enough by construction — a SIP is monthly, a CAGR needs the endpoints rather than the path, and for volatility we measured it: monthly and daily rankings agree at ρ = +0.873 with identical medians.

The history file has a different column order from the daily file (name and ISIN swapped, the date in another position). Read with the wrong offsets it does not fail — it silently produces garbage — so the two have separate parsers, proved to agree on 8,575 of 8,575 overlapping dates.

GET Endpoint
www.amfiindia.com/spages/NAVAll.txt
Sample row
Scheme Code;ISIN Div Payout;ISIN Div Reinvest;Scheme Name;Net Asset Value;Date
119551;INF209K01YM2;-;Example Fund - Direct Plan - Growth;123.4567;17-Jul-2026

The sky — computed, not fetched

Used for: the Astro Almanac only. Where the Sun and Moon sat on a given date is settled astronomy, so it is calculated rather than looked up — from NASA's DE421 planetary ephemeris, using the Lahiri sidereal ayanamsa, cast at the 09:15 opening bell.

No API, and no network call at all when you load the page. The whole sky for 2001–2028 is computed offline and shipped with the app, so a page view is a lookup. The rules themselves are parsed from the book's own text, and the hit rates are measured against real Nifty candles from the sources above — we never use the book's own price tables: most of its 2007 rows print an opening price of 0, and one prints an open above its own high.

Our sky is checked against the book's: it prints the exact dates it says each rule fired on, and our engine reproduces 96% of those 6,432 observations. The rest are days the sky turned over mid-session.

NSE — the IPO list & listing dates

Used for: the IPO Breakout screen. NSE's own feed of past public issues lists every mainboard (EQ/BE) and SME IPO since 1 January 2021 with its exact listing date, issue price and board. That listing date is what pins each stock's first candle to its true listing session — so its high seeds the reference the whole screen is measured against. Auth: none (a browser-style header plus a homepage cookie). The price candles themselves come from Upstox (section 1).

Fetched offline and committed, never on a page load: like every other nseindia.com endpoint it blocks data-centre IPs, so the list is downloaded by our scheduled job (daily) and baked into a snapshot the site reads. NSE's listing date matches our candle's first bar exactly (cross-checked on Nykaa, Paytm and LIC).

GET Endpoint
www.nseindia.com/api/public-past-issues
Sample row
{
  "symbol": "EXAMPLE", "company": "Example Industries Ltd",
  "listingDate": "10-Nov-2024", "issuePrice": "120",
  "priceRange": "Rs.114 to Rs.120",
  "securityType": "EQ"     // EQ / BE = mainboard, SME = NSE Emerge
}

We keep a COPY of this data on our server — and why

Almost nothing here is fetched from the source while you wait. We download it on a schedule, save it, and serve you our saved copy. That is worth stating plainly, because it decides both how fresh the numbers are and why the site works at all.

Why we copy it instead of asking live:

  • Some sources refuse our server. NSE's archives answer a home connection and a build machine but block data-centre addresses — which is what our host is. The F&O bhavcopy, the bulk/block deal files, the 52-week file and the IPO list are downloaded by a scheduled job elsewhere and saved; a page load never touches NSE. We learned this the hard way: the 52-week page shipped as a live fetch and showed “could not reach NSE” to every visitor, while working perfectly on the developer's machine.
  • Some would be impossibly slow. Screening 1,432 companies' shareholding live would take minutes per page load; deriving every stock's 52-week high from raw candles would need ~7,500 requests.
  • It is kinder to the sources. One scheduled download a day, rather than one per visitor.

What that means for you: a number is only as fresh as its last build, so every screen prints when it was built, and a page whose data never arrived shows a notice instead of inventing figures. The live exceptions are the corporate-actions calendar (ex-dates move daily, and a stale one would print a “buy by” deadline that has already passed) and today's movers and most active.

The data is not ours. Prices, filings and fund NAVs belong to the exchanges and providers named above; we store and present them for analysis and education, and every source is credited here with the exact endpoint we call. Anything we derive — the distances, the yields, the buy-by dates, the verdicts — is our own calculation, and where a figure is derived rather than published we say so, because the two carry very different weight.

Nothing about you is stored. The copies above are of market data, not of you — no account and no record of what you screen.

Sharing — nothing leaves your browser

The Share button on every screener row builds its message in your browser and copies it to your clipboard. We do not send it anywhere, and we do not log it.

If you then pick WhatsApp, X, Telegram or email, your browser opens that service with the text pre-filled — at which point you are on their site under their privacy policy, exactly as if you had pasted it yourself. Nothing happens until you choose one.

How we keep it honest

  • One source of truth. The primary (Upstox) price wins; the fallback may only add a missing day, never overwrite one.
  • No fabricated candles. A day missing from every source stays missing.
  • Caching. Answers are cached ~15 minutes and rebuilt on a schedule, so the site is fast and gentle on the upstream services.
  • Provenance. When a chart uses fallback or has a gap, it says so in a small “data note”.

All of these services are owned by their respective providers; Algo Py is not affiliated with them and simply reads their public endpoints.