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
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file chnyangjie_snbpy_mcp-0.1.1.tar.gz.
File metadata
- Download URL: chnyangjie_snbpy_mcp-0.1.1.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
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
70ba3782dd66efd35b652a3cb17e4a8acdb9824910cce833a2a2b896162a6782
|
|
| MD5 |
3b364d44d453ef737d91d54e4ee37084
|
|
| BLAKE2b-256 |
28ae4a331b3c328771b7aea9acae99d0fadb5cae80ce29ed82ba9f417e7da764
|
File details
Details for the file chnyangjie_snbpy_mcp-0.1.1-py3-none-any.whl.
File metadata
- Download URL: chnyangjie_snbpy_mcp-0.1.1-py3-none-any.whl
- Upload date:
- Size: 5.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
edb3e255830a2ec0a53b79558eca55a5ecc0f47cceffae24eba60270f3413ec5
|
|
| MD5 |
57bcb7c5ac0e6acfe7c9cce462bc6455
|
|
| BLAKE2b-256 |
c01d78f4b68701f10755427fca91dd7d816feea3a8a914f19d6a813656eb994b
|