{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/svgai-org/json-schema/svgai-org-generation-status-schema.json",
  "title": "GenerationStatus",
  "x-generated": "2026-11-25",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/svgai-org-openapi.json#/components/schemas/GenerationStatus",
  "type": "object",
  "required": [
    "object",
    "id",
    "status",
    "svgs"
  ],
  "properties": {
    "object": {
      "type": "string",
      "const": "svg.generation"
    },
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "status": {
      "type": "string",
      "description": "Processing while any variation is processing; completed when none are processing and at least one completed; failed when none completed. Inspect each svgs entry for its individual outcome.",
      "enum": [
        "completed",
        "processing",
        "failed"
      ]
    },
    "svgs": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/GeneratedSvg"
      }
    }
  },
  "$defs": {
    "GeneratedSvg": {
      "type": "object",
      "required": [
        "design_id",
        "status",
        "svg"
      ],
      "properties": {
        "design_id": {
          "type": "string",
          "format": "uuid"
        },
        "status": {
          "type": "string",
          "enum": [
            "completed",
            "processing",
            "failed"
          ]
        },
        "svg": {
          "type": [
            "string",
            "null"
          ],
          "description": "Complete SVG markup when available; null while processing or when unavailable."
        }
      }
    }
  }
}