authenticateLABSCO SUMMARY
Portfolio questions and order entry in the same conversation.
The account, the quotes and the order book are all readable, and orders can be placed, changed and pulled - so the research and the execution happen in one place rather than two.
What it is
A server over Fyers API v3 covering the whole trading loop: authentication, portfolio, market data and orders. The OAuth flow opens a browser once and the token is written back to your .env, so later sessions do not repeat it.
What you get
- Holdings, positions, funds and profile read from the account
- Real-time quotes for several symbols in one call
- Orders placed, modified and cancelled
- The order book and trade history
- Authentication status checked on its own, so a stale session is diagnosed rather than guessed at
Requirements
Python 3.10 or newer, a Fyers trading account with API access, and an app created in the Fyers API dashboard with its redirect URI pointed at a local address. The app's client id, secret and that redirect URI go in a .env file, and the first run opens a browser to authorise. Orders placed through it are real orders on a live account - read back what a call is about to do before you confirm it.
Setup effort
Build from source — git clone https://github.com/quantabox/fyers-mcp-server.git
USE CASES
Checking where the account stands
Read holdings, positions and available funds in one pass, before deciding anything.
Pricing a trade before you place it
Pull quotes for the symbols you are weighing, then place the order in the same conversation.
Adjusting an order that has not filled
Read the order book, then change the price or cancel it outright.
Finding out why nothing is working
Check the auth status first - an expired session looks exactly like an API failure until you do.
11 tools
Listed in project docs. Your client may show a different list.
check_auth_statusget_profileget_fundsget_holdingsget_positionsplace_ordermodify_ordercancel_orderget_ordersget_quotesBEFORE YOU INSTALL
What to know first
Tools you get
11 tools named in the project's documentation.
Requires
- Python 3.10 or higher
- FYERS_CLIENT_ID in your environment
- FYERS_SECRET_KEY in your environment
Where it runs
The documented client runs the server on your machine.
INSTALLATION
Connect your client
Server setup
# Clone the repository
git clone https://github.com/quantabox/fyers-mcp-server.git
cd fyers-mcp-server
# Install dependencies using uv (recommended)
curl -LsSf https://astral.sh/uv/install.sh | sh
uv sync
# Or install with pip
pip install .MCP Clients
Claude Desktop
{
"mcpServers": {
"fyers-mcp-server": {
"command": "uv",
"args": [
"run",
"--directory",
"<YOUR_PATH_TO_FYERS_MCP_SERVER>",
"python",
"fyers_mcp_complete.py"
],
"env": {
"PYTHONWARNINGS": "ignore"
}
}
}
}The configuration on this page does not set FYERS_CLIENT_ID and FYERS_SECRET_KEY; the project's instructions put them in a .env file. To supply them without depending on where the server looks for that file, use the block's "env" section.