Metadata-Version: 2.4
Name: tradingview-mcp
Version: 26.3.1
Summary: A comprehensive MCP server for TradingView market screening with integrated screener functionality
Project-URL: Homepage, https://github.com/k73a/tradingview-mcp
Project-URL: Documentation, https://github.com/k73a/tradingview-mcp#readme
Project-URL: Repository, https://github.com/k73a/tradingview-mcp
Project-URL: Issues, https://github.com/k73a/tradingview-mcp/issues
Project-URL: Changelog, https://github.com/k73a/tradingview-mcp/blob/main/CHANGELOG.md
Author: TradingView MCP Team
License: MIT
License-File: LICENSE
Keywords: crypto,mcp,model-context-protocol,screener,stocks,technical-analysis,trading,tradingview
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.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Office/Business :: Financial :: Investment
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.10
Requires-Dist: httpx>=0.24.0
Requires-Dist: mcp>=1.0.0
Requires-Dist: pandas>=2.0.0
Requires-Dist: requests>=2.28.0
Provides-Extra: dev
Requires-Dist: pyright>=1.1.0; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.21.0; extra == 'dev'
Requires-Dist: pytest-cov>=4.0.0; extra == 'dev'
Requires-Dist: pytest>=7.0.0; extra == 'dev'
Requires-Dist: ruff>=0.1.0; extra == 'dev'
Description-Content-Type: text/markdown

# TradingView MCP Server

[![PyPI version](https://badge.fury.io/py/tradingview-mcp.svg)](https://badge.fury.io/py/tradingview-mcp)
[![Python](https://img.shields.io/pypi/pyversions/tradingview-mcp.svg)](https://pypi.org/project/tradingview-mcp/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

MCP server for TradingView market screening. Supports stocks, crypto, forex, futures, bonds across 76+ markets.

## Quick Start
```json
{
  "mcpServers": {
    "tradingview": {
      "command": "uvx",
      "args": ["tradingview-mcp"]
    }
  }
}
```

## Smart Features

- **Auto-Market Detection**: If you search for `EURUSD` or `BTCUSDT`, the server automatically checks Forex and Crypto markets if not found in stocks.
- **Strict Exchange Support**: Use `EXCHANGE:SYMBOL` format (e.g., `BINANCE:BTCUSDT`, `FX:EURUSD`) to target specific markets.
- **Smart Filters**: You can use human-readable names in filters (e.g., `"Relative Strength Index (14)"` instead of `"RSI"`).

## Main Tools

| Tool | Description |
|------|-------------|
| `screen_market` | Custom market screening with filters |
| `get_top_gainers` | Top gaining assets |
| `get_top_losers` | Top losing assets |
| `get_most_active` | Most traded by volume |
| `search_symbols` | Search by company name |
| `get_symbol_info` | Detailed symbol info |
| `advanced_query` | Complex queries with AND/OR logic |

### Technical Analysis

| Tool | Description |
|------|-------------|
| `get_technical_analysis` | Full technical analysis |
| `scan_rsi_extremes` | RSI overbought/oversold |
| `scan_macd_crossover` | MACD crossover detection |
| `scan_bollinger_bands` | Bollinger Band squeeze |
| `scan_volume_breakout` | Volume breakout detection |

### Reference Tools

| Tool | Description |
|------|-------------|
| `ai_get_reference` | Quick reference for markets/columns/filters |
| `search_available_fields` | Search for fields by name |
| `get_field_info` | Get field display name and type |
| `list_fields_for_market` | List fields for a market |
| `get_screener_preset` | Get predefined screener presets |

## Reference Resources

These resources provide raw lists of available markets and fields for reference.

| Resource | Description |
|----------|-------------|
| `markets://list` | All available markets |
| `columns://list` | Available columns/fields |
| `docs://ai-reference` | AI quick reference |
| `docs://fields` | Field display names |

## Markets

- **Stocks**: america, uk, germany, japan, china, etc. (68 countries)
- **Crypto**: crypto (pairs), coin (individual coins)
- **Others**: forex, futures, bonds, cfd, options

## Installation

```bash
# Using uvx (recommended)
uvx tradingview-mcp

# Using pip
pip install tradingview-mcp

# From source
git clone https://github.com/k73a/tradingview-mcp.git
cd tradingview-mcp
uv sync
```

## Running

```bash
# Stdio (default)
tradingview-mcp

# HTTP
tradingview-mcp streamable-http --host 127.0.0.1 --port 8000
```

## Development

```bash
uv sync --all-extras
uv run pytest tests/ -v
uv run ruff format .
uv run ruff check . --fix
```

## License

MIT License
