{
  "openapi": "3.0.3",
  "info": {
    "title": "MzadAuto Public API",
    "description": "Public automotive catalog, comparison, and discovery endpoints for MzadAuto.ma (Morocco).",
    "version": "1.0.0",
    "contact": {
      "name": "MzadAuto Support",
      "url": "https://mzadauto.ma/about",
      "email": "support@mzadauto.ma"
    }
  },
  "servers": [
    {
      "url": "https://mzadauto.ma",
      "description": "Production server"
    }
  ],
  "paths": {
    "/.well-known/api-catalog": {
      "get": {
        "summary": "RFC 9727 API Catalog",
        "description": "Returns the RFC 9727 Linkset JSON document advertising machine-readable API resources.",
        "responses": {
          "200": {
            "description": "API Catalog Linkset",
            "content": {
              "application/linkset+json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/llms.txt": {
      "get": {
        "summary": "LLMs Site Summary",
        "description": "Returns markdown summary for AI agents and LLMs per llms.txt standard.",
        "responses": {
          "200": {
            "description": "LLM documentation",
            "content": {
              "text/plain": {
                "schema": {
                  "type": "string"
                }
              }
            }
          }
        }
      }
    },
    "/catalogue/modeles": {
      "get": {
        "summary": "List available automotive models",
        "description": "Returns active brands and models that have available technical specifications for comparison and search.",
        "responses": {
          "200": {
            "description": "JSON array of models with brand slug and specs count",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "id": { "type": "integer" },
                      "name": { "type": "string" },
                      "slug": { "type": "string" },
                      "category_id": { "type": "integer" }
                    }
                  }
                }
              }
            }
          }
        }
      }
    },
    "/up": {
      "get": {
        "summary": "Health check endpoint",
        "description": "Returns 200 OK when application is healthy.",
        "responses": {
          "200": {
            "description": "Application healthy"
          }
        }
      }
    }
  }
}
