Skip to main content
Glama

get_palette

Read-only

Reads a sprite's color palette and returns its entries as hex values. Reports the 1-based transparent index for indexed sprites.

Instructions

The sprite's palette as '#rrggbb' colours ('#rrggbbaa' when not opaque).

Indexed sprites also report transparent_index, the 1-based entry that is transparent on normal layers.

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": {
      "path": "<path>"
    },
    "name": "get_palette"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYesSprite file. Relative paths resolve against the server root.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.5/5.0
Behavior4/5

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

The readOnlyHint=true annotation already establishes this as a safe read, so the description's added value is in behavioral detail about output: colours are hex-encoded, alpha is appended only when the colour is not fully opaque, and indexed sprites additionally report a 1-based transparent_index that applies on normal layers. That 1-based convention and the layer-scoping caveat are exactly the kind of detail structured fields rarely carry. It stops short of noting any size or performance characteristics, but nothing is contradicted.

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?

Two short sentences with no filler, and the primary output contract is front-loaded before the indexed-sprite caveat. The stray leading line break and parenthetical nesting are minor formatting blemishes rather than wasted content.

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?

With an output schema present, the description need not enumerate return fields, and the single input parameter is fully documented in the schema. What remains is adequately covered: format of returned colours and the conditional transparent_index. Only the absence of sibling disambiguation keeps it from being fully self-sufficient.

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?

The schema covers its single 'path' parameter at 100%, including the note that relative paths resolve against the server root, so the description does not need to re-explain it. The description adds no parameter detail of its own; the baseline 3 applies when the schema does the work.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a specific resource (the sprite's palette) and its exact output encoding ('#rrggbb', with '#rrggbbaa' for non-opaque entries), plus the extra transparent_index field for indexed sprites. It does not, however, distinguish itself from the sibling extract_palette or set_palette, so an agent cannot tell from this text alone which palette tool to reach for.

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

Usage Guidelines2/5

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

There is no when-to-use or when-not-to-use guidance, no mention of the read-only nature as a selection criterion, and no reference to alternatives such as extract_palette (likely a derived palette) or set_palette (the mutating counterpart). The agent must infer usage purely from the name and the return-format notes.

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