Skip to main content
Glama

lookup_error

Decode a Solana program error code by hex or decimal to get each program's meaning, likely causes, fixes, and an example log line, including cross-program collisions.

Instructions

Look up a Solana program error code by hex (0x1773) or decimal (6003). Returns every program's meaning for that code — cross-program collisions included — with likely causes, fixes and an example log line for each. Covers Jupiter, Raydium (CPMM/CLMM/AMM v4/LaunchLab), Orca, Meteora (DLMM/AMM), pump.fun, SPL Token, Token-2022.

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": {
      "code": "<code>"
    },
    "name": "lookup_error"
  }
}

Input Schema

NameRequiredDescriptionDefault
codeYesError code in hex (0x1773) or decimal (6003)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.9/5.0
Behavior4/5

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

With no annotations provided the description carries the full burden, and it does disclose the important behavior: results are cross-program and include collisions, plus likely causes, fixes, and an example log line per match. It doesn't cover failure modes (unknown code) or output structure details, which keeps it short of a 5.

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?

Front-loaded with the core action and input format in the first sentence, with output expectations second. The trailing program enumeration is long but functions as coverage keywords; slightly list-heavy but nothing is wasted.

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?

No output schema and no annotations, so the description must explain what comes back — and it does, naming the per-program meanings, causes, fixes, and sample log line. Sufficient for a single-parameter lookup tool, though failure/unmatched-code behavior is unaddressed.

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?

Only one parameter, and schema coverage is 100% — the schema already documents 'code' with the exact same hex (0x1773) and decimal (6003) examples the description repeats. So the description adds no meaning beyond the schema; baseline 3 applies.

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?

States a specific verb (look up) and resource (Solana program error code) plus the two accepted input encodings, and the program list scopes exactly what domains it covers, which separates it from siblings like decode_log.

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?

Usage is implied by the input format examples (hex/decimal error codes), so an agent can infer this is the tool for resolving a numeric code. However, it never states when to prefer it over decode_log or list_programs, and no exclusions or prerequisites are given.

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

Deploy Server

Other Tools