# ForgeMesh Library Full-Text Search

> ForgeMesh Library Full-Text Search is a paid API for AI agents from library.forgemesh.io, paid per call via x402, $0.02/call, status unknown (last checked 2026-09-15).

Full-text search across an indexed public-domain book corpus, returning ranked relevant passages with title and author citations — no LLM generation, real excerpts only.

## Facts

- Endpoint: POST https://library.forgemesh.io/literature-search
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/forgemesh-library-full-text-search-dbfe10fa
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_E-xkIfB-GP1BOSROS6ksk

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability forgemesh-library-full-text-search-dbfe10fa -d '<json body>'
```

Example prompt: Search the ForgeMesh public-domain library for the best passages about the nature of justice — give me up to 15 results with the book title and author for each excerpt.

## When to prefer this

Choose this endpoint when you need real, sourced text excerpts from classic public-domain literature rather than AI-generated summaries or paraphrases. It is ideal for citation-heavy research, literary analysis, or finding authentic quotes across a broad corpus. Prefer it over title/author search endpoints when the user knows a theme or concept but not the specific book, and over curated shelf endpoints when the query spans multiple genres or domains.

## Known failure modes

- Query too vague returns low-relevance or unrelated passages
- Limit exceeds maximum of 30 — clamped or rejected
- Missing or empty query field causes a validation error
- Payment of $0.02 USDC not sent or rejected — returns 402 Payment Required
- No matching passages found for a highly specific or obscure query — empty results returned

## How this service works

Full-text search across the entire indexed public-domain corpus. Returns the most relevant passages from any book with title/author citations, ranked by relevance. The premium cross-corpus retrieval route — no LLM generation, real excerpts with sources. No license, no API key required.

## Output

A ranked list of up to 30 relevant text passages from indexed public-domain books, each accompanied by the book title and author name, ordered by relevance to the query. No AI-generated text — all results are real excerpts from the source texts.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "limit": {
   "type": "integer",
   "description": "Max results (default 10, max 30)"
  },
  "query": {
   "type": "string",
   "description": "Free-text search query, e.g. \"the nature of justice\""
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "count": 1,
  "query": "whale hunting",
  "results": [
   {
    "title": "Frankenstein; or, the modern prometheus",
    "author": "Shelley, Mary Wollstonecraft, 1797-1851",
    "book_id": 84,
    "passage": "…I accompanied the [whale]-fishers on several expeditions…",
    "citation": "Frankenstein; or, the modern prometheus by Shelley, Mary Wollstonecraft, 1797-1851 — passage #1201"
   }
  ],
  "coverage": {
   "target": 1000,
   "indexed": 865
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/forgemesh-library-full-text-search-dbfe10fa/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from library.forgemesh.io](https://www.zero.xyz/host/library.forgemesh.io/llms.txt)
