# TSETMC Tehran Stock Exchange

TSETMC Tehran Stock Exchange is an MCP server for Claude Code that reads quotes, movers, order books, history, and indices. It cannot place trades.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 10 repo stars
- Author: sepehr071
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/sepehr071/tsetmc-mcp
- Updated: 2026-11-17
- Security check: automated, 2026-11-17 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/mcp/tsetmc-tehran-stock-exchange

## What it does

TSETMC Tehran Stock Exchange gives an agent read access to Tehran Stock Exchange and Iran Fara Bourse market data. It can find shares, funds, rights issues, and bonds by ticker or name, then return quotes, market movers, order-book levels, daily history, and index data. Separate tools report trading by individual and legal investors.

This server is for market data, not trading: it does not log in or submit orders. Running it requires `uv` and Python 3.10+; no API key or account is needed. If TSETMC returns HTTP 403, `TSETMC_MCP_PROXY` can provide an HTTP proxy. Prices use Rial, volumes use shares, and dates use `YYYY-MM-DD`.

## Requirements
- Needs: Python and uv (commands run via uvx)
- Environment variables: `TSETMC_MCP_PROXY` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add --env TSETMC_MCP_PROXY=<TSETMC_MCP_PROXY> --transport stdio tsetmc-tehran-stock-exchange -- uvx tsetmc-mcp
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from tsetmc-mcp <command>

### Codex

**Platform CLI**
```bash
codex mcp add tsetmc-tehran-stock-exchange --env TSETMC_MCP_PROXY=<TSETMC_MCP_PROXY> -- uvx tsetmc-mcp
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from tsetmc-mcp <command>

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "tsetmc-tehran-stock-exchange": {
            "command": "uvx",
            "args": [
                "tsetmc-mcp"
            ],
            "env": {
                "TSETMC_MCP_PROXY": "<TSETMC_MCP_PROXY>"
            }
        }
    }
}
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from tsetmc-mcp <command>

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "tsetmc-tehran-stock-exchange": {
            "type": "stdio",
            "command": "uvx",
            "args": [
                "tsetmc-mcp"
            ],
            "env": {
                "TSETMC_MCP_PROXY": "<TSETMC_MCP_PROXY>"
            }
        }
    }
}
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from tsetmc-mcp <command>

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e TSETMC_MCP_PROXY=<TSETMC_MCP_PROXY> tsetmc-tehran-stock-exchange uvx tsetmc-mcp
```
Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from tsetmc-mcp <command>

## When to use it
- look up an instrument by ticker or name
- rank Bourse and Fara Bourse market movers
- inspect the best bid and ask levels
- retrieve daily trading history for an instrument
- track individual investor buying and selling

## Example prompts
- Show today’s strongest gainers on the Tehran Stock Exchange with their latest prices.
- Get the last 20 trading days for `وبملت` and check whether individual investors bought or sold during the last 3 days.
- Read the order book for `فولاد`, including the best buy and sell levels.

## Similar
- [Stock Price — Real-Time Quotes, US & International](https://affpapa.org/en/nevibecode/mcp/stock-price-real-time-quotes-us-international.md) — MCP server · 5293 installs
- [Conductor Relay Exchange](https://affpapa.org/en/nevibecode/mcp/conductor-relay-exchange.md) — MCP server · 2330 installs
- [stock-liquidity](https://affpapa.org/en/nevibecode/skills/stock-liquidity.md) — skill · 3600 installs
- [alphaear-stock](https://affpapa.org/en/nevibecode/skills/alphaear-stock.md) — skill · 1300 installs
- [Stock Screener](https://affpapa.org/en/nevibecode/mcp/stock-screener.md) — MCP server · ★ 424 repo stars

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
