{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/animgen-com/json-schema/animgen-com-job-out-schema.json",
  "title": "JobOut",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/animgen-com-jobs-api-openapi.yml#/components/schemas/JobOut",
  "properties": {
    "cancellationAllowed": {
      "type": "boolean",
      "title": "Cancellationallowed",
      "default": true
    },
    "cancellationReason": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Cancellationreason"
    },
    "id": {
      "type": "string",
      "format": "uuid",
      "title": "Id"
    },
    "workspaceId": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ],
      "title": "Workspaceid"
    },
    "type": {
      "type": "string",
      "title": "Type"
    },
    "displayName": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Displayname"
    },
    "status": {
      "type": "string",
      "title": "Status"
    },
    "progress": {
      "type": "number",
      "title": "Progress"
    },
    "params": {
      "additionalProperties": true,
      "type": "object",
      "title": "Params"
    },
    "input": {
      "$ref": "#/$defs/JobInputOut"
    },
    "result": {
      "additionalProperties": true,
      "type": "object",
      "title": "Result"
    },
    "error": {
      "anyOf": [
        {
          "$ref": "#/$defs/ErrorBody"
        },
        {
          "type": "null"
        }
      ]
    },
    "createdAt": {
      "type": "string",
      "title": "Createdat"
    },
    "updatedAt": {
      "type": "string",
      "title": "Updatedat"
    },
    "startedAt": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Startedat"
    },
    "finishedAt": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Finishedat"
    },
    "lastSeq": {
      "type": "integer",
      "title": "Lastseq",
      "default": 0
    },
    "assets": {
      "items": {
        "$ref": "#/$defs/AssetOut"
      },
      "type": "array",
      "title": "Assets"
    }
  },
  "type": "object",
  "required": [
    "id",
    "type",
    "status",
    "progress",
    "createdAt",
    "updatedAt"
  ],
  "$defs": {
    "AssetOut": {
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid",
          "title": "Id"
        },
        "kind": {
          "type": "string",
          "title": "Kind"
        },
        "displayName": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Displayname"
        },
        "mimeType": {
          "type": "string",
          "title": "Mimetype"
        },
        "downloadPath": {
          "type": "string",
          "title": "Downloadpath"
        },
        "thumbnailPath": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Thumbnailpath"
        },
        "byteSize": {
          "type": "integer",
          "title": "Bytesize",
          "default": 0
        },
        "sourceType": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Sourcetype"
        },
        "createdAt": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Createdat"
        },
        "meta": {
          "additionalProperties": true,
          "type": "object",
          "title": "Meta"
        }
      },
      "type": "object",
      "required": [
        "id",
        "kind",
        "mimeType",
        "downloadPath"
      ],
      "title": "AssetOut"
    },
    "ErrorBody": {
      "properties": {
        "code": {
          "type": "string",
          "title": "Code"
        },
        "message": {
          "type": "string",
          "title": "Message"
        },
        "details": {
          "anyOf": [
            {
              "additionalProperties": true,
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Details"
        }
      },
      "type": "object",
      "required": [
        "code",
        "message"
      ],
      "title": "ErrorBody"
    },
    "JobInputOut": {
      "properties": {
        "prompt": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Prompt"
        },
        "negativePrompt": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Negativeprompt"
        },
        "sourceJobId": {
          "anyOf": [
            {
              "type": "string",
              "format": "uuid"
            },
            {
              "type": "null"
            }
          ],
          "title": "Sourcejobid"
        },
        "resources": {
          "items": {
            "$ref": "#/$defs/JobInputResourceOut"
          },
          "type": "array",
          "title": "Resources"
        }
      },
      "type": "object",
      "title": "JobInputOut"
    },
    "JobInputResourceOut": {
      "properties": {
        "id": {
          "type": "string",
          "format": "uuid",
          "title": "Id"
        },
        "resourceType": {
          "type": "string",
          "enum": [
            "asset",
            "upload"
          ],
          "title": "Resourcetype"
        },
        "role": {
          "type": "string",
          "title": "Role"
        },
        "label": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Label"
        },
        "displayName": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Displayname"
        },
        "kind": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Kind"
        },
        "mimeType": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Mimetype"
        },
        "downloadPath": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Downloadpath"
        },
        "thumbnailPath": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Thumbnailpath"
        },
        "available": {
          "type": "boolean",
          "title": "Available",
          "default": true
        }
      },
      "type": "object",
      "required": [
        "id",
        "resourceType",
        "role"
      ],
      "title": "JobInputResourceOut"
    }
  }
}