Skip to main content
Glama

Browse the category tree

category_get_tree
Read-onlyIdempotent

Return a bounded category subtree. Use rootCategoryId and maxDepth to avoid loading the entire taxonomy. countryCode is a two-letter ISO country code and languageCode is a two-letter ISO language code; either may use uppercase or lowercase letters. Full locale tags such as en-US are not accepted. Both market fields are required.

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": {
      "countryCode": "<countryCode>",
      "languageCode": "<languageCode>"
    },
    "name": "category_get_tree"
  }
}

Input Schema

NameRequiredDescriptionDefault
maxDepthNo
maxNodesNo
countryCodeYesISO 3166-1 alpha-2 market country code; case-insensitive (for example, TH or th).
languageCodeYesISO 639-1 two-letter language code; case-insensitive (for example, en or EN). Do not pass a locale tag.
rootCategoryIdNo

Output Schema

NameRequiredDescriptionDefault
truncatedYes
categoriesYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • changedInput schema / properties / countryCode / description
      Previous value: -"ISO 3166-1 alpha-2 country code"New value: +"ISO 3166-1 alpha-2 market country code; case-insensitive (for example, TH or th)."
    • changedInput schema / properties / countryCode / pattern
      Previous value: -"^[A-Z]{2}$"New value: +"^[A-Za-z]{2}$"
    • changedInput schema / properties / languageCode / description
      Previous value: -"Lowercase two-letter language code"New value: +"ISO 639-1 two-letter language code; case-insensitive (for example, en or EN). Do not pass a locale tag."
    • changedInput schema / properties / languageCode / pattern
      Previous value: -"^[a-z]{2}$"New value: +"^[A-Za-z]{2}$"
  2. First observed

TDQS

A3.6/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint and openWorldHint=false, so the safety profile is covered. The description adds meaningful context the annotations do not: the response is deliberately bounded and callers should constrain depth to avoid pulling the whole taxonomy. It still omits whether a truncated result is flagged, which matters most for a bounded tool.

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?

Four sentences, front-loaded with the purpose, then the depth constraint, then input-format rules. No padding, though the locale-tag warning is delivered at greater length than its marginal value warrants.

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

Completeness3/5

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

An output schema exists, so return values need not be explained. However, for a tool whose defining trait is boundedness, the definition never says how an agent detects that the subtree was cut off by maxDepth or maxNodes, leaving a real gap given only 40% parameter coverage.

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 40%, and the description mainly restates what the schema already says about countryCode and languageCode, including the uppercase/lowercase permission and the locale-tag rejection. maxNodes is never explained, so the agent is not told how the node cap interacts with maxDepth or whether hitting it truncates silently.

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 opens with a specific verb and resource: 'Return a bounded category subtree.' That is clear, but it never names the obvious sibling category_search, so the agent must infer the browse-vs-search distinction from the word 'subtree' alone.

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?

'Use rootCategoryId and maxDepth to avoid loading the entire taxonomy' is parameter advice, not selection guidance. There is no statement of when to choose this over category_search or what happens if the taxonomy is large. Usage is implied rather than specified.

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