{
  "name": "image-api",
  "version": "1.0.0",
  "pages": {
    "/": "Home",
    "/models": "Model catalog UI",
    "/docs": "Documentation",
    "/docs.txt": "Plain-text agent API reference",
    "/status": "Public live feed UI"
  },
  "endpoints": {
    "GET /health": "Liveness",
    "GET /v1/status": "Public live feed (catalog models only)",
    "GET /v1/models": "List image, music, and voice models + parameters + logos",
    "GET /v1/models/:id": "Single model detail + logos",
    "GET /v1/usage": "Remaining quota for the calling API key",
    "GET /v1/logos": "Provider logos",
    "GET /v1/logos/:slug?theme=light|dark|color": "SVG logo",
    "GET /v1/music/tags": "Music style tags catalog (model v1)",
    "POST /v1/music/tokenize": "Count lyrics tokens (BPE, limit 1531)",
    "POST /v1/music/lyrics/enhance": "Write/expand lyrics from an idea + style prompt",
    "POST /v1/music/generations": "Start music generation (model v1)",
    "GET /v1/music/generations/:id": "Poll music job / variant",
    "GET /v1/music/stream/:id": "Live music stream",
    "GET /v1/music/files/:id": "Final music file",
    "GET /v1/voice-clone/status": "Whether this API key already has a saved voice",
    "POST /v1/voice-clone/generate": "Upload sample once (optional if saved) + transcript → speech",
    "POST /v1/images/generations": {
      "body": {
        "prompt": "string (required)",
        "model": "string (default gpt-image-2)",
        "aspect_ratio": "string enum per model",
        "resolution": "string enum per model (if supported)",
        "quality": "low|medium|high (if supported)",
        "generations_count": "1-4",
        "wait": "bool — poll until complete (default false)"
      },
      "example": {
        "prompt": "a red fox in snow, cinematic",
        "model": "gpt-image-2",
        "aspect_ratio": "16:9",
        "quality": "medium"
      }
    },
    "GET /v1/images/:batchId": "Poll a generation batch"
  },
  "tip": "Call GET /v1/models first. Invalid aspect_ratio returns 400 with allowed list."
}