{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/elaiio/json-schema/elaiio-voice-customization-schema.json",
  "title": "VoiceCustomization",
  "description": "A named bundle of TTS settings bound to one voice. Referenced from slides as `voiceVariantId`.",
  "x-generated": "2026-12-01",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/elaiio-elai-public-api-openapi.yml#/components/schemas/VoiceCustomization",
  "type": "object",
  "properties": {
    "_id": {
      "type": "string"
    },
    "name": {
      "type": "string",
      "maxLength": 20
    },
    "provider": {
      "type": "string",
      "enum": [
        "elevenlabs",
        "azure",
        "google"
      ]
    },
    "voiceId": {
      "type": "string"
    },
    "language": {
      "type": [
        "string",
        "null"
      ],
      "description": "Standard voices only; null for custom voices."
    },
    "locale": {
      "type": [
        "string",
        "null"
      ],
      "description": "Standard voices only; null for custom voices."
    },
    "model": {
      "type": [
        "string",
        "null"
      ],
      "description": "Provider model, resolved per slide at render time when null."
    },
    "customVoiceId": {
      "type": [
        "string",
        "null"
      ],
      "description": "Set when the customization targets a cloned/custom voice."
    },
    "settings": {
      "type": "object",
      "description": "All four values are optional and may be null.",
      "properties": {
        "stability": {
          "type": [
            "number",
            "null"
          ],
          "minimum": 0,
          "maximum": 1
        },
        "speed": {
          "type": [
            "number",
            "null"
          ],
          "minimum": 0.7,
          "maximum": 1.2
        },
        "similarity": {
          "type": [
            "number",
            "null"
          ],
          "minimum": 0,
          "maximum": 1
        },
        "style": {
          "type": [
            "number",
            "null"
          ],
          "minimum": 0,
          "maximum": 1
        }
      }
    },
    "lastModifiedByEmail": {
      "type": "string"
    },
    "accountId": {
      "type": "string"
    },
    "createdAt": {
      "type": "string",
      "format": "date-time"
    },
    "updatedAt": {
      "type": "string",
      "format": "date-time"
    }
  }
}