FxSocket
com.fxsocketPublished by fxsocket.comOfficial publisherv1.0.1Updated Nov 1, 2026
Read-only MetaTrader 4 and 5 accounts: balances, positions, trade history, quotes and candles.
Overview
Read-only access to MetaTrader 4 and 5 trading accounts on FxSocket: balances, positions, trade history, quotes and candles.
- What you can do
- List and inspect accounts with balance, equity, broker info and terminal status
- Review open positions and pending orders with floating P/L and swap
- Pull closed trades for a period with wins, losses, win rate and net P/L
- Look up broker symbol names, contract specifications and live bid/ask quotes
- Fetch OHLC price history for a symbol and timeframe
- When to use it
- Useful when you want an assistant to answer questions about your own MT4/MT5 accounts — how a strategy performed, what is currently open, or what a symbol's contract terms and recent prices look like — without giving it trading rights.
- Requirements
- A FxSocket account and API key, supplied as the FXSOCKET_API_KEY environment variable (Docker or Python relay) or an X-API-Key header for the remote endpoint. The Docker image needs Docker; the alternative single-file relay needs Python 3.10 or newer. Network access to the FxSocket MCP endpoint, and the key must be valid for every tool call.
Installation
In SourceWeft
- Open FxSocket in the dashboard and add it to a workspace.
- Connect X-API-Key credentials. They are stored privately and never shown on public pages.
- Enable the server for the chats that should use its tools.
Web executable via Streamable HTTP. Remote servers run from the web runtime once configured in a workspace.
Use with an agent
Paste this prompt into Claude Code, Codex, Cursor or another agent — or into SourceWeft chat. The agent reads this server's install guide, shows you its publisher, endpoint and sign-in, and adds it to your client once you agree. Keys never go into a command.
Read https://sourceweft.com/mcp/com.fxsocket%2Fmcp/install.md and connect the MCP server it describes to my client. Before changing any config, show me its publisher, endpoint and sign-in method and wait for my OK. Never put an API key in a command or in a file I would commit; ask me where it should come from.Other MCP clients
Add this to your client's mcpServers config.
{
"mcpServers": {
"fxsocket": {
"type": "http",
"url": "https://mcp.fxsocket.com/mcp",
"headers": {
"X-API-Key": "<YOUR_API_KEY>"
}
}
}
}README
FxSocket MCP
[Docker Hub] [CI] [License: MIT]
Lets Claude, Cursor, VS Code and other MCP clients read your MetaTrader 4 and 5 accounts on FxSocket: balances, open positions, closed trades with win rate and P/L, quotes, symbol specifications and price history. It is read-only. It cannot place, modify or close orders.
This image runs FxSocket's MCP server as a local stdio server, for
clients that start their servers themselves (Claude Desktop, Docker's MCP
Toolkit, or anything configured with a command). It relays each message
to https://mcp.fxsocket.com/mcp with your API key. The tools run on
FxSocket, next to the terminals your accounts are connected to, so the
image stays tiny and never needs updating when tools change.
If your client takes a remote server URL plus a header, you can skip the
image: point it at https://mcp.fxsocket.com/mcp with your key in an
X-API-Key header.
1. Get an API key
Create a read-only key (fxs_ro_...) at
app.fxsocket.com/dashboard/api-key.
A named key scoped to some of your accounts limits the agent to exactly
those. A full fxs_live_... key works too, but an agent has no use for one.
2. Add it to your client
Claude Desktop (Settings, Developer, Edit Config, then restart):
Claude Code:
Cursor (~/.cursor/mcp.json):
VS Code (.vscode/mcp.json, prompts for the key once):
-e FXSOCKET_API_KEY without a value passes the variable through from the
client's env, so the key never appears in the process list.
Without Docker: the relay is one file with no dependencies. Download
fxsocket_mcp.py and use python3 (3.10 or newer) as
the command with the file's path as the argument, keeping the same env.
Tools
Amounts are in each account's deposit currency and are never summed across currencies. Times are broker server time.
Configuration
FxSocket allows 60 MCP requests a minute per user.
How it works
The client writes newline-delimited JSON-RPC to the container's stdin. The relay POSTs each message to the MCP endpoint over a kept-alive HTTPS connection, adds the API key and the headers the protocol requires, and writes the replies to stdout. It handles both protocol eras:
- 2026-07-28: the protocol version travels in each request's
_meta, and the relay mirrors it into theMCP-Protocol-Version,Mcp-MethodandMcp-Nameheaders (plus anyx-mcp-headertool parameters). - 2025-03-26 to 2025-11-25: the client opens with
initialize, and the relay sends the negotiated version asMCP-Protocol-Versionfrom then on.
If FxSocket rejects the key, the relay still answers initialize and
tools/list from the server's public card
(https://mcp.fxsocket.com/.well-known/mcp/server-card.json), so
directories and inspectors that start it with a placeholder key can see
the tools. Every tool call still needs a valid key and otherwise returns
the rejection.
Requests run concurrently. A notifications/cancelled from the client
closes that request's connection, which is how Streamable HTTP cancels.
HTTP failures (bad key, rate limit, network) come back as JSON-RPC errors
with a sentence saying what to fix, rather than a hung client.
Development
The tests start the relay as a subprocess against a local stub server, so they cover the real stdio and HTTP paths.
To release, bump __version__ in fxsocket_mcp.py, then push a matching
tag (git tag v1.0.1 && git push --tags). The publish workflow builds
linux/amd64 and linux/arm64 and pushes fxsocket/mcp:<version>,
:<major>.<minor> and :latest, and the dockerhub-overview workflow
copies this README to the Docker Hub page.
License
Source: README.md at commit de84ab9
Tools
0Version history
1- v1.0.1LatestOct 18, 2026
Score
85% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 daysRequired25 pts
- Auth declaredRequired10 pts
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts