Skip to main content
Glama
Habinar

MCP Paradex Server

by Habinar

paradex_orderbook

Analyze market depth and liquidity to optimize order entry and execution by retrieving orderbook data for Paradex perpetual futures markets.

Instructions

Analyze market depth and liquidity to optimize order entry and execution. Use this tool when you need to: - Assess true liquidity before placing large orders - Identify potential support/resistance levels from order clusters - Determine optimal limit order prices for higher fill probability - Detect order imbalances that might signal price direction Understanding the orderbook is essential for effective trade execution, especially for larger orders or in less liquid markets. Example use cases: - Finding the optimal limit price to ensure your order gets filled - Estimating potential slippage for market orders of different sizes - Identifying large resting orders that might act as support/resistance - Detecting order book imbalances that could predict short-term price moves

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
market_idYesMarket symbol to get orderbook for.
depthNoThe depth of the orderbook to retrieve.

Implementation Reference

  • The handler function for 'paradex_orderbook' tool. It is registered via the @server.tool decorator and fetches the orderbook data from the Paradex client using the provided market_id and depth parameters.
    @server.tool(name="paradex_orderbook") async def get_orderbook( market_id: Annotated[str, Field(description="Market symbol to get orderbook for.")], depth: Annotated[ int, Field(default=OrderbookDepth.MEDIUM, description="The depth of the orderbook to retrieve."), ], ctx: Context = None, ) -> dict[str, Any]: """ Analyze market depth and liquidity to optimize order entry and execution. Use this tool when you need to: - Assess true liquidity before placing large orders - Identify potential support/resistance levels from order clusters - Determine optimal limit order prices for higher fill probability - Detect order imbalances that might signal price direction Understanding the orderbook is essential for effective trade execution, especially for larger orders or in less liquid markets. Example use cases: - Finding the optimal limit price to ensure your order gets filled - Estimating potential slippage for market orders of different sizes - Identifying large resting orders that might act as support/resistance - Detecting order book imbalances that could predict short-term price moves """ try: # Get orderbook from Paradex client = await get_paradex_client() response = client.fetch_orderbook(market_id, params={"depth": depth}) return response except Exception as e: await ctx.error(f"Error fetching orderbook for {market_id}: {e!s}") raise e

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Habinar/mcp-paradex-py'

If you have feedback or need assistance with the MCP directory API, please join our Discord server