{
  "openapi": "3.1.0",
  "info": {
    "title": "Mostanadat Arabic Document & Template Repository API",
    "version": "1.0.0",
    "description": "Public read-only API for discovering Arabic templates, legal contracts, Excel sheets, educational documents, PDF printables, and interactive document generators across 10 sectors on Mostanadat (مستندات).",
    "contact": {
      "name": "Mostanadat Editorial & Technical Team",
      "url": "https://mostandat.com/contact/",
      "email": "contact@mostandat.com"
    }
  },
  "servers": [
    {
      "url": "https://mostandat.com",
      "description": "Production Edge Server (Cloudflare Pages + D1 + R2)"
    }
  ],
  "paths": {
    "/api/catalog.json": {
      "get": {
        "operationId": "getCatalogAndTaxonomy",
        "summary": "Retrieve all 10 sectors, 8 supported file formats, online tools, and published document templates",
        "responses": {
          "200": {
            "description": "Complete JSON catalog of sectors, formats, tools, and published templates",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "platform": { "type": "string" },
                    "sectorsCount": { "type": "integer" },
                    "formatsCount": { "type": "integer" },
                    "templatesCount": { "type": "integer" },
                    "sectors": { "type": "array", "items": { "type": "object" } },
                    "formats": { "type": "array", "items": { "type": "object" } },
                    "tools": { "type": "array", "items": { "type": "object" } },
                    "templates": { "type": "array", "items": { "type": "object" } }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/api/health": {
      "get": {
        "operationId": "getHealthStatus",
        "summary": "Check platform health and API readiness",
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "status": { "type": "string" },
                    "service": { "type": "string" }
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}
