API Reference

REST API for Indian company filings, insider trading, and market data

Base URL: https://xaro.ai — Auth: X-Api-Key: YOUR_KEY header on all endpoints except /health
Search
POST /full-text-search Keyword search with snippets AUTH
ParamTypeRequiredDescription
querystringYesSearch query. Supports FTS5: OR, quoted phrases, prefix*
tickerstringNoNSE symbol (e.g. RELIANCE)
typestringNoannual_report, quarterly_result, other
yearintegerNoFilter by filing year
quarterintegerNo1-4
sectorstringNoSector or industry name
pageintegerNoPage number (default: 1)
limitintegerNo1-100 (default: 20)
snippet_tokensintegerNo16-128 (default: 64)
curl -X POST https://xaro.ai/full-text-search \
  -H "X-Api-Key: YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query": "\"import duty\" OR \"customs duty\"", "sector": "Automobile and Auto Components", "limit": 5}'
POST /embeddings-search Semantic search via AI embeddings AUTH
ParamTypeRequiredDescription
querystringYesNatural language query
tickerstringNoNSE symbol filter
typestringNoFiling type filter
yearintegerNoYear filter
quarterintegerNo1-4
sectorstringNoSector or industry
topKintegerNo1-100 (default: 20)
curl -X POST https://xaro.ai/embeddings-search \
  -H "X-Api-Key: YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query": "companies affected by EV policy changes", "topK": 10}'
POST /multi-search Batch queries with company dedup AUTH

Run multiple FTS + semantic queries in one call. Results aggregated and ranked by company.

ParamTypeRequiredDescription
queriesarrayYesUp to 50 query objects. Each: query, type (fts|semantic), optional filters
topKintegerNoMax companies, 1-200 (default: 50)
min_matchesintegerNoMin query matches per company (default: 1)
curl -X POST https://xaro.ai/multi-search \
  -H "X-Api-Key: YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "queries": [
      {"query": "\"import duty\"", "type": "fts", "sector": "Automobile and Auto Components"},
      {"query": "trade policy impact on margins", "type": "semantic"}
    ],
    "topK": 20
  }'
Insider Trading
GET /insider-trades PIT/SAST disclosures AUTH

SEBI insider trading disclosures from NSE. Filter by ticker, transaction type, person category, date range, and minimum value.

ParamTypeDescription
tickerstringNSE symbol (e.g. RELIANCE)
transaction_typestringBuy, Sell, or Pledge
person_categorystringe.g. Promoters, Director, Key Managerial Personnel
fromstringStart date (YYYY-MM-DD)
tostringEnd date (YYYY-MM-DD)
min_valuenumberMin transaction value in INR
pageintegerPage number (default 1)
limitinteger1-100 (default 20)
curl "https://xaro.ai/insider-trades?ticker=RELIANCE&transaction_type=Buy" \
  -H "X-Api-Key: YOUR_KEY"
GET /insider-trades/top Largest trades by value AUTH

Returns the biggest insider trades ranked by transaction value. Filter by recency and transaction type.

ParamTypeDescription
daysintegerLookback in days (default 30, max 365)
transaction_typestringBuy, Sell, or Pledge
limitinteger1-100 (default 20)
curl "https://xaro.ai/insider-trades/top?days=90&transaction_type=Buy&limit=10" \
  -H "X-Api-Key: YOUR_KEY"
GET /insider-trades/summary Net insider buy/sell per company AUTH

Aggregated insider activity: total buy/sell value, share counts, unique insiders. Ranked by net buy-sell value.

ParamTypeDescription
tickerstringNSE symbol (optional, omit for all companies)
daysintegerLookback in days (default 90, max 365)
curl "https://xaro.ai/insider-trades/summary?days=90" \
  -H "X-Api-Key: YOUR_KEY"
Reference Data
GET /stats Corpus overview AUTH 1HR

Returns filing counts, company counts, breakdowns by sector, type, and year.

curl https://xaro.ai/stats -H "X-Api-Key: YOUR_KEY"
GET /companies/:ticker Company lookup AUTH

Returns company name, sector, industry, ISIN, filing counts by type.

curl https://xaro.ai/companies/INFY -H "X-Api-Key: YOUR_KEY"
GET /sectors All sectors with counts AUTH 24HR

All 22 NSE sectors with company and filing counts. Use these as sector filter values.

curl https://xaro.ai/sectors -H "X-Api-Key: YOUR_KEY"
GET /health Health check (no auth)
curl https://xaro.ai/health
# {"status":"ok"}