Skip to main content
Glama
54yyyu
by 54yyyu

zotero_advanced_search

Run advanced Zotero searches with multiple field conditions joined by AND/OR, enabling precise filtering by date ranges, item types, creators, and other metadata.

Instructions

Advanced item search with multiple structured-field conditions joined by AND or OR. Use this when you need to filter by fields that zotero_search_items and zotero_search_by_tag can't express (date ranges, specific itemTypes, etc.). For plain text use zotero_search_items; for tags use zotero_search_by_tag; for topic discovery use zotero_semantic_search. conditions: list of {field, operation, value} dicts (also accepts a JSON string). Common fields: title, creator, date, dateAdded, dateModified, tag, itemType, publicationTitle, abstractNote, collection. Supported operations (exhaustive): is, isNot, contains, doesNotContain, beginsWith, endsWith, isGreaterThan, isLessThan, isBefore, isAfter. For 'added in the last N days', use field='dateAdded' with operation='isAfter' and an ISO date value (e.g. '2026-03-22'). join_mode: 'all' (AND, default) or 'any' (OR). sort_by: dateAdded, dateModified, title, creator, etc. sort_direction: 'asc' (default) or 'desc'. limit: max results (default 50, max 500). include_subcollections: make a 'collection' condition match items anywhere in that collection's subtree, for the is/isNot operations (default False). search_all_libraries: search every accessible library at once, labelling each result with its library; needs ZOTERO_SEARCH_BACKEND=sqlite. 'tag' conditions work; 'collection' conditions and include_subcollections do not. Example: zotero_advanced_search(conditions=[{'field': 'itemType', 'operation': 'is', 'value': 'preprint'}, {'field': 'dateAdded', 'operation': 'isAfter', 'value': '2026-03-22'}], join_mode='all').

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
limitNoMaximum number of results to return
sort_byNoField to sort by (dateAdded, dateModified, title, creator, etc.)
join_modeNoWhether all conditions must match ("all") or any condition can match ("any")all
conditionsYesList of search condition dictionaries, each containing: - field: The field to search (title, creator, date, tag, etc.) - operation: The operation to perform (is, isNot, contains, etc.) - value: The value to search for
sort_directionNoDirection to sort (asc or desc)asc
search_all_librariesNoSearch every accessible library at once instead of the active one (#163). Requires the SQLite backend; each result is labelled with its source library. A `collection` condition is rejected in this mode — collection keys are per-library — while `tag` conditions work, since Zotero stores tags in one database-wide table shared by every library.
include_subcollectionsNoMake a `collection` condition match items filed anywhere in that collection's subtree rather than in it directly. Applies to the `is` and `isNot` operations, which are the membership questions; other operators keep comparing keys as before. Defaults to False, matching Zotero's own "Search subcollections" checkbox.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Install Server

TDQS

A4.9/5.0
Behavior5/5

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

No annotations are present, so the description carries the full burden — and it delivers: the search_all_libraries mode limitation ('tag' conditions work; 'collection' conditions and include_subcollections do not), the ZOTERO_SEARCH_BACKEND=sqlite prerequisite, defaults (join_mode 'all', sort_direction 'asc', limit 50/max 500), the dateAdded+isAfter workaround for 'last N days', and an exhaustive operation list with a worked example.

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?

Long, but information-dense: purpose and sibling routing are front-loaded, and the closing example earns its place. However, the parameter rundown is one long semicolon-packed passage that partially overlaps the schema descriptions, so it is not maximally crisp.

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

Completeness5/5

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

For a 7-parameter tool with no annotations and an output schema present, the description covers purpose, sibling routing, every parameter's semantics, mode-specific caveats, defaults, hard limits, and a worked example — everything an agent needs to invoke it correctly. The only slight ambiguity ('collection' conditions and include_subcollections do not) is scoped by context to search_all_libraries mode.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, giving a baseline of 3, but the description adds substantial meaning beyond the schema: the exhaustive operation vocabulary (schema only says 'etc.'), the concrete common-field list (title, creator, date, dateAdded, tag, itemType, publicationTitle, abstractNote, collection), the limit max of 500 (schema only gives default 50), the include_subcollections is/isNot scope clarification, and a complete example call.

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

Purpose5/5

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

States a specific verb and resource ('Advanced item search') with an immediate differentiator: multiple structured-field conditions joined by AND/OR. It names the sibling tools it is not ('filter by fields that zotero_search_items and zotero_search_by_tag can't express (date ranges, specific itemTypes, etc.)') and enumerates common fields and operations, so an agent can identify it without opening a schema.

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

Usage Guidelines5/5

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

Explicitly routes usage: 'Use this when you need to filter by fields that zotero_search_items and zotero_search_by_tag can't express', then names each alternative with its condition ('For plain text use zotero_search_items; for tags use zotero_search_by_tag; for topic discovery use zotero_semantic_search'). Also flags the SQLite backend prerequisite for search_all_libraries, which is critical when-to-use information.

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

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/54yyyu/zotero-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server