Skip to main content
Glama
Ganjoor MCP Server

Ganjoor MCP Server

Official
by ganjoor

Get Ganjoor Poem Verses

ganjoor_get_poem_verses
Read-onlyIdempotent

Fetches ordered verses for a poem by ID, with optional single-couplet filtering, so you can return just the verse text needed instead of the complete poem.

Instructions

Get just the verses of a poem by id — a lightweight alternative to fetching the whole poem.

Each verse comes back in order with its couplet index and whether it is the first or second hemi- stich. Optionally restrict to a single couplet.

Args:

  • poem_id (number): Numeric poem id

  • couplet_index (number): Return only this couplet (0-based). Omit for the whole poem.

  • include_summary (boolean): Include the per-couplet prose summary (default: false)

  • include_original_text (boolean): Include the uncorrected original text where available (default: false)

  • response_format ('markdown' | 'json'): Output format (default: 'markdown')

Returns: For JSON: { poem_id, verse_count, verses: [{ id, order, couplet_index, position, text }] }

Examples:

  • "Quote the verses of poem 2623" -> poem_id=2623

  • "Show only couplet 3" -> poem_id=2623, couplet_index=3

Notes:

  • Position 0 is the first hemistich, position 1 the second; couplet_index groups them.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "poem_id": "<poem_id>"
    },
    "name": "ganjoor_get_poem_verses"
  }
}

Input Schema

NameRequiredDescriptionDefault
poem_idYesNumeric poem id.
couplet_indexNoReturn only this 0-based couplet. Omit to get the whole poem.
include_summaryNoInclude the modern Persian summary attached to each couplet.
response_formatNoOutput format: 'markdown' for human-readable text (default) or 'json' for machine-readable structured data.markdown
include_original_textNoInclude the pre-correction original text where the API has it.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.1

TDQS

A4.1/5.0
Behavior4/5

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

Annotations already declare readOnly/idempotent/non-destructive/openWorld, so safety is covered. The description adds real behavioral context beyond that: verses are returned in order with couplet index and hemistich position, and couplet filtering narrows scope. It omits things like pagination or size limits for very long poems, which keeps it from a 5.

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?

Front-loaded summary followed by Args/Returns/Examples/Notes is easy to scan. The Args section duplicates schema text and could be trimmed, but no sentence is actively wasteful.

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?

With no output schema, the description supplies the JSON return shape and the position/hemistich semantics, which is the key missing piece. It only documents the JSON shape and not the markdown output, a minor gap for a five-parameter read tool.

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 coverage is 100% and the Args block largely restates the schema descriptions verbatim, adding little new meaning. The genuine added value is the couplet_index example and the 0-based clarification, which is already present in the schema.

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 (get the verses of a poem by id) and immediately positions it against the sibling that fetches the complete poem. An agent can tell it apart from ganjoor_get_poem without reading either schema.

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 'lightweight alternative to fetching the whole poem' framing plus the two examples ('Quote the verses of poem 2623', 'Show only couplet 3') give clear conditions for selection. It stops short of naming the specific sibling tool to use instead, leaving that mapping to inference.

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