Skip to main content

MCP server for Snowball Securities (雪盈证券) trading API

Project description

chnyangjie-snbpy-mcp

MCP server for Snowball Securities (雪盈证券) trading API. Lets AI agents place orders, check balances, and manage positions.

Quick Start

# 1. Install the package
pip install chnyangjie-snbpy-mcp

# 2. Set environment variables
export SNB_ACCOUNT=your_account
export SNB_KEY=your_key

# 3. Auto-install into Claude Desktop
snbpy-install

# 4. Restart Claude Desktop

Setup

cd snbpy-mcp
pip install -e .

Environment Variables

Variable Required Default Description
SNB_ACCOUNT Yes - Account ID
SNB_KEY Yes - API secret key
SNB_SERVER No sandbox.snbsecurities.com API server
SNB_PORT No 443 Port
SNB_SCHEMA No https HTTP schema
SNB_TIMEOUT No 10000 Timeout (ms)

Run

# Development (MCP Inspector)
SNB_ACCOUNT=xxx SNB_KEY=yyy mcp dev server.py

# Direct stdio
SNB_ACCOUNT=xxx SNB_KEY=yyy python server.py

Tools

Tool Description
login Verify API credentials
place_order Place a trade order
cancel_order Cancel an order
get_order_by_id Query single order
get_order_list Query orders (paginated)
get_transaction_list Query fills (paginated)
get_balance Query account balance
get_position_list Query positions

Use with Claude Desktop

Option 1: Auto-install (Recommended)

export SNB_ACCOUNT=your_account
export SNB_KEY=your_key
snbpy-install

Option 2: Use uvx (zero install)

uvx chnyangjie-snbpy-mcp

Option 3: Manual config

Add to ~/Library/Application Support/Claude/claude_desktop_config.json:

{
  "mcpServers": {
    "chnyangjie-snbpy": {
      "command": "python",
      "args": ["/path/to/server.py"],
      "env": {
        "SNB_ACCOUNT": "YOUR_ACCOUNT",
        "SNB_KEY": "YOUR_KEY"
      }
    }
  }
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

chnyangjie_snbpy_mcp-0.1.0.tar.gz (5.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

chnyangjie_snbpy_mcp-0.1.0-py3-none-any.whl (5.8 kB view details)

Uploaded Python 3

File details

Details for the file chnyangjie_snbpy_mcp-0.1.0.tar.gz.

File metadata

  • Download URL: chnyangjie_snbpy_mcp-0.1.0.tar.gz
  • Upload date:
  • Size: 5.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.6

File hashes

Hashes for chnyangjie_snbpy_mcp-0.1.0.tar.gz
Algorithm Hash digest
SHA256 712d5edccf4ad785fb5e3931e24f83d3f9fb8c223f1c57c8277b1b220a7ac986
MD5 90a528ff8bdb28cc3ca87e2ccd1b570b
BLAKE2b-256 6cce8886c80e1c0e0563c7343d1a768e00984cc3475d62e233ab7edbfd0cbcd3

See more details on using hashes here.

File details

Details for the file chnyangjie_snbpy_mcp-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for chnyangjie_snbpy_mcp-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0423189612ef3bc925a6bd035db546eb57d3eef095d193a929426aed730702f3
MD5 a56e94aa04b0a737f505cc4a07b95710
BLAKE2b-256 83d620af3569e39e550e8297145fa3710b9356d4ff3fe30b3e47599c3a8904b4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page