Skip to main content
Glama

get_lighter_instruments

Read-onlyIdempotent

List available Lighter.xyz instruments with market IDs, fees, and decimals to identify valid trading symbols and active markets.

Instructions

List all available Lighter.xyz instruments with market IDs, fees, size/price decimals, and active status. Use this to discover valid Lighter symbols.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

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

  • Registration of the 'get_lighter_instruments' tool via the registerInstrumentsTool helper. The handler calls api().lighter.instruments.list() and formats the response. This is an instrument list tool (no input params) that returns all available Lighter.xyz instruments.
    registerInstrumentsTool(
      "get_lighter_instruments",
      "List all available Lighter.xyz instruments with market IDs, fees, size/price decimals, and active status. Use this to discover valid Lighter symbols.",
      () => api().lighter.instruments.list()
    );
  • src/index.ts:776-780 (registration)
    The tool is registered using the registerInstrumentsTool helper (defined at line 361) which wraps registerTool (line 328). registerInstrumentsTool passes an empty input schema {} and ListOutputSchema, and provides the SDK call api().lighter.instruments.list() as the handler.
    registerInstrumentsTool(
      "get_lighter_instruments",
      "List all available Lighter.xyz instruments with market IDs, fees, size/price decimals, and active status. Use this to discover valid Lighter symbols.",
      () => api().lighter.instruments.list()
    );
  • registerInstrumentsTool helper function that registers an instrument-list tool with no input parameters, returning formatted list output.
    function registerInstrumentsTool(
      name: string,
      description: string,
      sdkCall: () => Promise<unknown[]>
    ): void {
      registerTool(name, description, {}, ListOutputSchema, async () => {
        const data = await sdkCall();
        return formatResponse(data);
      });
    }
  • registerTool is the core helper that wraps server.registerTool with API key guard, error handling, and annotation configuration.
    function registerTool(
      name: string,
      description: string,
      inputSchema: ZodRawShape,
      outputSchema: ZodRawShape,
      handler: (params: any) => Promise<McpContent>
    ): void {
      server.registerTool(
        name,
        {
          description,
          inputSchema,
          outputSchema,
          annotations: TOOL_ANNOTATIONS,
        },
        async (params: any) => {
          if (!client) {
            return {
              content: [{ type: "text" as const, text: MISSING_KEY_MESSAGE }],
              isError: true,
            };
          }
          try {
            return await handler(params);
          } catch (err) {
            const error = err instanceof OxArchiveError ? err : new OxArchiveError(String(err), 500);
            return formatError(error);
          }
        }
      );
    }
  • LighterCoinParam schema used by the single-instrument variant (get_lighter_instrument), but not by get_lighter_instruments which takes no params.
    const LighterCoinParam = z
      .string()
      .describe("Lighter.xyz coin symbol, e.g. 'BTC', 'ETH'");
Behavior4/5

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

Annotations already declare readOnlyHint=true, destructiveHint=false, idempotentHint=true, and openWorldHint=true, covering safety and idempotency. The description adds value by specifying the exact data fields returned and the purpose (discovering valid symbols), but does not mention pagination or rate limits, which are minor gaps.

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; no wasted words. Purpose and content are front-loaded, making it easy to scan.

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

Completeness5/5

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

For a simple list tool with no parameters and a rich annotation set, the description is complete. It conveys what the tool returns, its purpose, and is sufficient for an agent to decide when to use it.

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?

No parameters exist, so schema description coverage is 100%. The description does not need to explain parameters. Baseline for zero parameters is 4, and the description adds no extra param info, which is appropriate.

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 it lists all available Lighter.xyz instruments with specific fields (market IDs, fees, decimals, active status) and explicitly says 'Use this to discover valid Lighter symbols.' This differentiates it from sibling instrument list tools (e.g., get_instruments, get_hip3_instruments) by specifying the Lighter.xyz 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?

The description implies usage for discovering Lighter symbols but does not provide explicit guidance on when not to use it or alternatives. Among many sibling instrument tools, no comparison is given, leaving the agent to infer context.

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