GUIDE · AI AGENTS FOR TRADERS
How the Model Context Protocol lets an AI assistant read and manage a trading platform, what it should and should not be allowed to do, how to connect it safely to software running on a VPS, and a step-by-step setup for Claude, ChatGPT and DeepSeek.

Contents
Short answer: the SharpTrader AI agents server now has 37 tools. Besides reading SharpTrader and managing strategies, an agent can book non-toxic orders that SharpTrader sends and closes on schedule, protect them with a stop loss, take profit and trailing stop, show how each account’s order flow looks to the broker, and calculate 76 technical indicators. Order tools exist only when you switch them on, and the agent trades only on the sessions you mark Active, inside limits it can read but never change.
Free agent skills. Nine skills teach Claude, ChatGPT, Codex and other agents to plan non-toxic orders within your limits: what to add, how many, at what cost, and how to check the effect. See Non-toxic skills for AI agents.
Short answer: the Model Context Protocol (MCP) is an open standard that lets an AI assistant call functions in another program. The program runs a small MCP server that publishes a list of tools, each with a name, a description and typed arguments. The assistant reads that list, decides which tool answers your request, calls it and turns the result into an answer. For a trading platform, the tools are things like “list strategies”, “get performance” or “stop strategy”.
The important part for traders: the assistant does not get a screen or a mouse, and it does not guess. It can only call the tools the server publishes, with the arguments the server accepts, and the server decides what each tool is allowed to change. That makes MCP very different from “giving an AI remote access to your VPS”.
Algorithmic and arbitrage traders run their software around the clock, usually on a VPS close to the broker or exchange. Most of the day-to-day work is checking, not trading: is every session connected, is every strategy running, what does the log say after a disconnect, how did a strategy do this week, what was the slippage. Each check means a remote desktop session, several windows and some scrolling.
There are two typical layouts. Which one you use decides whether you need a certificate and firewall rules.
| Layout | Where things run | Address | What you need |
|---|---|---|---|
| Local | The trading software and the AI assistant on the same computer | http://127.0.0.1:47350/mcp |
Access token only. Nothing is reachable from the network. |
| VPS | Trading software on a VPS, the assistant on your home or office computer | https://<VPS address>:47350/mcp |
Access token, HTTPS certificate, firewall rule for your home IP, port open at the VPS provider. |
| Hosted agents | Trading software on a VPS, the agent on OpenAI’s servers | https://<public name or IP>:47350/mcp |
A publicly trusted certificate (Let’s Encrypt), public address, open port. |
The VPS layout is the most common for SharpTrader users: the platform keeps its low-latency location, and the assistant runs where you are. Your phone then talks to the assistant, and the assistant’s desktop app talks to the VPS.
Language models are good at reading and summarising and sometimes wrong about what you meant. A sensible design gives an agent wide read access and narrow, explicit write access. In SharpTrader the 37 tools are split into five permission groups:
| Group | Tools | Allows | Default |
|---|---|---|---|
| Read | 16 | Overview, sessions, strategies, settings, instruments, open and closed orders, performance, session and strategy logs, journal, news, the flow profile of each account, 76 technical indicators, the list of agent orders and your limits | Always on while the server runs |
| Control | 9 | Start and stop strategies (one or all), trading on/off, connect and disconnect sessions | Off |
| Settings | 7 | Change strategy and instrument settings, the news filter and events, create and clone strategies | Off |
| Positions | 1 | Close all positions of a strategy at market | Off |
| Orders | 4 | Send, cancel and close non-toxic orders through manual trading and change their trailing stop, only on sessions you mark Active and within each session’s limits | Off; a risk warning must be accepted first |
Just as important is what is not available to any agent: sending an order outside the sessions and limits you set, changing those limits, deleting or renaming strategies, adding or removing instruments, session properties and symbol mapping, backtests and optimisation, and anything about paths, files, DLLs or network addresses. Those stay in the program’s own windows.
An MCP server on a trading VPS is a door into your trading. These are the protections to look for, in SharpTrader or in any platform you connect:
| Check | Why it matters | In SharpTrader |
|---|---|---|
| Token on every request | Without it anyone who finds the port can call tools | 32-byte random token, stored encrypted, “401” without it |
| HTTPS off the local computer | A token sent in plain text can be captured | The server refuses to listen on a network address without a certificate |
| IP allow-list | Limits who can even try a token | “Allowed external IPs” plus one-button Windows Firewall rules |
| Brute-force block | Stops token guessing | 10 wrong tokens in 10 minutes block that address for 15 minutes |
| No browser access | A malicious web page could call a local server | Requests from web pages are refused |
| Least privilege | Limits the damage of a misunderstood request | Read-only by default, four separate write switches; orders only on sessions you mark Active, inside per-session limits the agent cannot change |
| Audit trail | You can see what the agent did and when | Daily call log plus journal entries for every action and failure |
| Token rotation | Revokes a leaked token at once | “New token” cuts off every client using the old one |
In SharpTrader open Settings › AI agents (MCP). For the local layout, tick “Allow AI agents to connect”, keep “This computer only” and press Apply changes. For the VPS layout:
1
2
3
C:\SharpTrader.4
5

