Bybit Mcp Full

Created By
BCusacka year ago
A comprehensive Model Context Protocol (MCP) server that provides full access to Bybit's v5 API. This server enables AI assistants to fetch real-time market data, execute trading operations, manage positions, and access account information from the Bybit cryptocurrency exchange.
Overview

Bybit MCP Server

smithery badge

⚠️ TRADING WARNING ⚠️
This MCP server can execute REAL TRADING OPERATIONS on Bybit when BYBIT_TRADING_ENABLED=true.
Trading operations use REAL MONEY and can result in FINANCIAL LOSSES.
Always test on testnet first (BYBIT_TESTNET=true) and understand the risks before enabling trading.
Trading is DISABLED by default for safety.

A comprehensive Model Context Protocol (MCP) server that provides full access to Bybit's v5 API. This server enables AI assistants to fetch real-time market data, execute trading operations, manage positions, and access account information from the Bybit cryptocurrency exchange.

🚀 Production Ready

Fully Tested - All endpoints tested and working
Docker Support - Published image available at falconiun/bybit-mcp
VS Code Integration - Ready-to-use configurations provided
Comprehensive API Coverage - Market data, trading, positions, and account management

Features

Core Market Data

  • Server Time: Get current Bybit server time
  • Tickers: Retrieve ticker information for trading symbols
  • Order Book: Get order book depth for any symbol
  • Recent Trades: Access recent trade history

Kline/Candlestick Data

  • Standard Klines: Get OHLCV candlestick data
  • Mark Price Klines: Get mark price historical data
  • Index Price Klines: Get index price historical data
  • Premium Index Klines: Get premium index price data

Trading Information

  • Instruments Info: Get detailed trading instrument information
  • Funding Rate History: Access historical funding rates
  • Open Interest: Get open interest statistics
  • Risk Limits: Retrieve risk limit information

Market Statistics

  • Insurance Fund: Get insurance fund data
  • Long/Short Ratio: Access long/short ratio statistics

Trading Operations (Requires BYBIT_TRADING_ENABLED=true)

  • Order Management: Place, amend, and cancel orders with full control
  • Batch Operations: Execute multiple orders in a single request for efficiency
  • Order History: View comprehensive open/closed orders and trade history
  • Order Types: Support for Market, Limit, and conditional orders
  • Real-time Execution: Get immediate feedback on order status and fills

Position Management (Requires BYBIT_TRADING_ENABLED=true)

  • Position Info: Query real-time position data with detailed metrics
  • Leverage Control: Set and modify position leverage dynamically
  • Margin Management: Switch between cross/isolated margin modes
  • Trading Stops: Set take profit, stop loss, and trailing stops
  • Auto Add Margin: Configure automatic margin addition
  • Position Modes: Switch between one-way and hedge position modes
  • P&L Tracking: Access closed profit and loss records

Account & Wallet Management

  • Wallet Balance: Get comprehensive wallet balance information
  • Single Coin Balance: Query specific coin balances
  • Account Information: Access detailed account information and settings
  • Multiple Account Types: Support for UNIFIED, CONTRACT, SPOT, INVESTMENT accounts
  • 🎯 Key Capabilities

✅ Complete API Coverage

  • Market Data: All Bybit v5 market endpoints (tickers, order book, klines, funding rates, etc.)
  • Trading: Full order lifecycle management (place, amend, cancel, batch operations)
  • Positions: Complete position management (leverage, margin, stops, P&L tracking)
  • Account: Wallet balances, account info, and multi-account support

✅ Production Features

  • Safety First: Trading disabled by default with explicit enablement required
  • Testnet Support: Full testnet integration for safe development and testing
  • Error Handling: Comprehensive error handling with detailed error messages
  • Data Validation: Pydantic models ensure data integrity and type safety
  • Docker Ready: Published Docker image with proper environment variable handling

✅ Developer Experience

  • VS Code Integration: Ready-to-use configurations for both local and Docker deployment
  • MCP Protocol: Full Model Context Protocol compliance for AI assistant integration
  • Type Safety: Complete TypeScript-style typing with Pydantic models
  • Testing: Comprehensive test suite with real API integration
  • Documentation: Extensive documentation with examples and best practices

Supported Categories

  • Linear: USDT perpetual, USDC perpetual, USDC futures
  • Inverse: Inverse perpetual, Inverse futures
  • Option: Options trading
  • Spot: Spot trading pairs

Server Config

{
  "mcpServers": {
    "bybit-mcp": {
      "type": "stdio",
      "command": "docker",
      "args": [
        "run",
        "-i",
        "--rm",
        "--init",
        "-e",
        "DOCKER_CONTAINER",
        "-e",
        "BYBIT_API_KEY",
        "-e",
        "BYBIT_API_SECRET",
        "-e",
        "BYBIT_TRADING_ENABLED",
        "-e",
        "BYBIT_TESTNET",
        "falconiun/bybit-mcp"
      ],
      "env": {
        "DOCKER_CONTAINER": "true",
        "BYBIT_API_KEY": "<BYBIT_API_KEY>",
        "BYBIT_API_SECRET": "<BYBIT_API_SECRET>",
        "BYBIT_TRADING_ENABLED": "<BYBIT_TRADING_ENABLED>",
        "BYBIT_TESTNET": "<BYBIT_TESTNET>"
      }
    }
  }
}
Project Info
Created At
a year ago
Updated At
a year ago
Author Name
BCusack
Star
-
Language
-
License
-
Category

Recommend Servers

View All
Tavily Mcp
@tavily-ai

JavaScript
a year ago