
A stateless streamable HTTP MCP server for interacting with the official source of government spending data.

A Model Context Protocol server providing tools to access Bybit's v5 API for market data, trading operations, position management, and account information.
Bybit MCP Server is cataloged as an MCP server attributed to bcusack. A Model Context Protocol server providing tools to access Bybit's v5 API for market data, trading operations, position management, and account information. It is categorized under finance crypto. See the capability inspector for recorded interfaces and their independent review status; consult upstream documentation for the current interface.
Installation configuration is not reviewed. No executable setup is offered for this entry; inspect the source repository before proceeding.
Catalog license label: MIT License. Check the source repository's current license and terms before using, modifying or distributing this software.
Capability definitions are not reviewed. Unreviewed imports are not exposed as trusted interfaces.
No reviewed records to display. This does not establish that upstream lacks this capability.
No reviewed records to display. This does not establish that upstream lacks this capability.
No reviewed records to display. This does not establish that upstream lacks this capability.
Email delivery is not connected. This page does not collect email addresses or create subscriptions.
Browse the registry for current listings instead.
Reviews for Bybit MCP Server are not available yet
Review publishing and storage are not connected. This page does not collect or publish ratings or comments, including after sign-in.
No. Trading and position management tools are disabled by default and require setting BYBIT_TRADING_ENABLED=true.
Yes. Setting BYBIT_TESTNET=true uses Bybit's testnet, which uses fake money and won't affect real balances.
README.md · 599434171935 · Fetched 2026-11-13 12:45:29 UTC
Original upstream text, without AI rewriting. Scripts, forms and unsafe links are filtered for safety.
Showing the last retrieved documentation snapshot; check the source for current changes.
⚠️ TRADING WARNING ⚠️
This MCP server can execute REAL TRADING OPERATIONS on Bybit whenBYBIT_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.
✅ 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
BYBIT_TRADING_ENABLED=true)BYBIT_TRADING_ENABLED=true)Run directly from PyPi without cloning or installing:
uvx bybit-mcp
git clone <repository-url>
cd bybit-mcp
uv sync
# Copy the example environment file
cp .env.example .env
# Edit .env with your Bybit API credentials
BYBIT_API_KEY=your_api_key_here
BYBIT_API_SECRET=your_api_secret_here
BYBIT_TESTNET=false # Set to true for testnet
BYBIT_TRADING_ENABLED=false # Set to true to enable trading operations
uv run bybit-mcp
# Build the Docker image
docker build -t bybit-mcp .
# Run with environment variables (correct syntax)
docker run -i --rm --init \
-e BYBIT_API_KEY=your_api_key \
-e BYBIT_API_SECRET=your_api_secret \
-e BYBIT_TESTNET=false \
-e BYBIT_TRADING_ENABLED=false \
bybit-mcp
# Set environment variables in .env file first
docker-compose up
# Use the published Docker image
docker run -i --rm --init \
-e BYBIT_API_KEY=your_api_key \
-e BYBIT_API_SECRET=your_api_secret \
-e BYBIT_TESTNET=false \
-e BYBIT_TRADING_ENABLED=false \
falconiun/bybit-mcp
BYBIT_API_KEY: Your Bybit API keyBYBIT_API_SECRET: Your Bybit API secretBYBIT_TESTNET: Set to true to use the Bybit testnet (default is false)BYBIT_TRADING_ENABLED: Set to true to enable trading operations (default is false)The server implements several safety controls for trading operations:
BYBIT_TRADING_ENABLED=true to enable tradingBYBIT_TESTNET=true to use Bybit's testnet environmentBYBIT_TRADING_ENABLED=trueEnsure your Bybit API key has the appropriate permissions:
To use the Bybit MCP server with Claude Desktop, add the following configuration to your Claude Desktop MCP settings file:
Location of Claude Desktop MCP config:
%APPDATA%\Claude\claude_desktop_config.json~/Library/Application Support/Claude/claude_desktop_config.json~/.config/Claude/claude_desktop_config.jsonOption 1: Using Published Docker Image (Recommended)
{
"mcpServers": {
"bybit-mcp": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"--init",
"-e", "BYBIT_API_KEY=your_api_key_here",
"-e", "BYBIT_API_SECRET=your_api_secret_here",
"-e", "BYBIT_TESTNET=false",
"-e", "BYBIT_TRADING_ENABLED=false",
"falconiun/bybit-mcp"
]
}
}
}
Option 2: Using uvx (No Installation Required)
{
"mcpServers": {
"bybit-mcp": {
"command": "uvx",
"args": [
"bybit-mcp"
],
"env": {
"BYBIT_API_KEY": "your_api_key_here",
"BYBIT_API_SECRET": "your_api_secret_here",
"BYBIT_TESTNET": "false",
"BYBIT_TRADING_ENABLED": "false"
}
}
}
}
Option 3: Local Development
{
"mcpServers": {
"bybit-mcp": {
"command": "uv",
"args": ["run", "bybit-mcp"],
"cwd": "path/to/your/bybit-mcp",
"env": {
"BYBIT_API_KEY": "your_api_key_here",
"BYBIT_API_SECRET": "your_api_secret_here",
"BYBIT_TESTNET": "false",
"BYBIT_TRADING_ENABLED": "false"
}
}
}
}
Important Claude Desktop Notes:
your_api_key_here and your_api_secret_here with your actual Bybit API credentialsBYBIT_TESTNET=true for testing with fake money (recommended for first use)BYBIT_TRADING_ENABLED=true only when you want to enable real trading operationsClaude Desktop Usage Examples:
Once configured, you can ask Claude Desktop questions like:
For trading (when BYBIT_TRADING_ENABLED=true):
Security Best Practices:
BYBIT_TESTNET=true to test functionality safelyThis server works with any MCP-compatible client. The configuration format may vary slightly between clients, but the core setup remains the same:
Add to your VS Code settings.json:
{
"mcp": {
"servers": {
"bybit-mcp": {
"type": "stdio",
"command": "uvx",
"args": ["bybit-mcp"],
"env": {
"BYBIT_API_KEY": "${input:bybit_api_key}",
"BYBIT_API_SECRET": "${input:bybit_api_secret}",
"BYBIT_TESTNET": "${input:bybit_testnet}",
"BYBIT_TRADING_ENABLED": "${input:bybit_trading_enabled}"
}
}
},
"inputs": [
{
"type": "promptString",
"id": "bybit_api_key",
"description": "Bybit API Key",
"password": true
},
{
"type": "promptString",
"id": "bybit_api_secret",
"description": "Bybit API Secret",
"password": true
},
{
"type": "promptString",
"id": "bybit_testnet",
"description": "Use Bybit Testnet",
"default": "false"
},
{
"type": "promptString",
"id": "bybit_trading_enabled",
"description": "Enable Bybit Trading",
"default": "false"
}
]
}
}
For using the published Docker image:
{
"mcp": {
"servers": {
"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": "${input:bybit_api_key}",
"BYBIT_API_SECRET": "${input:bybit_api_secret}",
"BYBIT_TRADING_ENABLED": "${input:bybit_trading_enabled}",
"BYBIT_TESTNET": "${input:bybit_testnet}"
}
}
},
"inputs": [
{
"type": "promptString",
"id": "bybit_api_key",
"description": "Bybit API Key",
"password": true
},
{
"type": "promptString",
"id": "bybit_api_secret",
"description": "Bybit API Secret",
"password": true
},
{
"type": "promptString",
"id": "bybit_testnet",
"description": "Use Bybit Testnet",
"default": "false"
},
{
"type": "promptString",
"id": "bybit_trading_enabled",
"description": "Enable Bybit Trading",
"default": "false"
}
]
}
}
Important Docker Notes:
-e flags are required to pass environment variables to the Docker containerenv section sets the variables in VS Code's environment, which are then passed to Docker--init flag helps with proper signal handling in containersTest the server using the MCP inspector:
npx @modelcontextprotocol/inspector uv run bybit-mcp
uv run pytest tests/
All market data tools are always available and do not require special permissions.
get_server_time: Get current Bybit server timeget_tickers: Get ticker information for symbolsget_order_book: Get order book depthget_recent_trades: Get recent trade historyget_kline: Get standard OHLCV kline dataget_mark_price_kline: Get mark price historical dataget_index_price_kline: Get index price historical dataget_premium_index_price_kline: Get premium index kline dataget_instruments_info: Get trading instrument detailsget_funding_rate_history: Get funding rate historyget_open_interest: Get open interest statisticsget_insurance: Get insurance fund dataget_risk_limit: Get risk limit informationget_long_short_ratio: Get long/short ratio dataBYBIT_TRADING_ENABLED=true)These tools are only available when trading is enabled via the BYBIT_TRADING_ENABLED environment variable.
place_order: Place standard orders (Market, Limit) for immediate or specified price executionplace_trigger_order: Place conditional/trigger orders with advanced stop-loss, take-profit, and market entry strategiesamend_order: Modify existing pending orders (price, quantity, or trigger conditions)cancel_order: Cancel a specific pending ordercancel_all_orders: Cancel all open orders for enhanced risk managementbatch_place_order: Place multiple orders in one requestbatch_amend_order: Amend multiple orders in one requestbatch_cancel_order: Cancel multiple orders in one requestget_open_closed_orders: Get open and closed ordersget_order_history: Get order historyget_trade_history: Get trade execution historyget_wallet_balance: Get comprehensive wallet balance informationget_single_coin_balance: Get balance for a specific cryptocurrencyget_account_info: Get detailed account information and settingsBYBIT_TRADING_ENABLED=true)Position management tools require trading to be enabled.
get_position_info: Query real-time position dataget_closed_pnl: Get closed profit and loss recordsset_leverage: Set position leverageswitch_cross_isolated_margin: Switch margin modeswitch_position_mode: Switch between one-way/hedge modeset_auto_add_margin: Configure automatic margin additionset_trading_stop: Set take profit, stop loss, trailing stopsmodify_position_margin: Add or reduce position marginAll tools support the following common parameters where applicable:
category: Product type (linear, inverse, option, spot)symbol: Trading symbol (e.g., BTCUSDT)limit: Data size limit per pagestart/end: Time range for historical dataGet Server Time
{
"name": "get_server_time",
"arguments": {}
}
Get Ticker Data
{
"name": "get_tickers",
"arguments": {
"category": "linear",
"symbol": "BTCUSDT"
}
}
Get Kline Data
{
"name": "get_kline",
"arguments": {
"symbol": "BTCUSDT",
"interval": "1",
"category": "linear",
"limit": 100
}
}
Place Order (Requires Trading Enabled)
{
"name": "place_order",
"arguments": {
"category": "linear",
"symbol": "BTCUSDT",
"side": "Buy",
"orderType": "Limit",
"qty": "0.001",
"price": "50000.00",
"orderLinkId": "my-order-123"
}
}
Place Trigger Order (Requires Trading Enabled)
{
"name": "place_trigger_order",
"arguments": {
"category": "linear",
"symbol": "BTCUSDT",
"side": "Buy",
"orderType": "Market",
"qty": "0.001",
"triggerPrice": "48000.00",
"triggerDirection": 2,
"triggerBy": "LastPrice",
"orderLinkId": "trigger-buy-123"
}
}
Get Position Info (Requires Trading Enabled)
{
"name": "get_position_info",
"arguments": {
"category": "linear",
"symbol": "BTCUSDT"
}
}
Set Leverage (Requires Trading Enabled)
{
"name": "set_leverage",
"arguments": {
"category": "linear",
"symbol": "BTCUSDT",
"buyLeverage": "10",
"sellLeverage": "10"
}
}
Set Trading Stop (Requires Trading Enabled)
{
"name": "set_trading_stop",
"arguments": {
"category": "linear",
"symbol": "BTCUSDT",
"takeProfit": "55000.00",
"stopLoss": "45000.00",
"positionIdx": 0
}
}
Get Wallet Balance
{
"name": "get_wallet_balance",
"arguments": {
"accountType": "UNIFIED",
"coin": "USDT"
}
}
Get Single Coin Balance
{
"name": "get_single_coin_balance",
"arguments": {
"accountType": "UNIFIED",
"coin": "BTC"
}
}
Get Account Info
{
"name": "get_account_info",
"arguments": {}
}
bybit://market/info: General information about available endpoints and capabilities-e flag format shown in the Docker configuration aboveenv section in VS Code MCP settings sets variables in VS Code's environment, which are then passed to Docker via -e flagsseq field in trade history is automatically converted from int to stringBYBIT_TRADING_ENABLED=true in your environment variablesEnable debug logging by setting the log level:
# Local development
PYTHONPATH=src python -c "import logging; logging.basicConfig(level=logging.DEBUG)" -m bybit_mcp.main
# Docker
docker run -e PYTHONPATH=src -e LOG_LEVEL=DEBUG ...
bybit-mcp/
├── src/bybit_mcp/
│ ├── __init__.py
│ ├── main.py # MCP server implementation
│ ├── market.py # Market data API functions
│ ├── trade.py # Trading API functions
│ ├── position.py # Position management functions
│ └── models/
│ ├── market_models.py # Market data Pydantic models
│ ├── trade_models.py # Trading Pydantic models
│ └── position_models.py # Position Pydantic models
├── tests/
│ ├── test_market.py # Market data unit tests
│ └── test_trade.py # Trading unit tests
├── pyproject.toml # Project configuration
├── Dockerfile # Docker configuration
└── README.md
The project uses:
v0.1.0 - Production Release
falconiun/bybit-mcpThis project is licensed under the MIT License - see the LICENSE file for details.
This software is for educational and development purposes. Always test thoroughly before using in production environments. The authors are not responsible for any financial losses incurred through the use of this software.
For issues and questions:
If you find this MCP server useful for your trading and development needs, consider supporting its continued development:
Your support helps maintain and improve this project, add new features, and ensure compatibility with the latest Bybit API updates. Thank you for considering a contribution!
Claim this server with your GitHub account to request manual ownership verification.
Link to the catalog listing for Bybit MCP Server from your README. This badge does not certify ownership, compatibility or security.
[](https://awesome-mcp.com/servers/bybit-py-mcp)Public repository statistics could not be verified. Check the configured source address; unavailable counts are not zero.
Separate sources, scopes and periods. Never combined or treated as installations, active users or security reviews.
No reviewed package or image identity; download statistics are not listed yet.
Alternative and complementary servers in the same category

A stateless streamable HTTP MCP server for interacting with the official source of government spending data.

A hosted, remote MCP server for Fortnox that lets AI assistants answer questions from a company's bookkeeping and propose changes for approval before writing them.

OptimistFi is a read-only remote MCP server that provides perpetual futures market data, perps prop firm rules and pricing, and US equity investment research.