Skip to main content
Glama

Search asset statistics

immich_search_asset_statistics

Retrieve asset statistics by search criteria, including total matching counts for photos, videos, or audio in Immich.

Instructions

Search asset statistics

Retrieve statistical data about assets based on search criteria, such as the total matching count.

Immich operation: POST /search/statistics · tag: Search

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ocrNoocr (request body)
cityNocity (request body)
makeNomake (request body)
typeNotype (request body)
modelNomodel (request body)
stateNostate (request body)
filterNofilter (request body)
ratingNorating (request body)
tagIdsNotagIds (request body)
countryNocountry (request body)
albumIdsNoalbumIds (request body)
isMotionNoisMotion (request body)
isEncodedNoisEncoded (request body)
isOfflineNoisOffline (request body)
lensModelNolensModel (request body)
libraryIdNolibraryId (request body)
personIdsNopersonIds (request body)
isFavoriteNoisFavorite (request body)
takenAfterNotakenAfter (request body)
visibilityNovisibility (request body)
descriptionNodescription (request body)
takenBeforeNotakenBefore (request body)
createdAfterNocreatedAfter (request body)
isNotInAlbumNoisNotInAlbum (request body)
trashedAfterNotrashedAfter (request body)
updatedAfterNoupdatedAfter (request body)
createdBeforeNocreatedBefore (request body)
trashedBeforeNotrashedBefore (request body)
updatedBeforeNoupdatedBefore (request body)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.6/5.0
Behavior1/5

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

The description states this is a 'Retrieve' operation returning counts, i.e. a pure read, while the annotations declare readOnlyHint=false. That is a direct inconsistency an agent could act on (e.g. treating a harmless statistics query as a mutating call). Aside from the contradiction it adds no auth, rate-limit, or scope context.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The body sentence is efficient, but the first line merely repeats the tool title verbatim and the trailing 'Immich operation: POST /search/statistics · tag: Search' is metadata padding. Roughly half the text earns its place, and the useful content is not front-loaded.

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

Completeness2/5

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

For a 29-parameter filter tool with no output schema, the description should at least outline what statistics come back; it mentions only 'total matching count'. Combined with the missing sibling differentiation and the annotation mismatch, the definition is not sufficient for confident invocation.

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 nominally 100%, but the descriptions are placeholders like 'city (request body)', so the schema does not really explain the 29 fields. The description says nothing about parameters beyond 'search criteria', so it neither compensates nor misleads. Baseline 3 for high coverage 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?

States a specific verb+resource ('Retrieve statistical data about assets') and clarifies the output is a count ('total matching count'). However, it never differentiates itself from near-identical siblings such as immich_get_asset_statistics, immich_get_album_statistics, or immich_search_assets, so an agent cannot tell which statistics tool to pick without opening schemas.

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?

The phrase 'based on search criteria' hints that this tool is the filterable variant, but there is no explicit when-to-use, when-not-to-use, or named alternative. With so many statistics and search siblings, the absence of routing guidance is a real gap.

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