{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/coactive/main/json-schema/coactive-ingestion-create-ingest-job-for-metadata-request-schema.json",
  "title": "CreateIngestJobForMetadataRequest",
  "x-generated": "2026-10-20",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/coactive-ingestion-ingest-api-openapi.yml#/components/schemas/ingestion_CreateIngestJobForMetadataRequest",
  "type": "object",
  "properties": {
    "dataset_id": {
      "type": "string",
      "format": "uuid"
    },
    "update_assets": {
      "type": [
        "array",
        "null"
      ],
      "items": {
        "$ref": "#/$defs/ingestion_ExistingAssetMetadataUpdate"
      }
    },
    "source_path": {
      "type": [
        "string",
        "null"
      ]
    },
    "update_type": {
      "$ref": "#/$defs/ingestion_MetadataUpdateType"
    }
  },
  "required": [
    "dataset_id"
  ],
  "$defs": {
    "ingestion_ExistingAssetMetadataUpdate": {
      "type": "object",
      "properties": {
        "asset_id": {
          "type": [
            "string",
            "null"
          ],
          "format": "uuid"
        },
        "source_path": {
          "type": [
            "string",
            "null"
          ]
        },
        "asset_type": {
          "$ref": "#/$defs/ingestion_ExplicitExternalAssetType"
        },
        "metadata": {
          "type": [
            "object",
            "null"
          ],
          "additionalProperties": {
            "$ref": "#/$defs/ingestion_ExistingAssetMetadataUpdateMetadata"
          }
        }
      },
      "required": [
        "asset_type"
      ],
      "title": "ExistingAssetMetadataUpdate"
    },
    "ingestion_ExistingAssetMetadataUpdateMetadata": {
      "oneOf": [
        {
          "type": "boolean"
        },
        {
          "type": "integer"
        },
        {
          "type": "number",
          "format": "double"
        },
        {
          "type": "string"
        },
        {
          "type": "string",
          "format": "date-time"
        }
      ],
      "title": "ExistingAssetMetadataUpdateMetadata"
    },
    "ingestion_ExplicitExternalAssetType": {
      "type": "string",
      "enum": [
        "image",
        "video"
      ],
      "title": "ExplicitExternalAssetType"
    },
    "ingestion_MetadataUpdateType": {
      "type": "string",
      "enum": [
        "overwrite",
        "upsert",
        "remove"
      ],
      "title": "MetadataUpdateType"
    }
  }
}