If your VPS provider has its own firewall in its control panel, open TCP port 47350 there too; SharpTrader can only change Windows Firewall.
Claude Desktop is the easiest client because SharpTrader ships a ready extension file, SharpTrader.mcpb. It uses Claude Desktop’s own runtime, so nothing else has to be installed.
1
2
SharpTrader.mcpb into the window and press Install.3
http://127.0.0.1:47350/mcp on the same computer, or the https address shown next to “Server is running” for a VPS. Paste the access token, choose the .cer file, press Save.4
Given a certificate file, the extension connects only to a server that presents that certificate, so the token never goes anywhere else. If SharpTrader starts after Claude, the extension retries every 15 seconds and loads the tools once it connects. Claude Code, VS Code and Cursor users can instead press the matching Copy … config button in SharpTrader. The order, flow profile and indicator tools need extension version 1.3.0 or newer: install the current SharpTrader.mcpb, or turn the SharpTrader extension off and on so it reloads the tool list.
The ChatGPT desktop app starts local MCP servers as programs, so it reaches SharpTrader through the small mcp-remote bridge. Install Node.js on your computer first (the Windows installer, default options).
Then open ChatGPT › Settings › Plugins, add an MCP server and fill in:
| Field | Value |
|---|---|
| Command to launch | npx |
| Arguments (one per line) | -y · mcp-remote@latest · https://YOUR-VPS-IP:47350/mcp · --header · Authorization:${AUTH_HEADER} |
| AUTH_HEADER | Bearer, a space, then your access token |
| NODE_EXTRA_CA_CERTS | Path to the certificate, for example C:\SharpTrader\mcp-server.cer |
| NODE_OPTIONS | --use-system-ca |

Save, start a new chat and ask “show me my SharpTrader strategies”. If ChatGPT asks whether to trust the folder, confirm. For OpenAI’s hosted agents (Responses API, Agents SDK, Agent Builder) use Copy OpenAI config in SharpTrader instead; they need a Let’s Encrypt certificate and a public address.
Short answer: DeepSeek’s own apps cannot call external tools, so use Cherry Studio, a free open-source desktop client (Windows and macOS) with a built-in DeepSeek provider and MCP support. It needs no Node.js and no certificate file, but it accepts only trusted certificates: press Get a trusted certificate (Let’s Encrypt)… in SharpTrader first (a domain name pointing at the VPS is required). Both deepseek-flash (fast, cheap) and deepseek-v4-pro (stronger reasoning) support tool calls. This is the route for users in mainland China, where Claude and ChatGPT are not reachable without a VPN.
1
2
sk-… key is shown once).3
https://api.deepseek.com, press Fetch models and add deepseek-flash, then switch the provider on (top-right toggle).4
5
deepseek-flash, open the + menu › MCP › enable sharptrader, and ask “Show the SharpTrader overview and list all strategies with their status.” A tool-call block above the reply means the chain works.| Field | Value |
|---|---|
| Type | Streamable HTTP (streamableHttp), not SSE or STDIO |
| URL | The https address shown after “Server is running”, e.g. https://your-domain.com:47350/mcp (no trailing slash) |
| Headers | Authorization=Bearer <your access token> (one space after Bearer) |
{
"mcpServers": {
"sharptrader": {
"type": "streamableHttp",
"url": "https://your-domain.com:47350/mcp",
"headers": { "Authorization": "Bearer <your access token>" }
}
}
}



