{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/vidplate-app/json-schema/vidplate-app-upload-schema.json",
  "title": "Upload",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/vidplate-app-uploads-api-openapi.yml#/components/schemas/Upload",
  "type": "object",
  "properties": {
    "object": {
      "const": "upload"
    },
    "id": {
      "type": "string"
    },
    "status": {
      "enum": [
        "pending",
        "ready",
        "rejected",
        "expired"
      ]
    },
    "filename": {
      "type": "string"
    },
    "content_type": {
      "type": "string"
    },
    "kind": {
      "enum": [
        "image",
        "video",
        "model3d",
        "audio"
      ]
    },
    "size_bytes": {
      "type": "integer"
    },
    "width": {
      "type": [
        "integer",
        "null"
      ]
    },
    "height": {
      "type": [
        "integer",
        "null"
      ]
    },
    "rejected_reason": {
      "type": [
        "string",
        "null"
      ]
    },
    "upload": {
      "type": "object",
      "description": "Only when the upload is created.",
      "properties": {
        "method": {
          "const": "PUT"
        },
        "url": {
          "type": "string"
        },
        "headers": {
          "type": "object",
          "additionalProperties": {
            "type": "string"
          }
        },
        "expires_at": {
          "type": "string"
        }
      }
    },
    "expires_at": {
      "type": [
        "string",
        "null"
      ]
    },
    "created_at": {
      "type": [
        "string",
        "null"
      ]
    },
    "completed_at": {
      "type": [
        "string",
        "null"
      ]
    }
  }
}