Skip to main content
Glama
@chartobserver/mcp-server

@chartobserver/mcp-server

by bbusche

@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 (sent as an X-Webhook-Id identity header on every request for usage metering, and 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.

Related MCP server: ibkr-mcp

Install

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

Always pin to @latest. The package spec @chartobserver/mcp-server@latest tells npx to use the newest published version on each launch, so you automatically get fixes and new features. Plain @chartobserver/mcp-server (no tag) can keep running a stale cached copy.

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, then restart Claude Desktop:

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

Claude Code

Register the server with one command (run it in your terminal):

claude mcp add chartobserver \
  --env CHARTOBSERVER_WEBHOOK_ID=your-webhook-id-here \
  --env CHARTOBSERVER_UID=your-uid-here \
  --env CHARTOBSERVER_USERNAME=your-username-here \
  --transport stdio \
  -- npx -y @chartobserver/mcp-server@latest

Add --scope user to make it available across all your projects (the default is the current project only). Verify with claude mcp list; remove with claude mcp remove chartobserver.

Other MCP clients (Cursor, Cline, Windsurf, etc.)

Any client that supports stdio MCP servers uses the same shape — a server entry with a command, args, and env. Add this to that client's MCP/server configuration (consult its docs for the file location), then restart it:

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

All three paths run the identical server; the only difference is where each client keeps its configuration. The three environment variables are required in every case (see below).

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.

get_subscription

Your subscription tier (Basic / Swing Trader / Day Trader / Influencer), monthly usage vs. limits (trades, API calls, AI-assistant messages), renewal date, and recent payments.

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. token accepts a symbol (SOL), pair (SOLUSD), or name (Solana).

get_balance

Current USD balance (0 for a funded-but-empty account).

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 token. Accepts a symbol (SOL), pair (SOLUSD / SOL-USD), or name (Solana); quote defaults to USD.

list_supported_tokens

Every supported token-pair, so you can use a valid identifier before pricing or trading.

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.

Documentation

Tool

What it does

search_docs

Search the ChartObserver documentation and return the most relevant passages, each with its source URL. Use for "how does X work" / setup / integrations / subscriptions / troubleshooting questions; cite the URLs. Not for live account data.

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.

  • Prices are delayed up to 15 minutes. This is a paper-trading platform; quotes must not be used for real-money trading decisions.

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
  marshal.ts        # Unmarshals raw DynamoDB JSON from the read endpoints
  pairs.ts          # Token-pair resolution + bundled name→symbol map
  instructions.ts   # Agent-facing server instructions
  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

Available Tools

13 tools
get_balanceGet USD balanceA
Read-only

Fetch the configured user's current USD paper-trading balance.

Inputs: no named parameters.

get_closed_tradesGet closed tradesA
Read-only

List closed paper trades (completed buy→sell roundtrips) for the configured user, most recent first.

Inputs: limit.

get_leaderboardGet leaderboardA
Read-only

Fetch the 7-day rolling ChartObserver leaderboard: top traders by average % profit per closed trade, plus the top individual closed trades. Public data.

Inputs: limit.

get_my_rankingGet my leaderboard rankA
Read-only

Find the configured user's position on the 7-day leaderboard, if they appear. Returns null rank if not on the board.

Inputs: no named parameters.

get_open_positionsGet open positionsA
Read-only

List all currently open paper-trading positions (buy transactions that have not yet been closed by a sell).

Inputs: no named parameters.

get_portfolio_summaryGet portfolio summaryA
Read-only

One-call snapshot of the configured user's portfolio: USD balance, open positions grouped by token (with average cost basis), the 5 most recent closed trades, and the user's current leaderboard rank if any. Designed for periodic polling — agents can compare consecutive snapshots to detect changes.

Inputs: no named parameters.

get_priceGet current priceA
Read-only

Fetch the latest price for a supported crypto token. Accepts a bare symbol (SOL), a full pair (SOLUSD, SOL-USD, SOL/USD), or a name (Solana); the quote currency defaults to USD. Prices are delayed up to 15 minutes and are for paper trading only — never for real-money decisions. Use list_supported_tokens to see valid identifiers.

Inputs: token (required).

get_profileGet profileA
Read-only

Fetch the currently configured user's public profile (description, social links, follower counts) along with their USD paper-trading balance. Read-only. Requires an existing chart.observer account — if credentials are missing or rejected, direct the user to sign up in a browser at https://chart.observer (accounts cannot be created via this server).

Inputs: no named parameters.

get_recent_transactionsGet recent transactionsA
Read-only

List the configured user's recent transactions (open + closed, all types). Most recent first.

Inputs: limit.

get_subscriptionGet subscription & usageA
Read-only

Fetch the currently configured user's subscription tier (Basic, Swing Trader, Day Trader, or Influencer), their monthly usage vs. limits (trades, API calls, AI-assistant messages), the plan renewal date and whether it is set to cancel, and recent payments. Use this for ANY question about the user's own plan, tier, remaining quota, billing, or renewal — do NOT use search_docs for those (search_docs explains how tiers work in general; this returns the user's actual, resolved values). Read-only.

Inputs: no named parameters.

list_supported_tokensList supported tokensA
Read-only

List every crypto token-pair ChartObserver supports, so you (or the user) can use a valid identifier before requesting a price or placing a trade. Returns slash pairs like BTC/USD with their exchange. Most tokens trade against USD; a few against USDT.

Inputs: no named parameters.

place_tradePlace a paper tradeA
Destructive

Place a paper-trading buy or sell on the ChartObserver platform for the configured user.

IMPORTANT SAFETY NOTES:

  • Defaults to dry_run=true. With dry_run=true, NO trade is executed; the tool returns the would-be impact (cost, resulting balance, resulting position). Always start with dry_run=true and present the result to the user for confirmation before calling again with dry_run=false.

  • This is paper trading (simulated). It does NOT move real funds. It DOES affect the user's leaderboard standing and visible portfolio.

  • Crypto only. token accepts a bare symbol (SOL), a pair (SOLUSD / SOL-USD), or a name (Solana); quote defaults to USD. Use list_supported_tokens for valid identifiers.

  • Sell count may be a percentage string like '50%' or '100%'. Buy count must be a numeric quantity.

  • Buys require sufficient USD balance. Sells cannot exceed currently held tokens.

  • Live execution runs the same validation as the dry run and refuses trades that would fail.

  • Prices are delayed up to 15 minutes (paper trading only) — never present them as real-time or use them for real-money decisions.

  • Requires an existing chart.observer account. If credentials are rejected, direct the user to https://chart.observer to sign up in a browser (accounts cannot be created via this server).

Inputs: count (required), token (required), action (required), dry_run.

search_docsSearch ChartObserver documentationA
Read-only

Search the ChartObserver documentation and return the most relevant passages, each with its source URL. Use this for questions about how the platform works — features, setup, integrations (TradingView, webhooks, the MCP server itself), subscriptions/limits/pricing, supported tokens, or troubleshooting. Answer from the returned excerpts and cite the url(s). Do NOT use it for the user's own live account data (balance, positions, prices, leaderboard) — those have dedicated tools.

Inputs: query (required), top_k.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.2/5.0

    Scored across 13 tools

    Disambiguation4/5

    Most tools have clearly distinct purposes, though get_profile and get_balance share some balance info, and several tools deal with trades/positions. However, descriptions provide enough differentiation to guide an agent.

    Naming Consistency5/5

    All tool names follow a consistent verb_noun snake_case pattern (e.g., get_balance, place_trade, list_supported_tokens), making it easy to infer functionality.

    Tool Count5/5

    13 tools is well-scoped for a paper trading platform, covering user data, trading, portfolio, community features, and documentation search without unnecessary overlap.

    Completeness4/5

    The tool set covers essential CRUD and lifecycle operations for paper trading. Minor gaps exist (e.g., no tool for individual trade details), but core workflows are fully supported.

    Maintenance

    ActivityInactive
    ResponsivenessNo recent community issues

    Related MCP Connectors

    Related MCP Servers

    • A
      license
      Not graded
      quality
      B
      maintenance
      An MCP server that enables AI agents to scan the market, manage positions, and retrieve trading metrics for Bybit through natural language commands.
      20
      AGPL 3.0
    • F
      license
      Not graded
      quality
      B
      maintenance
      An MCP server that turns Interactive Brokers into a question-answering portfolio analyst.
      4
      -
    • A
      license
      Not graded
      quality
      C
      maintenance
      An MCP server that lets you talk to your AI trading assistant in plain English to research stocks, generate trade recommendations, manage a portfolio, and execute trades through natural language.
      MIT
    • F
      license
      Not graded
      quality
      C
      maintenance
      MCP server that exposes your GitEquity portfolio to AI clients, enabling balance queries, stock prices, and trade proposals confirmed via GitHub comments.
      -