{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/anomalyarmor-ai/json-schema/anomalyarmor-ai-bulk-export-job-request-schema.json",
  "title": "BulkExportJobRequest",
  "description": "Request body for POST /contracts/export-jobs.\n\n`scope_name` is required when `scope == warehouse`.\n`asset_public_ids` is required (non-empty) when `scope == assets`.\n`mode` defaults to `extended`; `include` / `exclude` filter the\nper-asset orchestrator exactly like the single-asset endpoint.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/anomalyarmor-ai-contracts-api-openapi.yml#/components/schemas/BulkExportJobRequest",
  "properties": {
    "scope": {
      "$ref": "#/$defs/BulkExportScope"
    },
    "scope_name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Scope Name"
    },
    "asset_public_ids": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Asset Public Ids"
    },
    "mode": {
      "type": "string",
      "title": "Mode",
      "default": "extended"
    },
    "include": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Include"
    },
    "exclude": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Exclude"
    }
  },
  "type": "object",
  "required": [
    "scope"
  ],
  "$defs": {
    "BulkExportScope": {
      "type": "string",
      "enum": [
        "asset",
        "assets",
        "warehouse",
        "all"
      ],
      "title": "BulkExportScope",
      "description": "Asset-selection scope. Matches the wire names from TECH-976.\n\n`ASSET` is listed for completeness so the job handler can reject it\nwith a clear error, pointing callers at the sync single-asset endpoint.\n\n`ASSETS` takes an explicit list of asset public ids; it is the scope\nthe UI picks when the user checks rows in the asset list."
    }
  }
}