MCP server
Let an AI assistant read the Finance APIs for you. The server speaks the Model Context Protocol, so Claude, Cursor and other MCP clients can look up schemes, NAV history, returns, holdings and industry flows, and the newest market session, in a conversation.
Two sets of tools, one connection:
mf_ tools for the Mutual Fund API and market_ tools for the Market Data API.Endpoint https://fin.ejiapi.com/mcp (Streamable HTTP). It uses your own API key, the same one as the REST API, so it counts against your own quota. Request a key if you do not have one.
Connect
claude mcp add --transport http mf-api https://fin.ejiapi.com/mcp \ --header "x-api-key: YOUR_KEY"
{
"mcpServers": {
"mf-api": {
"url": "https://fin.ejiapi.com/mcp",
"headers": { "x-api-key": "YOUR_KEY" }
}
}
}
{
"mcpServers": {
"mf-api": {
"command": "npx",
"args": ["-y", "mcp-remote", "https://fin.ejiapi.com/mcp",
"--header", "x-api-key:${MF_API_KEY}"],
"env": { "MF_API_KEY": "YOUR_KEY" }
}
}
}
Claude Desktop reaches remote servers through the
mcp-remote helper, which needs Node.js. Keep your key out of shared config files and repositories.Mutual fund tools
All tools are read-only. Start with mf_search_schemes to get a scheme code, then use it in the others.
| Tool | What it does |
|---|---|
mf_search_schemes | Find schemes by words of the name. |
mf_get_scheme | One scheme by code or ISIN: latest NAV and 52-week high and low. |
mf_list_schemes | Browse schemes a page at a time, optionally by category. |
mf_list_amcs | All fund houses with their scheme counts. |
mf_list_amc_schemes | Schemes of one fund house, by id or name. |
mf_get_variants | Plan and option variants of an exact scheme name. |
mf_get_nav_history | Daily NAV over a date range. Long ranges are thinned to about max_points points. |
mf_get_returns | 1, 3, 5 and 10 year annualised returns (CAGR). |
mf_compare_schemes | Two to five schemes side by side. |
mf_get_holdings | Month-end portfolio disclosures: largest positions, sectors and weights. |
mf_get_industry_flows | AMFI monthly report by fund category: folios, money raised and redeemed, net inflow and AUM, from March 2020. |
mf_get_category_flow_history | One category month by month, for example Flexi Cap or Liquid funds. |
mf_get_status | How fresh the data is and which fund houses have holdings. |
Market data tools
Also read-only, end of day. Dates are YYYY-MM-DD. Start with market_get_coverage to see the newest session held.
| Tool | What it does |
|---|---|
market_get_coverage | What is stored, from and to which date, and when each loader last ran. |
market_get_indices | NSE indices for a session with close, change, P/E, P/B and yield; filter by name. |
market_get_index_history | One index over time. Long ranges are thinned to about max_points. |
market_get_movers | Stocks ranked by change, delivery %, turnover or volume. |
market_get_equity_history | One stock's daily prices, volume and delivery %. |
market_get_flows | FII/FPI and DII cash-market buy, sell and net. |
market_get_participant_oi | Open interest by Client, DII, FII and Pro. |
market_get_deals | Bulk and block deals. |
market_get_futures | Futures per expiry: settlement, open interest, lot size. |
market_get_options_summary | Call and put open interest and put/call ratio per underlying and expiry. |
market_get_corporate_actions | Dividends, splits, bonus, rights and buybacks by ex-date. |
market_get_events | Board meetings and results dates. |
market_get_ipos | IPOs with price band, subscription and listing date. |
market_get_fx | Rupee value of 14 currencies (ECB reference rates). |
Example questions
- "Compare the 3 and 5 year returns of Parag Parikh Flexi Cap and the top two flexi cap funds from other houses."
- "What were the ten largest holdings of scheme 122639 last month, and how did the IT sector weight change over three months?"
- "Show the NAV of this ISIN since January 2024."
- "Which equity fund categories had the biggest net inflows last month, and how does that compare with six months ago?"
- "What is the Nifty 50 P/E today against its level three months ago, and which stocks had the highest delivery percentage yesterday?"
- "Which companies go ex-dividend next week, and what is the dividend per share?"
Keys and limits
- The server holds no key of its own. Each request uses the
x-api-keyheader your client sends, so the limits and monthly quota of your key apply, and every tool call is one API request. - Market data is end of day. FII/DII flows and bulk and block deals only go back to the day the service first stored them, and options are kept as per-expiry totals. Holdings exist for open-ended equity and hybrid funds of the fund houses listed on the Mutual Fund status page. For any other scheme
mf_get_holdingsanswers that none are stored. - Returns are computed from stored NAV history and are shown as null where the history is too short.
- Nothing here is investment advice.