{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/tubearchivist/json-schema/tubearchivist-channel-schema.json",
  "title": "Channel",
  "description": "serialize channel",
  "x-generated": "2026-10-28",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/tubearchivist-openapi.yml#/components/schemas/Channel",
  "type": "object",
  "properties": {
    "channel_id": {
      "type": "string"
    },
    "channel_active": {
      "type": "boolean"
    },
    "channel_banner_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "channel_thumb_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "channel_tvart_url": {
      "type": [
        "string",
        "null"
      ]
    },
    "channel_description": {
      "type": [
        "string",
        "null"
      ]
    },
    "channel_last_refresh": {
      "type": "string"
    },
    "channel_name": {
      "type": "string"
    },
    "channel_overwrites": {
      "$ref": "#/$defs/ChannelOverwrite"
    },
    "channel_subs": {
      "type": "integer"
    },
    "channel_subscribed": {
      "type": "boolean"
    },
    "channel_tags": {
      "type": "array",
      "items": {
        "type": "string"
      }
    },
    "channel_tabs": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/VidTypeFilterEnum"
      }
    },
    "_index": {
      "type": "string",
      "title": " index"
    },
    "_score": {
      "type": "integer",
      "title": " score"
    }
  },
  "required": [
    "channel_active",
    "channel_id",
    "channel_last_refresh",
    "channel_name",
    "channel_subs",
    "channel_subscribed",
    "channel_tabs"
  ],
  "$defs": {
    "ChannelOverwrite": {
      "type": "object",
      "description": "serialize channel overwrites",
      "properties": {
        "download_format": {
          "type": [
            "string",
            "null"
          ]
        },
        "autodelete_days": {
          "type": [
            "integer",
            "null"
          ]
        },
        "index_playlists": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "integrate_sponsorblock": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "subscriptions_channel_size": {
          "type": [
            "integer",
            "null"
          ]
        },
        "subscriptions_live_channel_size": {
          "type": [
            "integer",
            "null"
          ]
        },
        "subscriptions_shorts_channel_size": {
          "type": [
            "integer",
            "null"
          ]
        }
      }
    },
    "VidTypeFilterEnum": {
      "enum": [
        "videos",
        "streams",
        "shorts"
      ],
      "type": "string",
      "description": "* `videos` - videos\n* `streams` - streams\n* `shorts` - shorts"
    }
  }
}