Com APInepalstock.com.np ↗
Access real-time NEPSE indices, stock prices, market summaries, top performers, and historical OHLC data for all securities listed on Nepal's stock exchange.
What is the Com API?
This API exposes 7 endpoints covering Nepal Stock Exchange (NEPSE) market data, from live index values to per-security OHLC details. Use get_nepse_index to retrieve current values, percentage changes, and 52-week lows across four major NEPSE indices, or call get_today_prices to pull closing prices, volumes, and percentage changes for every security traded on a given day.
No input parameters required.
curl -X GET 'https://api.parse.bot/scraper/200a3fbe-2c84-436d-8f67-6c08621de86e/get_nepse_index' \ -H 'X-API-Key: $PARSE_API_KEY'
Typed, relational, agent-ready
A generated client with real types, enums, and the links between objects — the structure a flat JSON response can't carry. Autocompletes in your editor and reads cleanly to coding agents.
- Fully typed · autocompletes
- Objects link to objects
- Typed errors & pagination
Typed Python client. Set up the SDK in your uv project, then pull this API’s typed client:
uv add parse-sdk uv run parse init uv run parse add --marketplace nepalstock-com-np-api
uv run parse add --marketplace pulls a pinned snapshot of this canonical API — it won’t change underneath you. To customize it, subscribe and swap to your own copy.
from parse_apis.nepse_nepal_stock_exchange_api import Nepse, Index, Security, StockDetail, DailyPrice, Metric, Performer, IndexHistory, PerformanceType, IndexId
nepse = Nepse()
# List all NEPSE indices
for index in nepse.indexes.list():
print(index.name, index.current_value, index.percentage_change)
# Get top gainers
for performer in nepse.performers.list(type=PerformanceType.GAINER):
print(performer.symbol, performer.ltp, performer.point_change)
# Search for securities and navigate to detail
for security in nepse.securities.search(query="Bank"):
detail = security.details()
print(detail.security_data.symbol, detail.security_data.sector, detail.trading_data.close_price)
# Get index history via sub-resource navigation
nepse_index = nepse.index(id=58)
for entry in nepse_index.histories.list(limit=5):
print(entry.business_date, entry.closing_index, entry.abs_change)
# Get today's prices
for price in nepse.dailyprices.list(limit=3):
print(price.symbol, price.last_traded_price, price.percentage_change)
# Get market summary metrics
for metric in nepse.metrics.list():
print(metric.detail, metric.value)
Get current values and changes for various NEPSE indices including NEPSE Index, Sensitive Index, Float Index, and Sensitive Float Index. Returns all four indices with their current value, day range, 52-week range, and percentage change.
No input parameters required.
{
"type": "object",
"fields": {
"items": "array of Index objects with id, index name, currentValue, close, high, low, change, perChange, previousClose, fiftyTwoWeekLow, fiftyTwoWeekHigh"
},
"sample": {
"data": {
"items": [
{
"id": 58,
"low": 2722.67,
"high": 2744.18,
"close": 2733.6,
"index": "NEPSE Index",
"change": 2.57,
"perChange": 0.09,
"currentValue": 2736.17,
"previousClose": 2736.18,
"fiftyTwoWeekLow": 2487.18,
"fiftyTwoWeekHigh": 3002.08
}
]
},
"status": "success"
}
}About the Com API
Market Indices and Daily Prices
get_nepse_index returns live data for the NEPSE Index, Sensitive Index, Float Index, and Sensitive Float Index. Each entry includes currentValue, change, perChange, previousClose, high, low, and fiftyTwoWeekLow. get_today_prices returns a flat list of all securities traded on the main NEPSE board (index ID 58), with fields like symbol, closePrice, lastTradedPrice, percentageChange, and totalTradeQuantity per security.
Stock Search and Detail
search_stocks accepts an optional query parameter for case-insensitive partial matching against symbol or company name. It returns id, symbol, securityName, and activeStatus — useful for resolving a ticker before passing it to get_stock_detail. That endpoint accepts either a symbol string (e.g., NABIL) or a numeric security ID and returns two nested objects: securityData (sector, email, active status) and securityMcsData (open, high, low, close, previous close, last traded price, total trade quantity).
Market Summary and Top Performers
get_market_summary returns key market-wide metrics as value/detail pairs covering total turnover, traded shares, transactions, scrips traded, and market capitalization. get_top_performers ranks up to 10 securities by one of five criteria: gainer, loser, turnover, volume, or transaction. Each result includes ltp, pointChange, percentageChange, symbol, and securityName.
Historical Index Data
get_index_history returns paginated daily OHLC data for a chosen index. Supported index IDs are 58 (NEPSE), 57 (Sensitive), 62 (Float), and 63 (Sensitive Float). Each page contains up to 20 records ordered most-recent first, with businessDate, closingIndex, openIndex, highIndex, lowIndex, turnoverValue, and turnoverVol. The response also includes totalPages and totalElements so clients can paginate through the full history.
The Com API is a managed, monitored endpoint for nepalstock.com.np — not a raw scraper you maintain. Every endpoint is automatically health-checked on a schedule, and when nepalstock.com.np changes and a check fails, the API is automatically queued for repair and re-verified. It is built to keep working as the site underneath it changes.
This isn't an official nepalstock.com.np API — it's an independent, maintained REST wrapper over public data. Where the source has no official API (or only a limited one), Parse gives you a stable contract over a source that never promised one, and keeps it current. Need a new endpoint or field? You can revise it yourself in plain English and the agent rebuilds it against the live site in minutes — contributing the change back to the shared API is free.
Will this API break when the source site changes?+
Is this an official API from the source site?+
Can I fix or extend this API myself if I need a new endpoint or field?+
What happens if I call an endpoint that has an issue?+
- Display a live NEPSE dashboard showing current index values and percentage changes for all four major indices.
- Screen all traded securities by percentage change or volume using get_today_prices to identify movers at market close.
- Build a stock lookup tool that resolves partial company names or symbols via search_stocks before fetching OHLC detail.
- Track NEPSE market capitalization and total turnover over time using get_market_summary on a daily schedule.
- Populate a top-gainers and top-losers widget using get_top_performers with the gainer and loser type parameters.
- Plot historical index performance charts by paginating through get_index_history for the NEPSE or Sensitive Index.
- Alert users when a specific security's percentageChange crosses a threshold by monitoring get_today_prices output.
| Tier | Price | Credits/month | Rate limit |
|---|---|---|---|
| Free | $0/mo | 100 | 5 req/min |
| Hobby | $30/mo | 1,000 | 20 req/min |
| Developer | $100/mo | 5,000 | 100 req/min |
One credit = one API call regardless of which marketplace API you call. Exceeding the rate limit returns a 429 response. Authenticate with the X-API-Key header.
Does Nepal Stock Exchange (nepalstock.com.np) offer an official developer API?+
What does get_top_performers return and how is the type parameter used?+
type parameter accepts one of five values: gainer, loser, turnover, volume, or transaction. Each result includes symbol, securityName, ltp, pointChange, and percentageChange. If no type is supplied, the default ranking is applied.How is pagination handled in get_index_history?+
totalPages and totalElements so you can determine how many additional requests are needed to retrieve the full history for a given index ID.