yfinance trader.com
yfinance trader.com logo

YFinance Trader

Provides real-time stock market data and trading capabilities using yfinance, offering tools for quotes, company informa...

Created byApr 23, 2025

YFinance Trader MCP Tool

An MCP (Model Context Protocol) tool that provides stock market data and trading capabilities using the yfinance library.

Features

  • Real-time stock quotes
  • Company information and financial metrics
  • Historical price data
  • Symbol search functionality
  • Insider transaction tracking

Setup

  1. Ensure you have Python 3.10 or higher installed
  1. Install dependencies:

Integration with Cursor

  1. In Cursor, go to Settings > MCP
  1. Click "+ Add New MCP Server"
  1. Fill in the form: - Name: "yfinance-trader" (or any name you prefer) - Command: `python3 /path/to/your/yfinance-trader/main.py`
Example command:
(Replace with your actual path to main.py)
  1. Click "Add" and restart Cursor if needed

Available Tools

1. get_stock_quote

Get real-time stock quote information:

2. get_company_overview

Get company information and key metrics:

3. get_time_series_daily

Get historical daily price data:

4. search_symbol

Search for stocks and other securities:

5. get_recommendations

Get analyst recommendations for a stock:

6. get_insider_transactions

Get insider trading information:

Error Handling

All tools include proper error handling and will return an error message if something goes wrong:

Troubleshooting

If the MCP server is not working in Cursor:
  1. Verify the path in your settings is correct and absolute
  1. Make sure Python 3.10+ is in your system PATH
  1. Check that all dependencies are installed
  1. Try restarting Cursor
  1. Check Cursor's logs for any error messages

License

MIT License