Skip to main content
Glama

Server-rendered bibliography (library items)

zotero_bibliography
Read-only

Generate a formatted bibliography from Zotero library items using CSL styles like APA or Chicago, with options for locale and link wrapping.

Instructions

Produce a formatted bibliography for items already in a Zotero library, rendered server-side by Zotero in a CSL style (by the desktop app for a library it serves, so no cloud key is needed there; otherwise by the Web API). Provide item_keys and optionally style (a name such as "apa" or "chicago author-date", or a CSL id; unset renders Zotero's default, chicago-shortened-notes-bibliography), locale, and linkwrap. Returns XHTML. Note: this endpoint is item-only and capped at 150 items. For arbitrary CSL-JSON or items not in the library, use zotero_format_bibliography instead.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
styleNoStyle name or CSL id.
localeNoLocale (e.g. en-US).
linkwrapNoWrap URLs/DOIs in links.
item_keysYesLibrary item keys (max 150).
library_idNoNumeric id of the library to address, e.g. 5234875 for a group (zotero_groups lists the ids you can reach). Omit to use the configured default library; an id given without library_type is read as a group id.
library_typeNoWhich library to address: "user" (a personal library) or "group" (a shared group library). Omit to use the library this server is configured for. "group" on its own is refused: pass library_id with it.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
noteNoPresent when fewer entries rendered than keys were asked for, and why that happens.
styleYesThe CSL style Zotero rendered in; "chicago-shortened-notes-bibliography" is the default when `style` was unset.
entryCountYesEntries Zotero actually rendered, counted from the XHTML.
bibliographyYesThe rendered XHTML.
requestedCountYesKeys the call asked for. A key the library does not have, or a child item, renders nothing.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.21.0
    • addedInput schema / properties / library_id / exclusiveMinimum
      Added value: +0
  2. Changed2 schema fields changedv1.20.2
    • removedInput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
    • removedOutput schema / $schema
      Removed value: -"http://json-schema.org/draft-07/schema#"
  3. Changed3 schema fields changedv1.20.0
    • addedInput schema / properties / library_id / description
      Added value: +"Numeric id of the library to address, e.g. 5234875 for a group (zotero_groups lists the ids you can reach). Omit to use the configured default library; an id given without library_type is read as a group id."
    • addedInput schema / properties / library_type / description
      Added value: +"Which library to address: \"user\" (a personal library) or \"group\" (a shared group library). Omit to use the library this server is configured for. \"group\" on its own is refused: pass library_id with it."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": true,
      +  "properties": {
      +    "bibliography": {
      +      "description": "The rendered XHTML.",
      +      "type": "string"
      +    },
      +    "entryCount": {
      +      "description": "Entries Zotero actually rendered, counted from the XHTML.",
      +      "type": "number"
      +    },
      +    "note": {
      +      "description": "Present when fewer entries rendered than keys were asked for, and why that happens.",
      +      "type": "string"
      +    },
      +    "requestedCount": {
      +      "description": "Keys the call asked for. A key the library does not have, or a child item, renders nothing.",
      +      "type": "number"
      +    },
      +    "style": {
      +      "description": "The CSL style Zotero rendered in; \"chicago-shortened-notes-bibliography\" is the default when `style` was unset.",
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "style",
      +    "entryCount",
      +    "requestedCount",
      +    "bibliography"
      +  ],
      +  "type": "object"
      +}
  4. First observedv1.0.4

TDQS

A4.9/5.0
Behavior5/5

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

Beyond the readOnlyHint/openWorldHint annotations, the description adds meaningful behavioral context: server-side rendering, desktop versus Web API execution, default style when none is supplied, XHTML return format, item-only endpoint, and the 150-item cap. No contradiction with annotations exists.

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 dense but every clause earns its place: core action, rendering mode, optional parameters with defaults, output format, constraint, and alternative tool. The key scoping information is front-loaded, and the sibling routing is placed at the end in a clear note.

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?

With full schema coverage, a rich input schema, an output schema, and read-only annotations, the description completes the picture by adding the CSL rendering detail, default style, XHTML return, and the explicit 150-item constraint. An agent has enough to invoke this tool correctly and to route non-library cases to zotero_format_bibliography.

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 100%, so the baseline is 3. The description adds extra meaning for key parameters: style accepts names such as 'apa' or 'chicago author-date' or a CSL id, and omitting it invokes Zotero's default style. It also reinforces item_keys and the 150-item limit, going slightly beyond the schema alone.

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: 'Produce a formatted bibliography for items already in a Zotero library'. It clearly identifies the server-side CSL rendering behavior and explicitly distinguishes itself from zotero_format_bibliography at the end, making sibling differentiation easy.

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 states precisely when to use this tool (items already in a Zotero library) and gives an explicit exclusion: 'For arbitrary CSL-JSON or items not in the library, use zotero_format_bibliography instead.' It also notes the 150-item cap and rendering context, so an agent can decide between this and related tools without ambiguity.

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