Skip to main content
Glama

Get library stats

get_stats
Read-onlyIdempotent

Get collection statistics including progress, rating distribution, genre/theme breakdown, and timeline. If no media_type specified, returns combined stats.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "get_stats"
  }
}

Input Schema

NameRequiredDescriptionDefault
media_typeNoType of media (optional - omit for all)

Output Schema

NameRequiredDescriptionDefault
by_ratingNo
by_statusNo
top_genresNo
top_themesNo
total_itemsYes
by_media_typeNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / media_type / enum
      Previous value: -[
      -  "book",
      -  "movie",
      -  "album",
      -  "show",
      -  "anime",
      -  "podcast",
      -  "game",
      -  "manga",
      -  "comic"
      -]New value: +[
      +  "book",
      +  "movie",
      +  "album",
      +  "show",
      +  "anime",
      +  "podcast",
      +  "game",
      +  "manga",
      +  "comic",
      +  "boardgame"
      +]
  2. Changed1 schema field changed
    • changedInput schema / properties / media_type / enum
      Previous value: -[
      -  "book",
      -  "movie",
      -  "album",
      -  "show",
      -  "anime",
      -  "podcast",
      -  "game",
      -  "manga"
      -]New value: +[
      +  "book",
      +  "movie",
      +  "album",
      +  "show",
      +  "anime",
      +  "podcast",
      +  "game",
      +  "manga",
      +  "comic"
      +]
  3. Changed2 schema fields changed
    • changedInput schema / properties / media_type / enum
      Previous value: -[
      -  "book",
      -  "movie",
      -  "album",
      -  "show",
      -  "anime"
      -]New value: +[
      +  "book",
      +  "movie",
      +  "album",
      +  "show",
      +  "anime",
      +  "podcast",
      +  "game",
      +  "manga"
      +]
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "description": "Aggregate statistics for the user's collection.",
      +  "properties": {
      +    "by_media_type": {
      +      "additionalProperties": true,
      +      "properties": {
      +        "albums": {
      +          "type": "number"
      +        },
      +        "anime": {
      +          "type": "number"
      +        },
      +        "books": {
      +          "type": "number"
      +        },
      +        "games": {
      +          "type": "number"
      +        },
      +        "movies": {
      +          "type": "number"
      +        },
      +        "podcasts": {
      +          "type": "number"
      +        },
      +        "shows": {
      +          "type": "number"
      +        }
      +      },
      +      "type": "object"
      +    },
      +    "by_rating": {
      +      "additionalProperties": {
      +        "type": "number"
      +      },
      +      "type": "object"
      +    },
      +    "by_status": {
      +      "additionalProperties": {
      +        "type": "number"
      +      },
      +      "type": "object"
      +    },
      +    "top_genres": {
      +      "items": {
      +        "additionalProperties": true,
      +        "properties": {
      +          "count": {
      +            "type": "number"
      +          },
      +          "genre": {
      +            "type": "string"
      +          }
      +        },
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "top_themes": {
      +      "items": {
      +        "additionalProperties": true,
      +        "properties": {
      +          "count": {
      +            "type": "number"
      +          },
      +          "theme": {
      +            "type": "string"
      +          }
      +        },
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "total_items": {
      +      "type": "number"
      +    }
      +  },
      +  "required": [
      +    "total_items"
      +  ],
      +  "type": "object"
      +}
  4. First observed

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and openWorldHint=false, so safety behavior is fully covered by structured data. The description adds the aggregation fallback ('returns combined stats'), but the schema already states 'omit for all', making that addition largely redundant. Nothing about pagination, rate limits, or cost is disclosed.

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 sentences, front-loaded with the payload description and followed by the default-behavior caveat. Every clause carries information, though the second sentence retreads ground already covered by the parameter's schema description.

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?

For a single-optional-parameter read tool with an output schema, the definition covers purpose, scope, and default aggregation. Return-value shape need not be explained because an output schema exists, so the remaining gap is only the lack of routing guidance versus sibling stats tools.

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?

There is a single optional parameter with 100% schema description coverage and an enum of ten media types, so the schema already fully documents its meaning and legal values. The description's echo of the omit-for-all behavior adds no new semantics, so the baseline 3 applies.

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 names a specific verb ('Get') and resource ('collection statistics') and enumerates the content returned: progress, rating distribution, genre/theme breakdown, and timeline. That is enough for an agent to distinguish it from narrower siblings like get_charts or get_timeline, though it never explicitly contrasts itself with them.

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 only implied: an agent can infer this is the aggregate-statistics tool and that leaving media_type blank gives library-wide numbers. There is no explicit guidance about when to prefer get_charts, get_timeline, or get_taste instead, so the choice among the stats-oriented siblings is left to inference.

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