Skip to main content
Glama
bybit-exchange

Bybit MCP Server

Official

getLongShortRatio

Query the net long and short position ratios as a market sentiment indicator for derivatives contracts, with configurable time periods and pagination.

Instructions

Query the net long and short position ratios as percentages of all position holders, used as a market sentiment indicator for derivatives markets.

Use this endpoint when you need to:

  • Measure market sentiment by comparing long vs short position holder ratios

  • Track changes in long/short ratio over time as a contrarian or trend-following signal

  • Analyze historical sentiment data at intervals from 5min to 1d

Supported Products: USDT contract, Inverse contract

Calculation:

  • buyRatio = Number of long position holders / Total position holders

  • sellRatio = Number of short position holders / Total position holders

Required parameters: category, symbol, and period. Supports cursor-based pagination via nextPageCursor.

Notes:

  • Supports cursor-based pagination

  • No authentication required

Agent hint: Use this endpoint to retrieve long/short ratio sentiment data for a derivatives symbol. Required parameters: category, symbol, and period (5min/15min/30min/1h/4h/1d). Use startTime and endTime (milliseconds) to query a specific time range. For pagination, pass nextPageCursor from the previous response into the cursor parameter.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
categoryYes
symbolYes
periodYes
startTimeNo
endTimeNo
limitNo
cursorNo
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations provided, so description carries full burden. Discloses calculation formulas, supported products, pagination, and lack of authentication. Does not mention rate limits or error handling, but adequate given no annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Well-structured with sections, bullet points, and agent hint. Front-loaded with purpose. Minor redundancy (pagination mentioned twice), but overall efficient.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers purpose, calculation, parameters, pagination, and authentication. No output schema, but description doesn't need to explain return values. Fairly complete for a data query tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so description adds significant value. Explains required params (category, symbol, period) with enums, startTime/endTime for time range, and cursor for pagination. Adds context like 'Supported Products' linking category to actual contract types.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Clearly states the tool queries net long/short ratios as a sentiment indicator. Verb 'Query' and resource 'long and short position ratios' are explicit. Distinct from sibling tools focused on other data.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Lists specific use cases: measuring sentiment, tracking trend signals, analyzing historical data. Provides agent hint and required parameters. Does not explicitly mention when not to use, but context is clear.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/bybit-exchange/trading-mcp'

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