Skip to main content
Glama

Add To Collection

add_to_collection

Add an existing Zotero item to a collection using its item key and collection ID. Organize your Zotero library by placing papers and books into the right collections.

Instructions

Add an existing Zotero item to a collection.

Args: item_key: The Zotero item key (from search results) collection_id: The collection key to add it to

Pass both library_id and library_type to target another library; omit both to use the configured default.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
item_keyYes
library_idNo
library_typeNo
collection_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.10.0
    • addedInput schema / properties / library_id
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Library Id"
      +}
    • addedInput schema / properties / library_type
      Added value: +{
      +  "anyOf": [
      +    {
      +      "enum": [
      +        "user",
      +        "group"
      +      ],
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Library Type"
      +}
  2. First observedv0.9.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations indicate this is a write operation (readOnlyHint=false) and not destructive, so the description does not need to restate that. It adds useful behavioral context beyond annotations: the item must already exist, the operation targets collection membership, and library selection follows the both-or-omit rule. It does not discuss duplicate-association behavior, but that is a minor gap given the annotations.

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

Conciseness5/5

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

The description is compact and front-loaded: the purpose appears in the first sentence, followed by a terse Args block and the library-targeting rule. Every sentence earns its place with no filler or repetition.

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?

The description covers the required parameters, the optional library-targeting behavior, and the default fallback, which is sufficient for a simple mutation tool. It omits edge-case behavior like what happens if the item is already in the collection, but the presence of an output schema and clear annotations minimizes the missing context.

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

Parameters4/5

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

Schema description coverage is 0%, so the description carries the burden of explaining parameters. It defines item_key as a Zotero item key from search results, collection_id as the collection key, and explains library_id/library_type pairing for targeting another library. It does not detail library_id's exact value format, but it provides enough semantic grounding for the four parameters.

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?

The description opens with a specific verb and resource: 'Add an existing Zotero item to a collection.' The word 'existing' clarifies that this is about associating an already-present item rather than creating a new library item, distinguishing it from creation-oriented siblings like add_paper_by_doi and add_book_by_isbn.

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

Usage Guidelines4/5

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

The description gives concrete usage context: item_key comes from search results and collection_id is the collection key. It also states the library-targeting rule clearly: pass both library_id and library_type to use another library, or omit both for the default. It does not name alternatives or exclusions, but the intended use is explicit.

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