Skip to main content
Glama
This connector has been deprecated

Get book or author details

shamela_get_details
Read-onlyIdempotent

Catalogue record for one book (kind=book, default) or one author (kind=author), installed or not.

  • book: authors, category, type, printed-edition flag, whether the text is installed here, the scanned printing and the other editions of the same work (same_group). When a reader tool says BOOK_NOT_DOWNLOADED, pick an installed entry from same_group or answer from this record. Read book_date, edition, editor and publisher per their field notes: never supply a missing one.

  • author: name, Hijri death year (null = unknown or living) and every catalogued book they wrote or co-wrote, each flagged installed or not. Volumes → shamela_read(unit='parts'); a book by title or subject → shamela_find(kind='book'). Errors: BOOK_NOT_FOUND, AUTHOR_NOT_FOUND.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "shamela_get_details"
  }
}

Input Schema

NameRequiredDescriptionDefault
kindNoSelects what the call does: book | author. Default book.
book_idNoThe book id (e.g. 9942). (kind=book only.)
author_idNoThe author id (e.g. 474 for Ibn Qudama, 57 for Ibn Uthaymeen), from shamela_find(kind='name') with type 'author' or a book's authors[]. A catalogue id, not a death year or book id; shamela_find(kind='author') also gives it. (kind=author only.)
include_booksNoIf true (default), include every catalogued book by this author, main or co-author, ordered by book_id. False returns name and death year only. (kind=author only.)
include_coverNoAttach the book's cover image as an MCP image block when Shamela ships one (1,368 of 8,594 books). The picture is a ~310x460 thumbnail of the scanned printing's title page, so it costs roughly 190 image tokens. Set false to keep the reply text-only; `cover.available` still reports whether one exists. Default: true. (kind=book only.)
response_formatNoFormat of the human-readable text: 'markdown' (default) for display; 'json' the same data as one JSON code block; 'none' only a one-line pointer, leaving structuredContent as the whole answer. structuredContent is always returned, so a caller that parses it should pass 'none': the character budget counts both channels, and the unread copy otherwise spends most of it. Requires the 'response_format.none' capability (see shamela_get_brief).

Output Schema

NameRequiredDescriptionDefault
scanNoThe scanned printing Shamela holds; null when none. (kind=book only.)
booksNoThe author's books by ascending book_id; empty when include_books is false. (kind=author only.)
coverNoTitle-page thumbnail of the scanned printing; null when none. Says nothing about the real binding or whether a scan exists (377 books have a `scan` but no cover): read `scan`. (kind=book only.)
notesNoCaveats, including citation fields the catalogue lacks. (kind=book only.)
editorNoEditor (محقق) from the front matter; null when absent. (kind=book only.)
authorsNoAuthors, main author first. (kind=book only.)
book_idNoCatalogue book id. (kind=book only.)
editionNoEdition read from the book's front matter; null when absent. Never invent one. (kind=book only.)
printedNo1 when page numbers follow a printed edition; otherwise Shamela numbers the pages itself. (kind=book only.)
categoryNoCategory name. (kind=book only.)
author_idNoAuthor id. (kind=author only.)
availableNoTrue when Shamela offers the book for download. (kind=book only.)
book_dateNoShamela «تاريخ الكتاب», Hijri; on 98.5% of dated books the main author's death year, not a composition year: never cite it as one. (kind=book only.)
book_nameNoCatalogue title of the book (Arabic). (kind=book only.)
book_typeNoNumeric book type. (kind=book only.)
pdf_linksNoRaw scan descriptor from the catalogue; prefer `scan`. (kind=book only.)
publisherNoPublisher from the front matter; null when absent. (kind=book only.)
sub_booksNoCatalogue ids of books bound inside this one. (kind=book only.)
truncatedNo
book_countNoNumber of catalogue books (main or co-author). (kind=author only.)
death_textNoDeath date as display text. (kind=author only.)
death_yearNoHijri death year; null when unknown or living. (kind=author only.)
downloadedNoTrue only when the text is installed on this server and has pages. (kind=book only.)
same_groupNoOther catalogue entries of the same work (editions, abridgments: Sahih al-Bukhari is 8, five editions and three abridgments). Quotes from two of them are one source. (kind=book only.)
author_nameNoAuthor name. (kind=author only.)
category_idNoCategory id (see shamela_find(kind='category')). (kind=book only.)
rows_droppedNo
content_statusNo'readable', 'downloaded_no_pages' or 'not_downloaded'. (kind=book only.)
book_type_labelNoBook type in Arabic: printed, manuscript, journal, thesis, electronic or audio. (kind=book only.)
publication_dateNoHijri publication date, DDMMYYYY, from meta_data, when recorded. (kind=book only.)
truncation_messageNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already cover read-only/idempotent/non-destructive, but the description adds substantial context beyond them: the error codes, the null-means-unknown semantics for death year, the instruction never to supply a missing bibliographic field, cover-image token cost, and the response_format.none capability requirement.

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 purpose followed by tight kind-scoped bullets; the routing line and error list are the only additions. Dense but nearly every clause carries information, though the record-field detail leans on the output schema's territory.

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 an output schema present the description needn't re-explain return values, yet it covers the decision context (installed vs not, same_group fallback), failure codes, and field-interpretation caveats. Nothing an agent needs to invoke this correctly is missing.

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 description coverage is 100% and the schema already documents kind, book_id, author_id, include_books, include_cover and response_format in detail. The description reinforces defaults ('kind=book, default', 'installed or not') but adds little parameter syntax beyond what the schema provides, so the baseline 3 is appropriate.

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?

Opens with a specific verb+resource ('Catalogue record for one book ... or one author'), and the kind=book/kind=author bullets enumerate exactly what each mode returns. It distinguishes itself from siblings by noting shamela_read handles volumes and shamela_find handles title/subject lookups.

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?

Explicit when-to-use guidance: 'When a reader tool says BOOK_NOT_DOWNLOADED, pick an installed entry from same_group or answer from this record.' It also routes two adjacent cases to shamela_read(unit='parts') and shamela_find(kind='book'), and names the two error codes that signal this tool's failure modes.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources