mcpField
I
Interactive Brokers MCP

Interactive Brokers MCP

Remote
github.com/dickhfchanFinance1Updated 69w ago
Repository

About Interactive Brokers MCP

Interactive Brokers MCP is an MCP server created from an Interactive Brokers Web API application. The README describes running it alongside the Flask and FastAPI apps in Docker.

Key features

  1. 01Run the MCP server in Docker
  2. 02Run Flask and FastAPI apps together

Use cases

  1. 01Test the MCP server with the Web API
  2. 02Run both web apps alongside the MCP server

MCP support

The FastMCP server is implemented in app2.py and runs on port 3100 in the Docker Compose setup. The README does not specify which trading operations it exposes.

Configuration

Remote servers need no local install. Pick your client, then copy the config or install in one click.

Endpointhttp://ip_address:3000/sse
Copy install command
Claude CodeTerminal
Cursor.cursor/mcp.json
VS Code.vscode/mcp.json
Claude Desktopclaude_desktop_config.json
Windsurf~/.codeium/windsurf/mcp_config.json

Run commands in a terminal; paste JSON into the client’s MCP config and restart. Servers that need sign-in will prompt on first connect.

All endpoints
SSEhttp://ip_address:3000/sseAuth required

Tools

Details

From the project README

Interactive Brokers Web API

Video Walkthrough

https://www.youtube.com/watch?v=CRsH9TKveLo

Requirements

Clone the source code

git clone https://github.com/hackingthemarkets/interactive-brokers-web-api.git

Bring up the container

docker-compose up

Getting a command line prompt

docker exec -it ibkr bash

app2.py

app2.py is the MCP server. It was created by converting the flask app to fastapi app first then add the FastMCP.

added port 3100 in docker-compose.yml for the mcp server.

both flask app and fastapi app can run together for testing and checking.

Setup

Need to update the ID in docker yaml file IBKR_ACCOUNT_ID: "U1234567"

Comments

Markdown supported

New to MCP?

From what the protocol is to installing your first server, these answers cover most first questions.

An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.