{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/gloat/json-schema/gloat-bulk-task-automation-status-request-schema.json",
  "title": "BulkTaskAutomationStatusRequest",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/gloat-job-architecture-job-code-tasks-api-openapi.yml#/components/schemas/BulkTaskAutomationStatusRequest",
  "properties": {
    "tasks": {
      "items": {
        "$ref": "#/$defs/TaskAutomationStatusBulkUpdate"
      },
      "type": "array",
      "minItems": 1,
      "title": "Tasks",
      "description": "List of tasks to update (at least 1 required)"
    }
  },
  "type": "object",
  "required": [
    "tasks"
  ],
  "$defs": {
    "AutomationStatus": {
      "type": "string",
      "enum": [
        "full",
        "high",
        "moderate",
        "low",
        "not_automating",
        "in_progress",
        "no_status"
      ],
      "title": "AutomationStatus",
      "description": "Enum representing the automation status levels for tasks.\n\nEach level corresponds to a specific automation score that impacts AI calculations.\nScores are defined in the AUTOMATION_STATUS_SCORES constant."
    },
    "JobCodeAutomationUpdate": {
      "properties": {
        "id": {
          "type": "string",
          "title": "Id",
          "description": "Job code ID"
        }
      },
      "type": "object",
      "required": [
        "id"
      ],
      "title": "JobCodeAutomationUpdate",
      "description": "Single job code reference for bulk automation status updates."
    },
    "TaskAutomationStatusBulkUpdate": {
      "properties": {
        "taskId": {
          "type": "string",
          "title": "Taskid",
          "description": "Task identifier (UUID from Ontology Service)"
        },
        "status": {
          "$ref": "#/$defs/AutomationStatus",
          "description": "Automation status to apply"
        },
        "jobCodes": {
          "items": {
            "$ref": "#/$defs/JobCodeAutomationUpdate"
          },
          "type": "array",
          "minItems": 1,
          "title": "Jobcodes",
          "description": "List of job codes to update (at least 1 required)"
        }
      },
      "type": "object",
      "required": [
        "taskId",
        "status",
        "jobCodes"
      ],
      "title": "TaskAutomationStatusBulkUpdate"
    }
  }
}