{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/broad-institute/main/json-schema/broad-institute-submission-schema.json",
  "title": "Submission",
  "x-generated": "2026-10-15",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/broad-institute-openapi.yml#/components/schemas/Submission",
  "type": "object",
  "properties": {
    "submissionId": {
      "type": "string",
      "description": "SubmissionRequest unique identifier"
    },
    "submissionDate": {
      "type": "string",
      "description": "SubmissionRequest date",
      "format": "date-time"
    },
    "submitter": {
      "type": "string",
      "description": "user that created the submission"
    },
    "methodConfigurationNamespace": {
      "type": "string",
      "description": "Method configuration namespace"
    },
    "methodConfigurationName": {
      "type": "string",
      "description": "Method configuration name"
    },
    "submissionEntity": {
      "$ref": "#/$defs/AttributeEntityReference"
    },
    "workflows": {
      "type": "array",
      "description": "Status of Workflow(s)",
      "items": {
        "$ref": "#/$defs/Workflow"
      }
    },
    "status": {
      "$ref": "#/$defs/SubmissionStatus"
    },
    "cost": {
      "type": "number",
      "description": "The compute cost of this submission",
      "format": "float"
    },
    "useCallCache": {
      "type": "boolean",
      "description": "Whether or not to read from cache for this submission"
    },
    "deleteIntermediateOutputFiles": {
      "type": "boolean",
      "description": "Whether or not to delete intermediate output files when the workflow completes. See Cromwell docs for more information."
    },
    "useReferenceDisks": {
      "type": "boolean",
      "description": "Whether or not to use pre-built disks for common genome references"
    },
    "memoryRetryMultiplier": {
      "type": "number",
      "description": "If a task fails due to running out of memory and the task has `maxRetries` in its runtime attributes, then it will be retried with its memory multiplied by this amount.  See [Cromwell docs](https://cromwell.readthedocs.io/en/develop/cromwell_features/RetryWithMoreMemory/#retry-with-more-memory) for more information."
    },
    "workflowFailureMode": {
      "type": "string",
      "description": "What happens after a task fails. Choose from ContinueWhilePossible and NoNewCalls. Defaults to NoNewCalls if not specified. See Cromwell docs for more information.",
      "default": "NoNewCalls",
      "enum": [
        "NoNewCalls",
        "ContinueWhilePossible"
      ]
    },
    "userComment": {
      "type": "string",
      "description": "Comment for the submission"
    }
  },
  "$defs": {
    "AttributeEntityReference": {
      "required": [
        "entityName",
        "entityType"
      ],
      "type": "object",
      "properties": {
        "entityType": {
          "type": "string",
          "description": "The type of the entity"
        },
        "entityName": {
          "type": "string",
          "description": "The name of the entity"
        }
      },
      "description": ""
    },
    "SubmissionStatus": {
      "type": "string",
      "description": "submission status",
      "enum": [
        "Accepted",
        "Evaluating",
        "Submitting",
        "Submitted",
        "Aborting",
        "Aborted",
        "Done"
      ]
    },
    "SubmissionValidationValue": {
      "required": [
        "inputName"
      ],
      "type": "object",
      "properties": {
        "value": {
          "type": "string",
          "description": "the value of the input expression for the specified entity"
        },
        "error": {
          "type": "string",
          "description": "parsing error(s)"
        },
        "inputName": {
          "type": "string",
          "description": "name of input"
        }
      },
      "description": "result of an expression parse for one of the inputs"
    },
    "Workflow": {
      "type": "object",
      "properties": {
        "workflowId": {
          "type": "string",
          "description": "Workflow unique identifier"
        },
        "status": {
          "$ref": "#/$defs/WorkflowStatus"
        },
        "statusLastChangedDate": {
          "type": "string",
          "description": "Status last-changed date",
          "format": "date-time"
        },
        "workflowEntity": {
          "$ref": "#/$defs/AttributeEntityReference"
        },
        "inputResolutions": {
          "type": "array",
          "description": "The evaluation of each input",
          "items": {
            "$ref": "#/$defs/SubmissionValidationValue"
          }
        },
        "messages": {
          "type": "array",
          "description": "List of messages about this workflow",
          "items": {
            "type": "string"
          }
        },
        "cost": {
          "type": "number",
          "description": "The run cost of this workflow, if available",
          "format": "float"
        },
        "costType": {
          "type": "string",
          "description": "The method used to calculate the run cost",
          "enum": [
            "Actual",
            "Estimated"
          ]
        }
      },
      "description": ""
    },
    "WorkflowStatus": {
      "type": "string",
      "description": "workflow status",
      "enum": [
        "Queued",
        "Launching",
        "Submitted",
        "Running",
        "Failed",
        "Succeeded",
        "Aborting",
        "Aborted",
        "Unknown"
      ]
    }
  }
}