@chartobserver/mcp-server

@chartobserver/mcp-server

An MCP server that lets an AI agent read your portfolio, place paper trades, and check the leaderboard on your ChartObserver account.

Category
访问服务器

README

@chartobserver/mcp-server

An MCP (Model Context Protocol) server that lets an AI agent — Claude Desktop, etc. — read your portfolio, place paper trades, and check the leaderboard on your ChartObserver account.

ChartObserver is paper trading. This server cannot move real money. It can affect your public leaderboard standing and your visible portfolio.

Source code: https://github.com/bbusche/chartobserver-mcp — see SECURITY.md for the full egress/data-flow disclosure.

What this server sends and where

  • Outbound HTTPS to exactly one host: the configured CHARTOBSERVER_API_BASE (default: the ChartObserver production API on AWS API Gateway, https://g2uyqqluc4.execute-api.us-east-2.amazonaws.com/dev).
  • It transmits your UID, username, your webhook credential (as auth on trade execution), and the trade parameters the agent supplies. Nothing else.
  • It reads no files, contacts no other host, collects no telemetry, runs no code fetched at runtime, and has no install scripts.

Install

You don't install this package directly. You add it to your MCP client's configuration and it runs on demand via npx.

Claude Desktop

Open your Claude Desktop config file:

  • macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
  • Windows: %APPDATA%\Claude\claude_desktop_config.json

Add a chartobserver entry under mcpServers:

{
  "mcpServers": {
    "chartobserver": {
      "command": "npx",
      "args": ["-y", "@chartobserver/mcp-server"],
      "env": {
        "CHARTOBSERVER_WEBHOOK_ID": "your-webhook-id-here",
        "CHARTOBSERVER_UID": "your-uid-here",
        "CHARTOBSERVER_USERNAME": "your-username-here"
      }
    }
  }
}

Restart Claude Desktop. The tools become available in any conversation.

Where to find your credentials

Sign in at https://chart.observer and open Integrations → AI Agent (MCP) — or go directly to https://chart.observer/integrations/mcp. The page shows your webhook ID, UID, and username with copy buttons and a pre-filled config snippet you can paste straight into your MCP client.

Environment variables

Variable Required Default Description
CHARTOBSERVER_WEBHOOK_ID yes Your per-user webhook secret. Same value TradingView uses to fire trades into your account. Treat like a password.
CHARTOBSERVER_UID yes Your numeric user ID.
CHARTOBSERVER_USERNAME yes Your public username.
CHARTOBSERVER_API_BASE no https://g2uyqqluc4.execute-api.us-east-2.amazonaws.com/dev API Gateway base URL. Override to point at staging during testing. Must be https:.
CHARTOBSERVER_TIMEOUT_MS no 15000 Per-request timeout in milliseconds (max 120000).

Available tools

Account

Tool What it does
get_profile Read your public profile and current USD balance.

Trading

Tool What it does
place_trade Place a buy or sell. Defaults to dry_run: true — returns the projected impact without executing. Set dry_run: false only after confirming with the user.
get_balance Current USD balance.
get_open_positions Open positions, grouped by token pair with average cost basis.
get_closed_trades Recent closed trades (completed buy→sell roundtrips).
get_recent_transactions Recent raw transactions (open + closed).

Market

Tool What it does
get_leaderboard 7-day rolling leaderboard: top traders by average % profit.
get_my_ranking Your position on the leaderboard (or null if not ranked).
get_price Current price for a crypto pair (e.g. BTCUSD).

Portfolio

Tool What it does
get_portfolio_summary One-shot snapshot: balance + open positions + recent closed trades + your leaderboard rank. Designed for periodic polling — compare snapshots to detect changes.

Safety model

  • Paper trading only. Trades affect your simulated portfolio and your leaderboard standing. They do not move real money.
  • place_trade defaults to dry-run. The AI agent must explicitly pass dry_run: false to execute. You should be asked for confirmation before that happens.
  • Live trades are validated. Execution runs the same checks as the dry run (sufficient funds, position size, well-formed quantities) and refuses trades that would fail, without calling the API.
  • Secret redaction. Error text returned to the agent is sanitized; the webhook credential is redacted as defense-in-depth so it cannot leak into transcripts.
  • Bearer-secret auth. The webhook ID acts as a bearer token. If it leaks, anyone can act on your account. Don't paste it into screenshots, logs, or chat messages. If you suspect compromise, regenerate it from https://chart.observer/integrations/mcp.
  • No account creation. Sign up at https://chart.observer in a browser. Web signup requires a CAPTCHA, which a headless MCP server can't solve.

What's not in v1

  • Real-time push notifications (poll get_portfolio_summary instead).
  • Per-token rotation, multiple tokens, scoped tokens, expiry — these will come in a later revision that hardens the webhook-ID lifecycle.
  • Equities/options/forex — the platform is crypto-only paper trading today.

Development

npm install
npm run typecheck
npm test
npm run build

To test locally against staging, build then point Claude Desktop at the local file:

{
  "mcpServers": {
    "chartobserver-local": {
      "command": "node",
      "args": ["/absolute/path/to/chartobserver/mcp-server/dist/index.js"],
      "env": {
        "CHARTOBSERVER_API_BASE": "https://g2uyqqluc4.execute-api.us-east-2.amazonaws.com/staging",
        "CHARTOBSERVER_WEBHOOK_ID": "...",
        "CHARTOBSERVER_UID": "...",
        "CHARTOBSERVER_USERNAME": "..."
      }
    }
  }
}

Repo layout

src/
  index.ts          # MCP server entry, registers tools
  config.ts         # Loads + validates env vars
  api-client.ts     # HTTP client for ChartObserver API
  redact.ts         # Secret-redaction backstop for all outbound error text
  tools/
    account.ts
    trading.ts
    market.ts
    portfolio.ts
    util.ts
  __tests__/
    api-client.test.ts
    config.test.ts
    trading.test.ts
    redact.test.ts

推荐服务器

Baidu Map

Baidu Map

百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。

官方
精选
JavaScript
Playwright MCP Server

Playwright MCP Server

一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。

官方
精选
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。

官方
精选
本地
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。

官方
精选
本地
TypeScript
VeyraX

VeyraX

一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。

官方
精选
本地
graphlit-mcp-server

graphlit-mcp-server

模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。

官方
精选
TypeScript
Kagi MCP Server

Kagi MCP Server

一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。

官方
精选
Python
e2b-mcp-server

e2b-mcp-server

使用 MCP 通过 e2b 运行代码。

官方
精选
Neon MCP Server

Neon MCP Server

用于与 Neon 管理 API 和数据库交互的 MCP 服务器

官方
精选
Exa MCP Server

Exa MCP Server

模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。

官方
精选