Connect
The library is reachable two ways, both with a key from your dashboard: the MCP endpoint (the main way — for LLMs) and the REST API (for code).
MCP (recommended)
Point any MCP client at https://anglicanlibrary.com/mcp, authenticating with
Authorization: Bearer YOUR_KEY. It exposes one tool,
search_anglican_library, returning attributed passages your model can cite.
{
"mcpServers": {
"anglican-library": {
"type": "http",
"url": "https://anglicanlibrary.com/mcp",
"headers": { "Authorization": "Bearer bk_your_key" }
}
}
}
Tool arguments: query, top_k, mode
("semantic"/"literal"), rerank, deep (exhaustive recall, top_k up to
200), and filters author / category / title /
year_min / year_max. Then just ask your assistant to
“search the Anglican library for …”.
MCP via OAuth (custom connectors)
Some MCP clients use a one-click "custom connector" flow that doesn't take a
pasted key. For those, just add https://anglicanlibrary.com/mcp as the connector URL —
the client discovers the OAuth endpoints automatically, sends you here to
log in and authorize, and is then issued a token bound to your
account (metered against the same monthly quota). No key handling on your end.
Under the hood: protected-resource and authorization-server
metadata at /.well-known/oauth-protected-resource and
/.well-known/oauth-authorization-server, dynamic client registration
at /oauth/register, and an authorization-code + PKCE flow
(/oauth/authorize, /oauth/token).
REST API
Authenticate with your API key as a bearer token (or X-API-Key header).
POST /v1/search
curl -s https://YOUR_DOMAIN/v1/search \
-H "Authorization: Bearer bk_your_key_here" \
-H "Content-Type: application/json" \
-d '{"query":"the eternal generation of the Son","top_k":5}'
Request body
query | string, required |
top_k | int, default 5, max 25 |
mode | "semantic" (default) or "literal" |
rerank | bool, default true (cross-encoder rerank) |
deep | bool, default false. Exhaustive recall mode: returns many passages (top_k up to 200, no rerank) for a long-context model to synthesize. Counts as more quota units. |
author, category, title | substring filters |
year_min, year_max | publication-year range |
Response
{
"query": "...",
"count": 5,
"results": [
{"score": 0.91, "title": "...", "author": "...", "year": 1854,
"book_id": 1914, "url": "https://...", "char_start": 8331,
"char_end": 10034, "text": "..."},
...
]
}
Status codes
200 | success |
401 | missing/invalid API key |
429 | monthly quota exceeded |
503 | search engine not ready |
Your monthly request quota is shown on your dashboard.