{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/quiz-video/json-schema/quiz-video-quiz-schema.json",
  "title": "Quiz",
  "x-generated": "2026-11-22",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/quiz-video-openapi.json#/components/schemas/Quiz",
  "type": "object",
  "properties": {
    "id": {
      "type": "string"
    },
    "title": {
      "type": "string"
    },
    "description": {
      "type": [
        "string",
        "null"
      ]
    },
    "slug": {
      "type": "string"
    },
    "format": {
      "type": "string"
    },
    "quizType": {
      "type": "string"
    },
    "template": {
      "type": [
        "string",
        "null"
      ]
    },
    "themeCustomization": {
      "$ref": "#/$defs/ThemeCustomization"
    },
    "difficulty": {
      "type": [
        "string",
        "null"
      ]
    },
    "backgroundMusicId": {
      "type": [
        "integer",
        "null"
      ]
    },
    "musicVolume": {
      "type": "number"
    },
    "isPublished": {
      "type": "boolean"
    },
    "publishedAt": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "linkSharing": {
      "type": "boolean",
      "description": "True when anyone with the link can play this unlisted quiz."
    },
    "shareToken": {
      "type": [
        "string",
        "null"
      ],
      "description": "Random key in the play link. Treat it like the link itself."
    },
    "views": {
      "type": "integer"
    },
    "plays": {
      "type": "integer"
    },
    "thumbnailUrl": {
      "type": [
        "string",
        "null"
      ],
      "format": "uri"
    },
    "createdAt": {
      "type": "string",
      "format": "date-time"
    },
    "updatedAt": {
      "type": "string",
      "format": "date-time"
    }
  },
  "$defs": {
    "ThemeCustomization": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string"
        },
        "description": {
          "type": "string"
        },
        "accentColorOverride": {
          "type": "string",
          "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$"
        },
        "backgroundColorOverride": {
          "type": "string",
          "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$"
        },
        "secondaryColorOverride": {
          "type": "string",
          "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$"
        },
        "textColorOverride": {
          "type": "string",
          "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$"
        },
        "answerTextColorOverride": {
          "type": "string",
          "pattern": "^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$"
        },
        "fontFamilyOverride": {
          "type": "string",
          "enum": [
            "Inter",
            "Poppins",
            "Roboto",
            "Montserrat",
            "Open Sans",
            "Lato",
            "Raleway",
            "Source Sans 3",
            "Space Grotesk",
            "Manrope",
            "Work Sans",
            "DM Sans",
            "Lexend",
            "Nunito",
            "Quicksand",
            "Outfit",
            "Sora",
            "Albert Sans",
            "Bricolage Grotesque",
            "Playfair Display",
            "Merriweather",
            "Cormorant Garamond",
            "Fraunces",
            "Crimson Pro",
            "Cinzel",
            "Oswald",
            "Bebas Neue",
            "Anton",
            "Archivo Black",
            "Big Shoulders",
            "Bungee",
            "Bangers",
            "Lilita One",
            "Fredoka",
            "Baloo 2",
            "Exo 2",
            "Orbitron",
            "Press Start 2P",
            "Caveat",
            "Dancing Script",
            "Pacifico",
            "Permanent Marker",
            "Noto Sans",
            "Noto Naskh Arabic",
            "Vazirmatn"
          ]
        }
      },
      "additionalProperties": false
    }
  }
}