Skip to main content
Glama

get_hip3_l2_orderbook_history

Read-onlyIdempotent

Retrieve HIP-3 L2 full-depth orderbook checkpoints for case-sensitive coin symbols across multiple builders. Access periodic aggregated snapshots with optional time range and depth limits.

Instructions

Get HIP-3 L2 full-depth orderbook checkpoints (Build+ tier). Symbols are CASE-SENSITIVE. Returns periodic aggregated snapshots.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
coinYesHIP-3 coin symbol (CASE-SENSITIVE). 125+ markets across 6 builders: xyz, flx, hyna, km, vntl, cash. Examples: 'km:US500', 'xyz:GOLD', 'hyna:BTC', 'vntl:SPACEX', 'flx:TSLA', 'cash:NVDA'. Use get_hip3_instruments to list all.
startNoStart timestamp (Unix ms or ISO). Defaults to 24h ago.
endNoEnd timestamp (Unix ms or ISO). Defaults to now.
limitNoMax records to return (default 100, max 1000)
cursorNoPagination cursor from previous response's nextCursor
depthNoOrderbook depth — number of price levels per side

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
recordsYesArray of result records
countYesTotal number of records in the full result set
nextCursorNoCursor for next page, if more results available

Implementation Reference

  • src/index.ts:662-670 (registration)
    Registration of the 'get_hip3_l2_orderbook_history' tool using registerHistoryTool. It calls api().hyperliquid.hip3.l2Orderbook.history(coin, params) via a lambda, uses Hip3CoinParam schema for the coin parameter, normalizeHip3Coin normalization, and adds an optional depth parameter.
    registerHistoryTool(
      "get_hip3_orderbook_history",
      "Get historical HIP-3 orderbook snapshots. Symbols are CASE-SENSITIVE (e.g. 'km:US500'). Returns L2 snapshots with bids/asks over a time range. Free tier: km:US500 only. Build+: all HIP-3 symbols.",
      (coin, params) =>
        api().hyperliquid.hip3.orderbook.history(coin, params as any),
      Hip3CoinParam,
      normalizeHip3Coin,
      { depth: DepthParam }
    );
  • Hip3CoinParam schema – Zod string describing the HIP-3 coin parameter used by get_hip3_l2_orderbook_history.
    const Hip3CoinParam = z
      .string()
      .describe(
        "HIP-3 coin symbol (CASE-SENSITIVE). 125+ markets across 6 builders: xyz, flx, hyna, km, vntl, cash. Examples: 'km:US500', 'xyz:GOLD', 'hyna:BTC', 'vntl:SPACEX', 'flx:TSLA', 'cash:NVDA'. Use get_hip3_instruments to list all."
      );
  • DepthParam schema – optional Zod number for orderbook depth (price levels per side), used by get_hip3_l2_orderbook_history.
    const DepthParam = z
      .number()
      .optional()
      .describe("Orderbook depth — number of price levels per side");
  • normalizeHip3Coin – normalization function for HIP-3 coin symbols (case-sensitive, returns as-is).
    function normalizeHip3Coin(coin: string): string {
      return coin; // Case-sensitive
    }
  • registerHistoryTool – the generic tool registration helper used to register get_hip3_l2_orderbook_history. It handles time range resolution, pagination, and extra schema params like depth.
    function registerHistoryTool(
      name: string,
      description: string,
      sdkCall: (coin: string, params: Record<string, unknown>) => Promise<{ data: unknown; nextCursor?: string }>,
      coinSchema: z.ZodString,
      normFn: (coin: string) => string,
      extraSchema?: ZodRawShape
    ): void {
      const schema: ZodRawShape = { coin: coinSchema, ...HistoryParams };
      if (extraSchema) Object.assign(schema, extraSchema);
    
      registerTool(name, description, schema, ListOutputSchema, async (params) => {
        const { coin, start, end, limit, cursor, ...extra } = params;
    
        const timeRange = resolveTimeRange(start, end);
        const sdkParams: Record<string, unknown> = {
          ...timeRange,
          limit: resolveLimit(limit),
        };
    
        if (cursor) sdkParams.cursor = cursor;
    
        // Pass through extra params (interval, side, etc.)
        for (const [k, v] of Object.entries(extra)) {
          if (v !== undefined) sdkParams[k] = v;
        }
    
        const result = await sdkCall(normFn(coin), sdkParams);
        return formatCursorResponse(result);
      });
    }
Behavior4/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true, openWorldHint=true. The description adds value by stating 'Symbols are CASE-SENSITIVE' and 'Returns periodic aggregated snapshots', which are behavioral details not covered by annotations. No contradictions.

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 concise sentences plus a key note. Front-loaded with main purpose. No redundant or filler content. Every sentence provides value.

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?

Output schema exists, so return format is covered. Required parameters and optional params are clear. The description explains the main purpose, case sensitivity, snapshot nature, but could mention pagination (cursor) or the tier's limitation. Still adequate for a historical data tool.

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 coverage is 100% with each parameter described. The description only repeats the case-sensitivity note for 'coin', which is already in the schema. No additional parameter semantics beyond the schema.

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?

Description clearly states 'Get HIP-3 L2 full-depth orderbook checkpoints' with specific verb and resource. It distinguishes from siblings like get_hip3_l2_orderbook (current snapshot) and get_hip3_l2_diffs (changes) by mentioning 'history' and 'periodic aggregated snapshots'. The tier 'Build+' adds context.

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

Usage Guidelines3/5

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

No explicit guidance on when to use this tool versus alternatives like get_hip3_l2_orderbook or get_hip3_l2_diffs. The description implies historical data but doesn't compare or contrast. The case-sensitivity note is helpful but doesn't address selection criteria.

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/0xArchiveIO/0xarchive-mcp'

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