Skip to main content
Glama

Zotero Create Annotation

zotero_create_annotation

Create highlights, area boxes, or sticky notes on PDF/EPUB attachments in Zotero MCP by specifying text, rect, or note mode for page annotations.

Instructions

Create an annotation on a PDF attachment (EPUB: highlights only). Exactly one mode per call: text= HIGHLIGHTS selectable text; rect= draws an AREA box over a figure, table, or other non-text region (PDF only); note=[x, y] places a STICKY NOTE centered on that normalized point, its text in comment (PDF only). Passing several or none is an error. attachment_key: the PDF/EPUB attachment key, NOT the parent item key (zotero_get_item_children finds it). page: 1-indexed page (EPUB: 1-indexed chapter). text: exact text to highlight, matched against the text layer — scanned/image-only PDFs will not match. rect: [x, y, width, height] normalized to [0, 1], with (0, 0) at the page's top-left; width/height are page-relative and the box must fit the page. Call zotero_get_page_layout first and reuse a detected region's bbox instead of guessing coordinates. comment, color (hex, default '#ffd400'), tags: optional. Requires PyMuPDF (the [pdf] extra) and a writable library: local writes (Zotero 10+) or a web API key. Examples: (attachment_key='NHZFE5A7', page=4, text='working memory'); (attachment_key='NHZFE5A7', page=7, rect=[0.15, 0.22, 0.6, 0.35], comment='Figure 3').

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
noteNo
pageYes
rectNo
tagsNo
textNo
colorNo#ffd400
commentNo
attachment_keyYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.9/5.0
Behavior5/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure and succeeds: it states the PyMuPDF dependency (the [pdf] extra), the writable-library requirement (local writes Zotero 10+ or web API key), the scanned/image-only PDF text-matching limitation, the EPUB highlights-only constraint, and the rect-must-fit-page rule. For a mutation tool with zero annotation coverage this is comprehensive and honest.

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?

The description is long, but length is justified by 8 parameters with 0% schema coverage and a three-mode API. It is front-loaded with the core purpose and mode distinction, and the trailing examples clarify exact argument formats. Minor redundancy exists between the parameter prose and the examples, which could have been trimmed, so it falls just short of a 5.

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?

Given the tool's complexity (3 modes, EPUB/PDF differences, normalized coordinates, prerequisites) the description is essentially complete. The output schema already covers return values, so no return-format prose is needed. Missing items are negligible: the description covers prerequisites, error conditions, coordinate conventions, limitations, and provides concrete examples.

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 description coverage is 0%, so the description must fully compensate, and it does: it explains attachment_key is the attachment key NOT the parent item key, page is 1-indexed (chapter for EPUB), text matches the text layer exactly, rect is normalized [x,y,width,height] with (0,0) at top-left and page-relative dims, note is a normalized [x,y] point with text in comment, plus color default and tags. Every one of the 8 parameters is semantically covered in prose.

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-resource pair ('Create an annotation on a PDF attachment') and immediately distinguishes three mutually exclusive modes (text, rect, note) with clear semantics for each. It differentiates cleanly from siblings like zotero_get_annotations (read), zotero_update_annotation (modify), and zotero_delete_annotation (delete), so an agent can select this tool unambiguously.

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?

The description explicitly routes to sibling tools for correct usage: it names zotero_get_item_children for finding the attachment key and instructs the agent to call zotero_get_page_layout first and reuse a detected bbox instead of guessing coordinates. It also spells out the error condition ('Passing several or none is an error') and the EPUB-vs-PDF applicability split, giving the agent clear when/how guidance.

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