JUHE API Marketplace
karimQuant avatar
MCP Server

ibapi-mcp-server

This project creates a middleware server that connects to Interactive Brokers Gateway and exposes its functionality through the FastMCP framework. This allows LLMs like Claude to interact with your IB account, retrieve portfolio information, and potentially execute trades.

3
GitHub Stars
11/22/2025
Last Updated
No Configuration
Please check the documentation below.
  1. Home
  2. MCP Servers
  3. ibapi-mcp-server

README Documentation

Interactive Brokers API FastMCP Server

A server implementation for Interactive Brokers' API that allows LLMs to interact with your IB account using the Model Context Protocol (MCP).

Overview

This project creates a middleware server that connects to Interactive Brokers Gateway and exposes its functionality through the FastMCP framework. This allows LLMs like Claude to interact with your IB account, retrieve portfolio information, and potentially execute trades.

Features

  • Connect to Interactive Brokers Gateway via the official IB API
  • Support multiple simultaneous client connections through FastMCP
  • Expose IB functionality as MCP tools and resources
  • Connection status monitoring
  • Error handling and logging

Prerequisites

  • Python 3.11+
  • Interactive Brokers Gateway installed and running
  • IB account with API access enabled

Installation

  1. Clone this repository:
git clone https://github.com/karimQuant/ibapi-mcp-server.git
cd ibapi-mcp-server
  1. Install dependencies:
pip install -e .

Usage

  1. Start your IB Gateway and log in

  2. Run the server:

    a. Using stdio transport (default):

    python server.py
    

    b. Using SSE transport:

    python server.py sse
    

    c. Using SSE transport with custom port:

    python server.py sse port=9000
    

    d. Using the FastMCP CLI:

    fastmcp run server.py
    

    e. For development with an interactive testing environment:

    fastmcp dev server.py
    
  3. Connect client applications (like Claude Desktop) to the server

API Documentation

The FastMCP Server provides the following functionality:

Available Tools

  • get_portfolio_tool: Retrieve your current portfolio positions and account summary

Resources

  • ibgateway://{host}/{port}: Get the current status of the IB Gateway connection

License

MIT

Contribution

Contributions are welcome! Please feel free to submit a Pull Request.

Quick Actions

View on GitHubView All Servers

Key Features

Model Context Protocol
Secure Communication
Real-time Updates
Open Source

Boost your projects with Wisdom Gate LLM API

Supporting GPT-5, Claude-4, DeepSeek v3, Gemini and more.

Enjoy a free trial and save 20%+ compared to official pricing.

Learn More
JUHE API Marketplace

Accelerate development, innovate faster, and transform your business with our comprehensive API ecosystem.

JUHE API VS

  • vs. RapidAPI
  • vs. API Layer
  • API Platforms 2025
  • API Marketplaces 2025
  • Best Alternatives to RapidAPI

For Developers

  • Console
  • Collections
  • Documentation
  • MCP Servers
  • Free APIs
  • Temp Mail Demo

Product

  • Browse APIs
  • Suggest an API
  • Wisdom Gate LLM
  • Global SMS Messaging
  • Temp Mail API

Company

  • What's New
  • Welcome
  • About Us
  • Contact Support
  • Terms of Service
  • Privacy Policy
Featured on Startup FameFeatured on Twelve ToolsFazier badgeJuheAPI Marketplace - Connect smarter, beyond APIs | Product Huntai tools code.marketDang.ai
Copyright © 2025 - All rights reserved