{
  "openapi": "3.1.0",
  "info": {
    "title": "AppInitDev Discovery API",
    "version": "1.0.0",
    "description": "API de solo lectura. Requiere desplegar el Worker independiente; no sustituye MCP ni es NLWeb oficial."
  },
  "x-appinitdev-deployment": "Esta copia es una plantilla; para importar como acción utiliza /openapi.json del Worker desplegado.",
  "paths": {
    "/v1/apps": {
      "get": {
        "summary": "Lista de aplicaciones Android",
        "operationId": "listarAplicaciones",
        "responses": {
          "200": {
            "description": "Respuesta JSON válida",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/v1/search": {
      "get": {
        "summary": "Busca apps por texto",
        "operationId": "buscarAplicaciones",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 180
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 50,
              "default": 10
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Respuesta JSON válida",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/v1/ask": {
      "get": {
        "summary": "Búsqueda por pregunta en lenguaje natural (léxica, sin LLM)",
        "operationId": "preguntarSobreAplicaciones",
        "parameters": [
          {
            "name": "q",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string",
              "minLength": 1,
              "maxLength": 180
            }
          },
          {
            "name": "limit",
            "in": "query",
            "schema": {
              "type": "integer",
              "minimum": 1,
              "maximum": 50,
              "default": 10
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Respuesta JSON válida",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/v1/categories": {
      "get": {
        "summary": "Lista de categorías",
        "operationId": "listarCategorias",
        "responses": {
          "200": {
            "description": "Respuesta JSON válida",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/v1/apps/{slug}": {
      "get": {
        "summary": "Ficha de una aplicación",
        "operationId": "obtenerAplicacion",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Respuesta JSON válida",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    },
    "/health": {
      "get": {
        "summary": "Estado del servicio",
        "operationId": "estadoServicio",
        "responses": {
          "200": {
            "description": "Respuesta JSON válida",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          }
        }
      }
    }
  },
  "tags": [
    {
      "name": "AppInitDev",
      "description": "Información pública de las aplicaciones"
    }
  ]
}
