Skip to main content
Glama
anki-connect-mcp
by SolarianGG

statistics.getHtml

statistics_getHtml
Read-only

Retrieve Anki's supported legacy HTML statistics report for a whole collection or a specific deck. Use it to read study stats in HTML form from the collection.

Instructions

Return the supported legacy HTML report, labelled as such.

Anki-Connect method statistics.getHtml. Scope: collection. Effect: read. Completion: completed. Undo: none.

Possible errors: collectionUnavailable, internalError, invalidParams, notFound, staleSession.

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": "statistics_getHtml"
  }
}

Input Schema

NameRequiredDescriptionDefault
deckNoDeck (with subdecks): exactly one of {"id": "<deckId>"} or {"name": "<full deck name, e.g. Japanese::Verbs>"}. Omit for the whole collection.
sessionNoOptional. Collection session ID: the `session` field returned by `collection_get`. Usually omit it — the server then uses the session current at the time of the call. Pass it to make the call fail with `staleSession` instead of acting on a different profile/collection than the one your IDs, cursors and tokens came from.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.1/5.0
Behavior4/5

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

Beyond the readOnly/destructive annotations, the description discloses scope, the fact that completion is awaited, that there is no undo effect, and an explicit set of failure modes including collectionUnavailable and staleSession. That is meaningful operational context an agent can act on. It stops short of describing the shape or size of the returned report, which is the remaining behavioral gap.

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 statement, then compact labelled metadata (scope, effect, completion, undo) and an error list. The templated fields are efficient rather than wasteful, though the method-name line duplicates the tool title/name.

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?

For a zero-required-parameter read tool with no output schema, the description covers errors and safety but leaves the return value underspecified — an agent does not learn whether it gets an HTML string, a URL, or a structured object, nor how large the payload may be. That is the one omission that matters for calling it correctly.

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 100%, with the deck union and session semantics fully documented inline, so the baseline is 3. The description adds nothing further about the deck selector or session token beyond repeating the method signature metadata.

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

Purpose3/5

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

The verb and resource are present ("Return the ... legacy HTML report"), and the title ties it to statistics. But "the supported legacy HTML report" never says what the report actually contains (decks/collection statistics?) nor how it differs from the sibling statistics_getSummary, so an agent can't confidently distinguish the two from the description alone.

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?

Only "Scope: collection" is offered; there is no statement of when to prefer this over statistics_getSummary or statistics_getToday, and no note on when the legacy HTML form is appropriate versus structured data. The reader must infer usage entirely from the name.

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