SeerahBook for developers

Structured, read-only access to the SeerahBook knowledge graph — the life of the Prophet Muhammad ﷺ, his companions, and the events of early Islam. Choose how you want to consume it below.

What's available

The same data underlies both the REST API and the MCP server below.

People

Companions, adversaries, prophets, and angels — with relationships, events, and Quranic connections.

Events

Battles, revelations, migrations, and more — with participants, sayings, and Quranic links.

Tribes

The tribal fabric of 7th-century Arabia, with members and their connected events.

Cities & Places

Makkah, Madinah, battlefields, and caves — each with their historical events.

Sayings & Actions

First-person sayings and deeds, threaded as conversations, tied to their event.

Sources

Classical texts, lecture series, and other provenance records for every claim.

Search

Full-text search across all entity types.

REST API

for apps & scripts

Quick start

No signup or API key, ever — just call the endpoint:

curl https://seerahbook.hmeid.uk/api/v1/people

Requests are rate-limited per IP address — a generous daily allowance for a research session, but not enough to bulk-scrape the whole graph.

Including related data

Use the ?include= parameter to fetch related data in a single request:

# Person with their events and relationships
GET /api/v1/people/abu-bakr?include=events,relationships

# Event with participants and sayings
GET /api/v1/events/battle-of-badr?include=participants,posts,ayahs

MCP server

for AI agents

MCP (Model Context Protocol) lets an AI assistant call SeerahBook's data directly as tools during a conversation — the same data as the REST API above, no signup or key, ever, same per-IP rate limits. The server URL is:

https://seerahbook.hmeid.uk/api/mcp

Add it to your client

Claude

claude.ai / Claude Desktop

Settings → Connectors → Add custom connector → paste the URL above → Add.

Claude Code (CLI)

claude mcp add --transport http seerahbook https://seerahbook.hmeid.uk/api/mcp
ChatGPT

Available on Plus, Pro, Business, Enterprise, and Education plans, on the web app:

  1. Settings → Apps → Advanced settings → turn on Developer mode
  2. Settings → Connectors → Add custom connector
  3. Paste the URL above and confirm
Gemini CLI

Add to your ~/.gemini/settings.json (or a project-local .gemini/settings.json):

{
  "mcpServers": {
    "seerahbook": {
      "httpUrl": "https://seerahbook.hmeid.uk/api/mcp"
    }
  }
}

Adab & usage

This data concerns sacred history. The Prophet Muhammad ﷺ and the Companions are presented with respect throughout. Please maintain that respect in your applications. All content is read-only; the API does not accept writes.