Metadata-Version: 2.4
Name: oxford-ledge-mcp
Version: 2.0.1
Summary: MCP server for Oxford Ledge financial terminal — 36 tools for stocks, SEC filings, credit data, bonds, macro indicators, and BDC holdings from Claude Desktop
Author-email: Oxford Ledge <contact@oxfordledge.com>
License: MIT
Project-URL: Homepage, https://www.oxfordledge.com
Project-URL: Repository, https://github.com/hs902/OxfordLedge
Project-URL: Documentation, https://www.oxfordledge.com/llm-guide
Keywords: mcp,finance,stocks,sec,edgar,bonds,bdc,credit,claude,anthropic
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Financial and Insurance Industry
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Office/Business :: Financial
Classifier: Topic :: Software Development :: Libraries
Requires-Python: >=3.9
Description-Content-Type: text/markdown
Provides-Extra: mcp
Requires-Dist: mcp>=1.0.0; extra == "mcp"

> **Last Updated:** 2026-04-24 ET — 2.0.0 architecture refactor

# Oxford Ledge MCP Server

Financial data tools for [Claude Desktop](https://claude.ai/download) via the [Model Context Protocol](https://modelcontextprotocol.io/).

36 tools for stocks, SEC filings, bonds, credit data, BDC holdings, macro indicators, and more. Works standalone with free public data or connects to your Oxford Ledge instance for the full suite.

**Upgrading from 1.x?** 2.0 is an internal architecture refactor — tool names, argument schemas, and output shapes are unchanged, and your Claude Desktop config stays the same. See [MIGRATING.md](./MIGRATING.md) for details. Under the hood, 2.0 extracts the shared tool registry (`@mcp_tool` decorator, cache, error class) into a new `oxford_ledge_mcp_core` subpackage that both the pip-installable server and Oxford Ledge's in-tree server consume — eliminates drift between the two.

## Install

```bash
pip install oxford-ledge-mcp
```

## Claude Desktop Setup

Add to your `claude_desktop_config.json`:

```json
{
  "mcpServers": {
    "oxford-ledge": {
      "command": "oxford-ledge-mcp"
    }
  }
}
```

Restart Claude Desktop. You'll see 36 financial tools available.

### API Mode (recommended)

For all 36 tools, connect to a running Oxford Ledge instance:

```json
{
  "mcpServers": {
    "oxford-ledge": {
      "command": "oxford-ledge-mcp",
      "env": {
        "OXFORD_LEDGE_URL": "https://www.oxfordledge.com"
      }
    }
  }
}
```

### Environment Variables

| Variable | Description |
|----------|-------------|
| `OXFORD_LEDGE_URL` | Oxford Ledge API URL (enables all 36 tools) |
| `FRED_API_KEY` | FRED API key for yield curve and economic data |

## Available Tools

### Standalone Tools (18 tools, no server needed)

| Tool | Description |
|------|-------------|
| `get_stock_quote` | Current price, P/E, EV/EBITDA, market cap, beta |
| `get_financials` | Income statement (revenue, net income, EBITDA) |
| `get_balance_sheet` | Assets, liabilities, equity, debt, cash |
| `get_cash_flow` | Operating, investing, financing cash flows, FCF |
| `get_analyst_recommendations` | Buy/hold/sell counts, price targets |
| `get_holders` | Top institutional shareholders |
| `get_company_info` | Sector, industry, employees, description |
| `compare_stocks` | Side-by-side comparison of 2-5 stocks |
| `get_sec_filings` | Recent 10-K, 10-Q, 8-K filings from EDGAR |
| `get_insider_trades` | Recent insider buy/sell transactions |
| `get_options_chain` | Calls and puts with expiry filtering |
| `screen_stocks` | Filter by sector, market cap, P/E, dividend yield |
| `get_fundamentals` | 10-year XBRL financials from SEC EDGAR |
| `search_bonds` | Search bond issuers via FINRA TRACE |
| `get_bond_data` | Look up bonds by CUSIP |
| `get_yield_curve` | Treasury yield curve from FRED |
| `get_fred_data` | Any FRED series (GDP, UNRATE, CPI, etc.) |
| `get_short_interest` | Short percent of float, days to cover |

### API-Mode Tools (18 additional tools, require OXFORD_LEDGE_URL)

| Tool | Description |
|------|-------------|
| `get_company_data` | Full company data with valuation multiples |
| `search_company` | Fuzzy search by name, ticker, or industry |
| `get_company_profile` | Business description, CEO, founding year |
| `get_corporate_events` | M&A, executive changes, restructurings |
| `get_market_indicators` | S&P 500, VIX, Treasury yields, gold, oil |
| `search_bdc_borrower` | Search BDC portfolio holdings by borrower |
| `get_bdc_list` | All tracked BDCs with AUM and holdings |
| `calculate_intrinsic_value` | DCF, EPV, Graham fair value models |
| `get_anomaly_flags` | 15 automated red flag checks |
| `get_debt_maturities` | Maturity schedule from 10-K footnotes |
| `get_capital_allocation` | 10-year buyback/dividend/debt scorecard |
| `get_peer_comparison` | Peer valuation and financial metrics |
| `get_news` | News archive search with sentiment scores |
| `get_price_history` | OHLCV price history |
| `get_13f_holdings` | Institutional 13F holdings from EDGAR |
| `get_value_investing_fact` | Buffett/Graham/Munger quotes and principles |
| `get_valuation_history` | Historical P/E, EV/EBITDA, P/B, P/S |
| `get_economic_calendar` | FOMC, CPI, GDP, jobs report dates |

## Data Sources

- **yfinance** -- real-time quotes, financials, analyst data
- **SEC EDGAR** -- XBRL fundamentals, 10-K/10-Q/8-K filings
- **FINRA TRACE** -- corporate bond search and pricing
- **FRED** -- Treasury yields, economic indicators
- **Oxford Ledge API** -- BDC holdings, news archive, valuations (API mode)

## Full Terminal

For the complete experience with 45+ databases, news archive, credit analysis, BDC data, and AI-powered analysis, visit [www.oxfordledge.com](https://www.oxfordledge.com).

## Standalone Mode Data Source Notice

The 18 standalone tools (including `get_stock_quote`, `get_financials`, `get_short_interest`, etc.) rely on the open-source [`yfinance`](https://pypi.org/project/yfinance/) library, which retrieves data from Yahoo Finance. Yahoo Finance's Terms of Service restrict automated access and commercial redistribution of scraped data. Because `oxford-ledge-mcp` runs on **your local machine** (inside Claude Desktop), all such requests originate from your IP and are governed by Yahoo's ToS as they apply to you.

- Standalone mode is intended for **personal, educational, and research** use.
- If you plan to use this data commercially, redistribute it, or integrate it into a paid product, **review Yahoo Finance's Terms of Service first** and obtain appropriate licensing.
- For commercial or production workloads, we strongly recommend **API mode** (set `OXFORD_LEDGE_URL`), which routes requests through Oxford Ledge's licensed data providers (FMP, Finnhub, SEC EDGAR, FRED) rather than scraping.
- Oxford Ledge LLC is not responsible for end-user compliance with third-party data provider terms when using standalone mode.

Tools that use yfinance under the hood: `get_stock_quote`, `get_financials`, `get_balance_sheet`, `get_cash_flow`, `get_analyst_recommendations`, `get_holders`, `get_company_info`, `compare_stocks`, `get_insider_trades`, `get_options_chain`, `screen_stocks`, `get_short_interest`.

## License

MIT