Cherry Studio’s UI is shown in Chinese in the screenshots; the English UI has the same layout. Common errors: a red server status means a wrong URL or type; 401 in the server log means a wrong token (press New token in SharpTrader); no tool calls in the chat means MCP is not enabled for that conversation or the model does not support tools. A step-by-step PDF with every screen is available in Chinese: SharpTrader × DeepSeek setup guide (PDF, 中文).
| Request | Permission group |
|---|---|
| “Give me an overview: which sessions are connected and which strategies are running?” | Read |
| “Show the last errors in the log of strategy 21.” | Read |
| “What were the net profit, profit factor and average slippage of strategy 23 this week?” | Read |
| “Which high-impact USD events are on the calendar today?” | Read |
| “Connect all sessions, then start strategy 19.” | Control |
| “Stop all strategies until the release is over.” | Control |
| “Clone strategy 18 and set MaxOrdersTotal to 5 on the copy.” | Settings |
| “Turn on the news filter for strategy 21 and refresh the calendar.” | Settings |
| “Close all positions of strategy 23.” | Positions |
| “Show me the flow profile of my main account for the last 7 days and tell me what stands out to the broker.” | Read |
| “What are the RSI(14) and the 50-period SMA on H1 for EURUSD on session MAIN? Warn me if the candles are not complete.” | Read |
| “Book 4 orders on EURUSD on session MAIN: 0.01 lots, two buys and two sells, spread over the next 3 hours, each held 40 to 90 minutes.” | Orders |
| “Give order 12 a trailing stop: start after 20 points of profit, with a 15-point step.” | Orders |
Good habits: name strategies by ID, ask the agent to read the state again after an action (connecting, closing positions and order updates continue in the background), and keep write requests short and explicit.
| Symptom | What to do |
|---|---|
| The client shows no tools, or old tools | After changing allowed operations, reconnect the server in the client (or restart it) so it reloads the list. |
| “Server could not start” | The reason follows: usually the port is taken, the certificate or its password is wrong, or a network address has no certificate. |
| 401 Unauthorized | Wrong token, or New token was pressed. Copy the configuration again. |
| 429 Too many requests | That address sent 10 wrong tokens in 10 minutes. Fix the token; the block ends after 15 minutes. |
| Other computers cannot connect | Check that Listen on is not “This computer only”, the VPS provider’s firewall, and the message of Create firewall rules. |
| Claude shows the server but no SharpTrader tools | Quit Claude Desktop fully from the tray icon and start it again. |
| A settings change is refused | Stop the strategy for general settings, close its window in SharpTrader, or close its open orders before changing a symbol. |
| The agent cannot send an order | Check that Send non-toxic orders is ticked, the session is Active in the grid and the order fits that session’s limits; then reconnect the client so it loads the order tools. |
| Indicator values come with a warning | Switch on candle collection for that timeframe in the symbol’s properties in the session settings, then reconnect the session. |
| A call times out after 30 seconds | A message box or dialog is open in SharpTrader. Close it, then let the agent read the state. |
37 tools, read-only by default, order sending only inside the limits you set, HTTPS and token protection. Works with Claude, ChatGPT, DeepSeek (via Cherry Studio) and other MCP clients.
Model Context Protocol, an open standard for connecting AI assistants to programs and data. A program runs an MCP server that publishes tools; an assistant such as Claude or ChatGPT calls them.
Only if you allow it. In SharpTrader the order tools are off by default. When you switch on non-toxic orders and accept the risk warning, an agent can send orders through manual trading on the sessions you mark Active, within the limits you set for each one; it can never change those limits. Without that switch an agent can only start or stop the strategies you configured and, if you allow it, close a strategy’s positions.
No. If the assistant runs on the same computer as SharpTrader, the server listens only on 127.0.0.1 and needs no certificate. A VPS is only needed if your trading already runs there.
Yes, through the Cherry Studio desktop client: it has a built-in DeepSeek provider and connects to the same MCP server with a Streamable HTTP entry and a bearer token. It needs a Let’s Encrypt certificate on the SharpTrader side and works without a VPN in mainland China. See Connecting DeepSeek.
Both work with the same tools. Claude Desktop is quicker to set up thanks to the ready extension file; ChatGPT needs Node.js and a few more fields. Use the assistant you already pay for.
Yes. Connect the assistant on your computer, then use its mobile app; the connector is available there too, and you can ask by text or voice.
Press New token in SharpTrader and apply the changes: every client using the old token is cut off at once. Then paste the new token into your own clients.
Trading involves risk. This guide is educational and not financial advice. AI assistants can make mistakes; always review what you allow an agent to do.