Skip to main content
Glama
OKX Market Guard

OKX Market Guard

by mavis-codee

Funding rate

funding_rate
Read-onlyIdempotent

Fetches the current OKX public funding rate for a perpetual swap (e.g., BTC-USDT-SWAP) so you can assess carry costs with read-only market data and no credentials.

Instructions

Get the current OKX public funding rate for a perpetual swap. READ-ONLY: this tool only calls OKX public market REST. No API key, no order, no account access. instId must be a SWAP, e.g. BTC-USDT-SWAP.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "instId": "<instId>"
    },
    "name": "funding_rate"
  }
}

Input Schema

NameRequiredDescriptionDefault
instIdYesPerpetual swap instrument ID, e.g. BTC-USDT-SWAP.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare read-only, open-world, idempotent, and non-destructive behavior. The description adds useful context beyond annotations by stating it only calls OKX public market REST and requires no API key, order, or account access. It does not cover rate limits or response behavior, but it sufficiently clarifies the safety and access profile.

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 short and front-loaded with the core purpose. The read-only/access sentences are slightly repetitive with the annotations but still earn their place by clarifying auth and scope.

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?

For a single-parameter read-only market-data tool with no output schema, the description covers purpose, access constraints, parameter constraints, and safety. It does not describe the response shape, but that is a minor omission given the tool's simplicity.

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 coverage is 100%, so the schema already documents instId. The description adds a meaningful constraint beyond the schema: instId must be a SWAP, with BTC-USDT-SWAP as an example. This helps prevent misuse with spot or futures identifiers.

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?

The description states a specific verb and resource: get the current OKX public funding rate for a perpetual swap. This is clearly distinct from sibling tools such as market_ticker, market_candles, oi_summary, and alert_check.

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?

It gives clear usage context: public OKX market REST, no API key, no account access, and instId must be a SWAP. It does not explicitly say when to prefer another tool or when not to use it, but the context is strong enough for selection.

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