Skip to main content
Glama
0xReisearch

REI Crypto MCP Server

by 0xReisearch

get_yield_perps

Retrieve funding rates and open interest data for perpetual contracts from both decentralized and centralized cryptocurrency exchanges.

Instructions

GET /yields/perps

Funding rates and Open Interest of perps across exchanges, including both Decentralized and Centralized.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • Handler function for the 'get_yield_perps' tool. Fetches perp funding rates and open interest data from the DefiLlama /yields/perps API endpoint using the shared make_request helper.
    @mcp.tool()
    async def get_yield_perps() -> str:
        """GET /yields/perps
        
        Funding rates and Open Interest of perps across exchanges, including both Decentralized and Centralized.
        """
        result = await make_request('GET', '/yields/perps')
        return str(result)
  • The @mcp.tool() decorator registers the get_yield_perps function with the FastMCP server.
    @mcp.tool()
  • Shared helper function used by get_yield_perps (and all other tools) to make HTTP requests to the DefiLlama API.
    async def make_request(method: str, endpoint: str, params: Optional[Dict[str, Any]] = None) -> Any:
        """Make a request to the DefiLlama API."""
        try:
            response = await client.request(method, endpoint, params=params)
            response.raise_for_status()
            return response.json()
        except Exception as e:
            return f"Error: {str(e)}"
Behavior2/5

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

No annotations are provided, so the description carries the full burden. It states the tool performs a GET operation (implying read-only) and specifies the data returned, but lacks details on behavioral traits like rate limits, authentication needs, pagination, error handling, or data freshness. For a tool with zero annotation coverage, this is a significant gap in transparency.

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?

The description is concise and front-loaded, consisting of two sentences that directly state the tool's purpose and scope. There's no wasted text, though it could be slightly more structured by explicitly separating the HTTP method from the data description.

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

Completeness3/5

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

Given the tool has 0 parameters, 100% schema coverage, and an output schema exists, the description is minimally adequate. However, as a read operation with no annotations, it lacks completeness in areas like behavioral context (e.g., rate limits, data sources) and doesn't leverage the output schema to hint at return structure, leaving room for improvement.

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?

The input schema has 0 parameters with 100% coverage, so no parameter documentation is needed. The description doesn't add parameter semantics, but that's appropriate given the schema completeness. A baseline of 4 is assigned as the description doesn't need to compensate for any parameter gaps.

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

Purpose4/5

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

The description clearly states the tool retrieves 'Funding rates and Open Interest of perps across exchanges, including both Decentralized and Centralized.' It specifies the resource (perps) and data types (funding rates, open interest) with scope (across exchanges). However, it doesn't explicitly differentiate from sibling tools like get_derivatives_overview or get_derivatives_summary, which might cover similar data.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention any prerequisites, exclusions, or comparisons to sibling tools such as get_derivatives_overview or get_yield_chart, leaving the agent to infer usage context solely from the tool name and description.

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/0xReisearch/crypto-mcp-beta'

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