Zum Inhalt springen
The Library
of Alexandria

Developers

The library's catalogue, its free shelf and its print editions are open to programs, assistants and models as eight read-only tools. There is no key and nothing to sign up for. The tools never sign anyone in, take a payment or change anything: every title comes back with the address of its page on libraryofalexandria.com, where a person reads, listens, prints or starts.

Three ways in

  • MCP (Streamable HTTP) at https://loa-reading-service-live.tim-b26.workers.dev/mcp: for Claude, ChatGPT, Gemini, Grok, Copilot, Perplexity, Le Chat, LM Studio, Open WebUI, Cursor, VS Code, Goose and every other MCP client.
  • REST and OpenAPI 3.1: POST https://loa-reading-service-live.tim-b26.workers.dev/v1/<tool> and the OpenAPI file at https://loa-reading-service-live.tim-b26.workers.dev/v1/openapi.json: for scripts, automation tools (n8n, Zapier, Make, Dify, Flowise), Open WebUI tool servers and Copilot Studio.
  • Tool files for model makers: GET https://loa-reading-service-live.tim-b26.workers.dev/v1/tools?format=openai: for any program that passes tool definitions to a model. The formats are openai, openai-chat, anthropic, gemini, ollama and mcp.

Try it in a minute

curl -s https://loa-reading-service-live.tim-b26.workers.dev/v1/search_books \
  -H 'content-type: application/json' \
  -d '{"query":"moby dick","limit":3}'

The answer is {"ok": true, "data": {...}, "source": "Library of Alexandria, libraryofalexandria.com"}. Each title in data.results has an id, a title, an author and the url of its page.

The eight tools

  • search_books (query, language, limit): find titles by words from a title, an author or a topic, in any language of the catalogue.
  • get_book (id, language): the facts of one title: author, original title, cover, print editions and its page in each language.
  • get_summary (id, language, part): the first key idea of the 15-minute summary of one title in full, and the headings of the others.
  • get_sample (id, language, page): the free opening of one title, in pages of at most 400 words.
  • list_free_shelf (language, subject, limit): the titles on the free shelf, by language and subject.
  • read_free_chapter (id, chapter, page, language): one chapter of a free-shelf title, in pages of at most 400 words.
  • get_print_options (id, language): the print editions of one title (standard and large print, paperback or hardcover) with the US dollar price of each.
  • get_publisher_info: who publishes the library, its languages, the terms and the privacy page.

A summary, a sample page or a free-shelf chapter that is not open yet (a title, a language, or all texts before they go online) answers plainly that it opens here soon. It then fills in without any change on your side. There is no tool that returns a whole book: the tools return small, limited pieces, and count the words they hand out for each client (72,000 a day and 48,000 an hour; the answer shows what is left).

Connect an assistant

All eight tools only read, so any client may allow them without asking each time. The address is https://loa-reading-service-live.tim-b26.workers.dev/mcp.

  • Claude: Settings, Connectors, Add custom connector. In Claude Code: claude mcp add --transport http library-of-alexandria https://loa-reading-service-live.tim-b26.workers.dev/mcp
  • ChatGPT: open chatgpt.com/plugins, choose the plus button and Add custom MCP server, enter the address and create the plugin.
  • Cursor: add "library-of-alexandria": {"url": "https://loa-reading-service-live.tim-b26.workers.dev/mcp"} under mcpServers in ~/.cursor/mcp.json.
  • VS Code: run MCP: Add Server from the Command Palette, choose HTTP and enter the address.
  • LM Studio (0.3.17 or newer): Program tab, Install, Edit mcp.json, then add the same url entry under mcpServers.
  • Open WebUI (0.6.31 or newer): Settings, Admin, Integrations, External Tool Servers, Add Connection, type MCP (Streamable HTTP), the address, no authentication. Or choose the OpenAPI type and enter the address of the OpenAPI file.
  • OpenAI Responses API: pass {"type": "mcp", "server_label": "library", "server_url": "https://loa-reading-service-live.tim-b26.workers.dev/mcp", "allowed_tools": ["search_books", "get_book"], "require_approval": "never"} in tools.

Small local models do best with a short tool list: connect only the tools the task needs.

Call the REST API

Every tool is one operation, POST /v1/<tool>, with the tool's arguments as a JSON object and no key.

// JavaScript (Node 18 or newer, browsers, Deno, Bun, Workers)
const res = await fetch("https://loa-reading-service-live.tim-b26.workers.dev/v1/get_book", {
  method: "POST",
  headers: { "content-type": "application/json" },
  body: JSON.stringify({ id: "top3500-00002", language: "en" }),
});
const { ok, data } = await res.json();
console.log(data.title, data.url);
# Python, standard library only
import json, urllib.request

req = urllib.request.Request(
    "https://loa-reading-service-live.tim-b26.workers.dev/v1/list_free_shelf",
    data=json.dumps({"language": "es", "limit": 5}).encode(),
    headers={"content-type": "application/json"},
)
print(json.load(urllib.request.urlopen(req))["data"]["titles"])

The OpenAPI file and the tool files

The OpenAPI 3.1 file at /v1/openapi.json describes every operation, its arguments and the shape of its answer. Import it into Open WebUI, Dify, Flowise, Copilot Studio or any OpenAPI tool. For programs that pass tool definitions to a model, GET /v1/tools?format= returns the eight tools in the shape each maker wants: openai (Responses API), openai-chat (Chat Completions), anthropic, gemini, ollama, and mcp (the list the MCP server shows). Answer the calls the model makes with the REST operations above.

Errors

A problem comes back as application/problem+json (RFC 9457) with type, title, status, detail and a stable code.

  • 400 invalid_json, invalid_request, unknown_format: the body is not JSON, an argument is missing or wrong (the detail says which), or the tool file format is unknown.
  • 404 unknown_tool, not_found: there is no such tool, or no such title.
  • 405 method_not_allowed: tools take POST; the documents take GET.
  • 413 payload_too_large: the body is over 8 KB.
  • 415 unsupported_media_type: a body must be JSON.
  • 500 internal: the library could not answer just now. Try again in a moment.

Using the answers

  • Say what the answer says and use the url of a title as given. Do not invent a price or an offer.
  • The library is not the ancient library of Alexandria and not the Bibliotheca Alexandrina.
  • Payments and sign-up happen on libraryofalexandria.com only. A tool can hand over a link; it never takes a payment.
  • No key is needed. Please keep to a few requests a second and send a User-Agent that names your program.

Privacy

The service counts calls by tool name, status and the name and version of the client. It does not keep what was asked, and it sets no cookies. The privacy policy and the terms of service apply.

Versions

The API version is a date, sent back in the LOA-Version header (now 2026-10-25). Changes are announced on this page.