{
  "openapi": "3.1.0",
  "info": {
    "title": "WowAddons Forever Addons API",
    "version": "1.0.0",
    "description": "Structured, continuously updated catalog of verified World of Warcraft Forever (Interface 16001 / 1.60.x) addons across WowAddons, GitHub, WoWInterface, Tukui and verified bridges.",
    "contact": {
      "name": "Solar Beam Studio (WowAddons)",
      "url": "https://docs.wowaddons.gg",
      "email": "hello@solarbeam.studio"
    }
  },
  "externalDocs": {
    "description": "WowAddons Developer Documentation",
    "url": "https://docs.wowaddons.gg"
  },
  "servers": [
    {
      "url": "https://api.wowaddons.gg",
      "description": "Production API (recommended)"
    },
    {
      "url": "https://wowaddons.gg/api",
      "description": "Backward-compatible alias"
    }
  ],
  "security": [
    {
      "bearerAuth": []
    },
    {
      "apiKeyHeader": []
    }
  ],
  "components": {
    "securitySchemes": {
      "bearerAuth": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "wa_live_..."
      },
      "apiKeyHeader": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Api-Key"
      }
    },
    "schemas": {
      "Addon": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string",
            "examples": [
              "gh:BigWigsMods/BigWigs",
              "cf:1592",
              "tukui:elvui",
              "wa:cyclop/PetitOeil"
            ]
          },
          "ref": {
            "type": "string"
          },
          "source": {
            "type": "string",
            "enum": [
              "wowaddons",
              "github",
              "wowinterface",
              "tukui",
              "curseforge"
            ]
          },
          "title": {
            "type": "string"
          },
          "summary": {
            "type": "string"
          },
          "author": {
            "type": "string"
          },
          "version": {
            "type": "string"
          },
          "categories": {
            "type": "array",
            "items": {
              "type": "string",
              "enum": [
                "quests",
                "dungeons",
                "maps",
                "combat",
                "interface",
                "items",
                "economy",
                "social"
              ]
            }
          },
          "installs": {
            "type": [
              "integer",
              "null"
            ]
          },
          "stars": {
            "type": [
              "integer",
              "null"
            ]
          },
          "updated_at": {
            "type": [
              "string",
              "null"
            ],
            "format": "date-time"
          },
          "image": {
            "type": [
              "string",
              "null"
            ],
            "format": "uri"
          },
          "url": {
            "type": "string",
            "format": "uri"
          },
          "source_url": {
            "type": "string",
            "format": "uri"
          },
          "install_uri": {
            "type": "string"
          },
          "curse_id": {
            "type": [
              "string",
              "null"
            ]
          },
          "repo": {
            "type": [
              "string",
              "null"
            ]
          }
        }
      }
    }
  },
  "paths": {
    "/v1/addons": {
      "get": {
        "summary": "List and search verified World of Warcraft Forever addons",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "schema": {
              "type": "string",
              "maxLength": 80
            },
            "description": "Search query (name, keywords, FR/EN synonyms)"
          },
          {
            "name": "source",
            "in": "query",
            "schema": {
              "type": "string"
            },
            "description": "Comma-separated filter: wowaddons,github,wowinterface,tukui,curseforge"
          },
          {
            "name": "category",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "quests",
                "dungeons",
                "maps",
                "combat",
                "interface",
                "items",
                "economy",
                "social"
              ]
            }
          },
          {
            "name": "sort",
            "in": "query",
            "schema": {
              "type": "string",
              "enum": [
                "popular",
                "updated"
              ]
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 100,
              "default": 50
            }
          },
          {
            "name": "offset",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 0,
              "default": 0
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Paginated list of Forever addons"
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "429": {
            "description": "Rate limit exceeded (120/min, 5000/day)"
          }
        }
      }
    },
    "/v1/addon": {
      "get": {
        "summary": "Get one Forever addon by its canonical id",
        "parameters": [
          {
            "name": "id",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "cf:1592"
          }
        ],
        "responses": {
          "200": {
            "description": "Structured addon record"
          },
          "404": {
            "description": "Addon not found"
          }
        }
      }
    },
    "/v1/stats": {
      "get": {
        "summary": "Live counts of verified Forever addons by source and category",
        "responses": {
          "200": {
            "description": "Catalog statistics"
          }
        }
      }
    },
    "/v1/openapi.json": {
      "get": {
        "summary": "OpenAPI 3.1 specification (public, no key required)",
        "security": [],
        "responses": {
          "200": {
            "description": "OpenAPI JSON"
          }
        }
      }
    }
  }
}