{
  "namespace": "com.pacbio.common.models.contracts",
  "type": "record",
  "name": "ToolContract",
  "fields": [
    {
      "name": "tool_contract",
      "type": {
        "type": "record",
        "name": "ToolContractTask",
        "fields": [
          {
            "name": "input_types",
            "type": {
              "type": "array",
              "items": {
                "type": "record",
                "name": "ToolInputFile",
                "fields": [
                  {
                    "name": "id",
                    "type": "string"
                  },
                  {
                    "doc": "PacBio File Type identifier",
                    "name": "file_type_id",
                    "type": "string"
                  },
                  {
                    "doc": "Display Name",
                    "name": "title",
                    "type": "string"
                  },
                  {
                    "name": "description",
                    "type": "string"
                  }
                ]
              }
            }
          },
          {
            "name": "output_types",
            "type": {
              "type": "array",
              "items": {
                "type": "record",
                "name": "ToolOutputFile",
                "fields": [
                  {
                    "name": "id",
                    "type": "string"
                  },
                  {
                    "doc": "PacBio FileType identifier",
                    "name": "file_type_id",
                    "type": "string"
                  },
                  {
                    "doc": "Display Name",
                    "name": "title",
                    "type": "string"
                  },
                  {
                    "doc": "Default file name",
                    "name": "default_name",
                    "type": "string"
                  },
                  {
                    "name": "description",
                    "type": "string"
                  }
                ]
              }
            }
          },
          {
            "name": "schema_options",
            "type": {
              "type": "array",
              "items": {
                "type": "record",
                "name": "PacBioOptions",
                "fields": [
                  {
                    "name": "pb_option",
                    "type": {
                      "type": "record",
                      "name": "pb_option",
                      "fields": [
                        {
                          "name": "default",
                          "type": [
                            "int",
                            "string",
                            "boolean",
                            "float"
                          ]
                        },
                        {
                          "name": "option_id",
                          "type": "string"
                        },
                        {
                          "name": "name",
                          "type": "string"
                        },
                        {
                          "name": "description",
                          "type": "string"
                        }
                      ]
                    }
                  }
                ]
              }
            }
          },
          {
            "doc": "Number of processors to use",
            "name": "nproc",
            "type": "int"
          },
          {
            "doc": "Globally unique Tool Contract identifier",
            "name": "tool_contract_id",
            "type": "string"
          },
          {
            "doc": "Task class type, Standard, Scatter, Gather",
            "name": "task_type",
            "type": "string"
          },
          {
            "doc": "Determine if the task will be submitted to the cluster resources",
            "name": "is_distributed",
            "type": "boolean"
          },
          {
            "name": "resource_types",
            "type": {
              "type": "array",
              "items": {
                "type": "string"
              }
            }
          }
        ]
      }
    },
    {
      "name": "driver",
      "type": {
        "type": "record",
        "name": "ToolDriver",
        "fields": [
          {
            "name": "exe",
            "type": "string"
          }
        ]
      }
    }
  ]
}