{
  "openapi": "3.1.0",
  "info": {
    "title": "Muhammad (ﷺ) — Seerah data API",
    "version": "1.0.0",
    "summary": "Machine-readable content and datasets for the interactive Seerah site.",
    "description": "The site is a fully static export: every URI below is a plain file served directly, with no request parameters. The JSON datasets are the same ones the pages are built from and are free to read and cite. Page content is also mirrored to Markdown and to llms.txt for language models.",
    "license": { "name": "See site for content licensing and sources" },
    "contact": { "name": "Muhammad (ﷺ)", "url": "https://discovermuhammad.com/" }
  },
  "servers": [{ "url": "https://discovermuhammad.com", "description": "Production" }],
  "paths": {
    "/map-data.json": {
      "get": {
        "operationId": "getMapData",
        "summary": "Shared map dataset",
        "description": "Events, people, places, road corridors and period overlays that drive the interactive map.",
        "responses": {
          "200": {
            "description": "The complete build-time dataset.",
            "content": { "application/json": { "schema": { "$ref": "#/components/schemas/MapData" } } }
          }
        }
      }
    },
    "/i18n/{lang}.json": {
      "get": {
        "operationId": "getTranslations",
        "summary": "Per-language UI and content strings",
        "parameters": [
          {
            "name": "lang",
            "in": "path",
            "required": true,
            "description": "Language code.",
            "schema": { "type": "string", "enum": ["en", "bn", "ar", "hi", "es", "fr", "ur"] }
          }
        ],
        "responses": {
          "200": {
            "description": "Translation strings for the requested language.",
            "content": { "application/json": { "schema": { "type": "object", "additionalProperties": true } } }
          }
        }
      }
    },
    "/sitemap.xml": {
      "get": {
        "operationId": "getSitemap",
        "summary": "XML sitemap of every crawlable URL",
        "responses": { "200": { "description": "sitemap.xml", "content": { "application/xml": {} } } }
      }
    },
    "/llms.txt": {
      "get": {
        "operationId": "getLlmsTxt",
        "summary": "llms.txt summary for language models",
        "responses": { "200": { "description": "llms.txt", "content": { "text/plain": {} } } }
      }
    },
    "/index.md": {
      "get": {
        "operationId": "getMarkdownHome",
        "summary": "Markdown rendering of the home page",
        "responses": { "200": { "description": "Home page as Markdown", "content": { "text/markdown": {} } } }
      }
    },
    "/robots.txt": {
      "get": {
        "operationId": "getRobots",
        "summary": "Crawler rules, including explicit AI-agent entries",
        "responses": { "200": { "description": "robots.txt", "content": { "text/plain": {} } } }
      }
    },
    "/.well-known/api-catalog": {
      "get": {
        "operationId": "getApiCatalog",
        "summary": "RFC 9727 API catalog linkset",
        "responses": {
          "200": {
            "description": "An application/linkset+json document linking this description and the site's documentation.",
            "content": { "application/linkset+json": {} }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "MapData": {
        "type": "object",
        "description": "Build-time dataset consumed by the map. Shape is stable per build; keys mirror data/*.json.",
        "properties": {
          "events": { "type": "array", "items": { "$ref": "#/components/schemas/Event" } },
          "people": { "type": "array", "items": { "type": "object", "additionalProperties": true } },
          "places": { "type": "array", "items": { "type": "object", "additionalProperties": true } },
          "routes": { "type": "array", "items": { "type": "object", "additionalProperties": true } },
          "overlays": { "type": "array", "items": { "type": "object", "additionalProperties": true } }
        },
        "additionalProperties": true
      },
      "Event": {
        "type": "object",
        "description": "One dated event of the Prophet's ﷺ life. Translatable fields are objects keyed by language.",
        "properties": {
          "id": { "type": "string", "description": "Stable slug, also the URL path segment: /events/<id>/." },
          "seq": { "type": "number", "description": "Ordering within the timeline." },
          "date": { "type": "object", "additionalProperties": { "type": "string" } },
          "title": { "type": "object", "additionalProperties": { "type": "string" } },
          "summary": { "type": "object", "additionalProperties": { "type": "string" } },
          "places": { "type": "array", "items": { "type": "string" } },
          "people": { "type": "array", "items": { "type": "string" } },
          "sources": { "type": "array", "items": { "type": "string" } }
        },
        "required": ["id"],
        "additionalProperties": true
      }
    }
  }
}
