Skip to main content
Glama

Crypto Bot Audit + Market Data (x402 paid)

OKX OHLC candles

market_okx_candles
Read-onlyIdempotent

Mark, base and quote volume per bucket for an OKX instrument, oldest first, across the bar widths the venue serves. Costs $0.001 USDC per call. Byte-identical to GET /market/okx-candles?instId=BTC-USDT&bar=1m&limit=20.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
barNoOKX bar width (default "1m")
limitNocandles (max 300) (default 48)
instIdYesOKX instrument id, BASE-QUOTE (BTC-USDT, ETH-USDT-SWAP) [required]

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
tsNo
barNo
noteNo
rowsNo
countNo
foundNo
staleNo
caveatNo
instIdNo
reasonNo
sourceNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": false,
      +  "properties": {
      +    "bar": {
      +      "type": "string"
      +    },
      +    "caveat": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "count": {
      +      "type": "integer"
      +    },
      +    "found": {
      +      "type": "boolean"
      +    },
      +    "instId": {
      +      "type": "string"
      +    },
      +    "note": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "reason": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "rows": {
      +      "items": {},
      +      "type": "array"
      +    },
      +    "source": {
      +      "type": "string"
      +    },
      +    "stale": {
      +      "type": [
      +        "boolean",
      +        "null"
      +      ]
      +    },
      +    "ts": {
      +      "type": "string"
      +    }
      +  },
      +  "type": "object"
      +}
  2. Added

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, destructiveHint=false, so the safety profile is covered. The description adds valuable behavioral context: it discloses the cost ($0.001 USDC per call), the ordering (oldest first), and the byte-identical equivalence to a specific REST endpoint. This goes beyond annotations and helps an agent understand side effects and exactness.

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

Conciseness5/5

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

Two sentences, front-loaded with the core function, then cost and exact endpoint equivalence. Every sentence earns its place; no filler or repetition of schema details.

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?

The tool has an output schema, so return values need no description. Annotations cover safety and idempotence. The description covers cost, ordering, and endpoint equivalence. The only minor gap is not listing valid bar values or explaining the default limit behavior, but the schema already provides defaults and the output schema exists. Complete enough for an agent to call correctly.

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

Parameters3/5

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

Schema description coverage is 100%, so the schema already documents all three parameters (instId, bar, limit). The description adds the notion of 'bar widths the venue serves' and 'per bucket' but doesn't enumerate valid bar values or explain limit semantics beyond what the schema says. Baseline 3 is appropriate because the schema carries the parameter documentation burden.

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 ('Mark, base and quote volume per bucket') and resource ('OKX instrument'), and distinguishes itself from sibling candle tools by naming the venue (OKX) and the exact endpoint it mirrors. It is immediately clear this is the OKX-specific OHLC candle tool, not a generic market tool.

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?

The description implies usage for OKX instruments and bar widths, and the byte-identical endpoint reference gives a precise contract. It doesn't explicitly say when to use this over market_okx_ticker or market_okx_trades, but the candle-specific language and venue naming provide clear context. No exclusions or alternatives are named, but the scope is unambiguous.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources