Type CWLGraphOrFile
File match *.cwl
Schema URL https://catalog.lintel.tools/schemas/schemastore/cwl/latest.json
Source https://raw.githubusercontent.com/common-workflow-lab/cwl-ts-auto/main/json_schemas/cwl_schema.json

Validate with Lintel

npx @lintel/lintel check
Type: CWLGraphOrFile

Definitions

CommandInputArraySchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandInputArraySchema

items CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | string[] | string required

Defines the type of the array elements.

type string required

Must be array

Constant: "array"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

inputBinding object

When listed under inputBinding in the input schema, the term "value" refers to the corresponding value in the input object. For binding objects listed in CommandLineTool.arguments, the term "value" refers to the effective value after evaluating valueFrom.

The binding behavior when building the command line depends on the data type of the value. If there is a mismatch between the type described by the input schema and the effective value, such as resulting from an expression evaluation, an implementation must use the data type of the effective value.

  • string: Add prefix and the string to the command line.

  • number: Add prefix and decimal representation to command line.

  • boolean: If true, add prefix to the command line. If false, add nothing.

  • File: Add prefix and the value of File.path to the command line.

  • Directory: Add prefix and the value of Directory.path to the command line.

  • array: If itemSeparator is specified, add prefix and the join the array into a single string with itemSeparator separating the items. Otherwise, first add prefix, then recursively process individual elements. If the array is empty, it does not add anything to command line.

  • object: Add prefix only, and recursively add object fields for which inputBinding is specified.

  • null: Add nothing.

7 nested properties
itemSeparator string

Join the array elements into a single string with the elements separated by itemSeparator.

loadContents boolean

Use of loadContents in InputBinding is deprecated. Preserved for v1.0 backwards compatibility. Will be removed in CWL v2.0. Use InputParameter.loadContents instead.

position string | number

The sorting key. Default position is 0. If a CWL Parameter Reference or CWL Expression is used and if the inputBinding is associated with an input parameter, then the value of self will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression. Expressions must return a single value of type int or a null.

prefix string

Command line prefix to add before the value.

separate boolean

If true (default), then the prefix and value must be added as separate command line arguments; if false, prefix and value must be concatenated into a single command line argument.

shellQuote boolean

If ShellCommandRequirement is in the requirements for the current command, this controls whether the value is quoted on the command line (default is true). Use shellQuote: false to inject metacharacters for operations such as pipes.

If shellQuote is true or not provided, the implementation must not permit interpretation of any shell metacharacters or directives.

valueFrom string

If valueFrom is a constant string value, use this as the value and apply the binding rules above.

If valueFrom is an expression, evaluate the expression to yield the actual value to use to build the command line and apply the binding rules above. If the inputBinding is associated with an input parameter, the value of self in the expression will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression.

If the value of the associated input parameter is null, valueFrom is not evaluated and nothing is added to the command line.

When a binding is part of the CommandLineTool.arguments field, the valueFrom field is required.

label string

A short, human-readable label of this object.

name string

The identifier for this type

CommandInputEnumSchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandInputEnumSchema

symbols string[] required

Defines the set of valid symbols.

type string required

Must be enum

Constant: "enum"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

inputBinding object

When listed under inputBinding in the input schema, the term "value" refers to the corresponding value in the input object. For binding objects listed in CommandLineTool.arguments, the term "value" refers to the effective value after evaluating valueFrom.

The binding behavior when building the command line depends on the data type of the value. If there is a mismatch between the type described by the input schema and the effective value, such as resulting from an expression evaluation, an implementation must use the data type of the effective value.

  • string: Add prefix and the string to the command line.

  • number: Add prefix and decimal representation to command line.

  • boolean: If true, add prefix to the command line. If false, add nothing.

  • File: Add prefix and the value of File.path to the command line.

  • Directory: Add prefix and the value of Directory.path to the command line.

  • array: If itemSeparator is specified, add prefix and the join the array into a single string with itemSeparator separating the items. Otherwise, first add prefix, then recursively process individual elements. If the array is empty, it does not add anything to command line.

  • object: Add prefix only, and recursively add object fields for which inputBinding is specified.

  • null: Add nothing.

7 nested properties
itemSeparator string

Join the array elements into a single string with the elements separated by itemSeparator.

loadContents boolean

Use of loadContents in InputBinding is deprecated. Preserved for v1.0 backwards compatibility. Will be removed in CWL v2.0. Use InputParameter.loadContents instead.

position string | number

The sorting key. Default position is 0. If a CWL Parameter Reference or CWL Expression is used and if the inputBinding is associated with an input parameter, then the value of self will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression. Expressions must return a single value of type int or a null.

prefix string

Command line prefix to add before the value.

separate boolean

If true (default), then the prefix and value must be added as separate command line arguments; if false, prefix and value must be concatenated into a single command line argument.

shellQuote boolean

If ShellCommandRequirement is in the requirements for the current command, this controls whether the value is quoted on the command line (default is true). Use shellQuote: false to inject metacharacters for operations such as pipes.

If shellQuote is true or not provided, the implementation must not permit interpretation of any shell metacharacters or directives.

valueFrom string

If valueFrom is a constant string value, use this as the value and apply the binding rules above.

If valueFrom is an expression, evaluate the expression to yield the actual value to use to build the command line and apply the binding rules above. If the inputBinding is associated with an input parameter, the value of self in the expression will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression.

If the value of the associated input parameter is null, valueFrom is not evaluated and nothing is added to the command line.

When a binding is part of the CommandLineTool.arguments field, the valueFrom field is required.

label string

A short, human-readable label of this object.

name string

The identifier for this type

CommandInputParameter object

An input parameter for a CommandLineTool.

type CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | string[] | string required

Specify valid types of data that may be assigned to this parameter.

default

The default value to use for this parameter if the parameter is missing from the input object, or if the value of the parameter in the input object is null. Default values are applied before evaluating expressions (e.g. dependent valueFrom fields).

doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

format string[] | string

Only valid when type: File or is an array of items: File.

This must be one or more IRIs of concept nodes that represents file formats which are allowed as input to this parameter, preferably defined within an ontology. If no ontology is available, file formats may be tested by exact match.

id string

The unique identifier for this object.

inputBinding object

When listed under inputBinding in the input schema, the term "value" refers to the corresponding value in the input object. For binding objects listed in CommandLineTool.arguments, the term "value" refers to the effective value after evaluating valueFrom.

The binding behavior when building the command line depends on the data type of the value. If there is a mismatch between the type described by the input schema and the effective value, such as resulting from an expression evaluation, an implementation must use the data type of the effective value.

  • string: Add prefix and the string to the command line.

  • number: Add prefix and decimal representation to command line.

  • boolean: If true, add prefix to the command line. If false, add nothing.

  • File: Add prefix and the value of File.path to the command line.

  • Directory: Add prefix and the value of Directory.path to the command line.

  • array: If itemSeparator is specified, add prefix and the join the array into a single string with itemSeparator separating the items. Otherwise, first add prefix, then recursively process individual elements. If the array is empty, it does not add anything to command line.

  • object: Add prefix only, and recursively add object fields for which inputBinding is specified.

  • null: Add nothing.

7 nested properties
itemSeparator string

Join the array elements into a single string with the elements separated by itemSeparator.

loadContents boolean

Use of loadContents in InputBinding is deprecated. Preserved for v1.0 backwards compatibility. Will be removed in CWL v2.0. Use InputParameter.loadContents instead.

position string | number

The sorting key. Default position is 0. If a CWL Parameter Reference or CWL Expression is used and if the inputBinding is associated with an input parameter, then the value of self will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression. Expressions must return a single value of type int or a null.

prefix string

Command line prefix to add before the value.

separate boolean

If true (default), then the prefix and value must be added as separate command line arguments; if false, prefix and value must be concatenated into a single command line argument.

shellQuote boolean

If ShellCommandRequirement is in the requirements for the current command, this controls whether the value is quoted on the command line (default is true). Use shellQuote: false to inject metacharacters for operations such as pipes.

If shellQuote is true or not provided, the implementation must not permit interpretation of any shell metacharacters or directives.

valueFrom string

If valueFrom is a constant string value, use this as the value and apply the binding rules above.

If valueFrom is an expression, evaluate the expression to yield the actual value to use to build the command line and apply the binding rules above. If the inputBinding is associated with an input parameter, the value of self in the expression will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression.

If the value of the associated input parameter is null, valueFrom is not evaluated and nothing is added to the command line.

When a binding is part of the CommandLineTool.arguments field, the valueFrom field is required.

label string

A short, human-readable label of this object.

loadContents boolean

Only valid when type: File or is an array of items: File.

If true, the file (or each file in the array) must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use by expressions. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

loadListing string

Only valid when type: Directory or is an array of items: Directory.

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

The order of precedence for loadListing is:

  1. loadListing on an individual parameter
  2. Inherited from LoadListingRequirement
  3. By default: no_listing
Values: "deep_listing" "no_listing" "shallow_listing"

Only valid when type: File or is an array of items: File.

Provides a pattern or expression specifying files or directories that should be included alongside the primary file. Secondary files may be required or optional. When not explicitly specified, secondary files specified for inputs are required and outputs are optional. An implementation must include matching Files and Directories in the secondaryFiles property of the primary file. These Files and Directories must be transferred and staged alongside the primary file. An implementation may fail workflow execution if a required secondary file does not exist.

If the value is an expression, the value of self in the expression must be the primary input or output File object to which this binding applies. The basename, nameroot and nameext fields must be present in self. For CommandLineTool outputs the path field must also be present. The expression must return a filename string relative to the path to the primary File, a File or Directory object with either path or location and basename fields set, or an array consisting of strings or File or Directory objects. It is legal to reference an unchanged File or Directory object taken from input as a secondaryFile. The expression may return "null" in which case there is no secondaryFile from that expression.

To work on non-filename-preserving storage systems, portable tool descriptions should avoid constructing new values from location, but should construct relative references using basename or nameroot instead.

If a value in secondaryFiles is a string that is not an expression, it specifies that the following pattern should be applied to the path of the primary file to yield a filename relative to the primary File:

  1. If string ends with ? character, remove the last ? and mark the resulting secondary file as optional.
  2. If string begins with one or more caret ^ characters, for each caret, remove the last file extension from the path (the last period . and all following characters). If there are no file extensions, the path is unchanged.
  3. Append the remainder of the string to the end of the file path.
streamable boolean

Only valid when type: File or is an array of items: File.

A value of true indicates that the file is read or written sequentially without seeking. An implementation may use this flag to indicate whether it is valid to stream file contents using a named pipe. Default: false.

CommandInputRecordField object | CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | string[] | string[]

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandInputRecordField

CommandInputRecordSchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandInputRecordSchema

type string required

Must be record

Constant: "record"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

fields CommandInputRecordField[] | object

Defines the fields of the record.

inputBinding object

When listed under inputBinding in the input schema, the term "value" refers to the corresponding value in the input object. For binding objects listed in CommandLineTool.arguments, the term "value" refers to the effective value after evaluating valueFrom.

The binding behavior when building the command line depends on the data type of the value. If there is a mismatch between the type described by the input schema and the effective value, such as resulting from an expression evaluation, an implementation must use the data type of the effective value.

  • string: Add prefix and the string to the command line.

  • number: Add prefix and decimal representation to command line.

  • boolean: If true, add prefix to the command line. If false, add nothing.

  • File: Add prefix and the value of File.path to the command line.

  • Directory: Add prefix and the value of Directory.path to the command line.

  • array: If itemSeparator is specified, add prefix and the join the array into a single string with itemSeparator separating the items. Otherwise, first add prefix, then recursively process individual elements. If the array is empty, it does not add anything to command line.

  • object: Add prefix only, and recursively add object fields for which inputBinding is specified.

  • null: Add nothing.

7 nested properties
itemSeparator string

Join the array elements into a single string with the elements separated by itemSeparator.

loadContents boolean

Use of loadContents in InputBinding is deprecated. Preserved for v1.0 backwards compatibility. Will be removed in CWL v2.0. Use InputParameter.loadContents instead.

position string | number

The sorting key. Default position is 0. If a CWL Parameter Reference or CWL Expression is used and if the inputBinding is associated with an input parameter, then the value of self will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression. Expressions must return a single value of type int or a null.

prefix string

Command line prefix to add before the value.

separate boolean

If true (default), then the prefix and value must be added as separate command line arguments; if false, prefix and value must be concatenated into a single command line argument.

shellQuote boolean

If ShellCommandRequirement is in the requirements for the current command, this controls whether the value is quoted on the command line (default is true). Use shellQuote: false to inject metacharacters for operations such as pipes.

If shellQuote is true or not provided, the implementation must not permit interpretation of any shell metacharacters or directives.

valueFrom string

If valueFrom is a constant string value, use this as the value and apply the binding rules above.

If valueFrom is an expression, evaluate the expression to yield the actual value to use to build the command line and apply the binding rules above. If the inputBinding is associated with an input parameter, the value of self in the expression will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression.

If the value of the associated input parameter is null, valueFrom is not evaluated and nothing is added to the command line.

When a binding is part of the CommandLineTool.arguments field, the valueFrom field is required.

label string

A short, human-readable label of this object.

name string

The identifier for this type

CommandLineBinding object

When listed under inputBinding in the input schema, the term "value" refers to the corresponding value in the input object. For binding objects listed in CommandLineTool.arguments, the term "value" refers to the effective value after evaluating valueFrom.

The binding behavior when building the command line depends on the data type of the value. If there is a mismatch between the type described by the input schema and the effective value, such as resulting from an expression evaluation, an implementation must use the data type of the effective value.

  • string: Add prefix and the string to the command line.

  • number: Add prefix and decimal representation to command line.

  • boolean: If true, add prefix to the command line. If false, add nothing.

  • File: Add prefix and the value of File.path to the command line.

  • Directory: Add prefix and the value of Directory.path to the command line.

  • array: If itemSeparator is specified, add prefix and the join the array into a single string with itemSeparator separating the items. Otherwise, first add prefix, then recursively process individual elements. If the array is empty, it does not add anything to command line.

  • object: Add prefix only, and recursively add object fields for which inputBinding is specified.

  • null: Add nothing.

itemSeparator string

Join the array elements into a single string with the elements separated by itemSeparator.

loadContents boolean

Use of loadContents in InputBinding is deprecated. Preserved for v1.0 backwards compatibility. Will be removed in CWL v2.0. Use InputParameter.loadContents instead.

position string | number

The sorting key. Default position is 0. If a CWL Parameter Reference or CWL Expression is used and if the inputBinding is associated with an input parameter, then the value of self will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression. Expressions must return a single value of type int or a null.

prefix string

Command line prefix to add before the value.

separate boolean

If true (default), then the prefix and value must be added as separate command line arguments; if false, prefix and value must be concatenated into a single command line argument.

shellQuote boolean

If ShellCommandRequirement is in the requirements for the current command, this controls whether the value is quoted on the command line (default is true). Use shellQuote: false to inject metacharacters for operations such as pipes.

If shellQuote is true or not provided, the implementation must not permit interpretation of any shell metacharacters or directives.

valueFrom string

If valueFrom is a constant string value, use this as the value and apply the binding rules above.

If valueFrom is an expression, evaluate the expression to yield the actual value to use to build the command line and apply the binding rules above. If the inputBinding is associated with an input parameter, the value of self in the expression will be the value of the input parameter. Input parameter defaults (as specified by the InputParameter.default field) must be applied before evaluating the expression.

If the value of the associated input parameter is null, valueFrom is not evaluated and nothing is added to the command line.

When a binding is part of the CommandLineTool.arguments field, the valueFrom field is required.

CommandLineTool object

This defines the schema of the CWL Command Line Tool Description document.

class string required
Constant: "CommandLineTool"
inputs CommandInputParameter[] | object required

Defines the input parameters of the process. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is used to validate the input object. It may also be used to build a user interface for constructing the input object.

When accepting an input object, all input parameters must have a value. If an input parameter is missing from the input object, it must be assigned a value of null (or the value of default for that parameter, if provided) for the purposes of validation and evaluation of expressions.

outputs CommandOutputParameter[] | object required

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

arguments CommandLineBinding | string[]

Command line bindings which are not directly associated with input parameters. If the value is a string, it is used as a string literal argument. If it is an Expression, the result of the evaluation is used as an argument.

baseCommand string[] | string

Specifies the program to execute. If an array, the first element of the array is the command to execute, and subsequent elements are mandatory command line arguments. The elements in baseCommand must appear before any command line bindings from inputBinding or arguments.

If baseCommand is not provided or is an empty array, the first element of the command line produced after processing inputBinding or arguments must be used as the program to execute.

If the program includes a path separator character it must be an absolute path, otherwise it is an error. If the program does not include a path separator, search the $PATH variable in the runtime environment of the workflow runner find the absolute path of the executable.

cwlVersion string

CWL document version. Always required at the document root. Not required for a Process embedded inside another Process.

Values: "draft-2" "draft-3" "draft-3.dev1" "draft-3.dev2" "draft-3.dev3" "draft-3.dev4" "draft-3.dev5" "draft-4.dev1" "draft-4.dev2" "draft-4.dev3" "v1.0" "v1.0.dev4" "v1.1" "v1.1.0-dev1" "v1.2" "v1.2.0-dev1" "v1.2.0-dev2" "v1.2.0-dev3" "v1.2.0-dev4" "v1.2.0-dev5"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

hints CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this process. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

id string

The unique identifier for this object.

Only useful for $graph at Process level. Should not be exposed to users in graphical or terminal user interfaces.

intent string[]

An identifier for the type of computational operation, of this Process. Especially useful for Operation, but can also be used for CommandLineTool, Workflow, or ExpressionTool.

If provided, then this must be an IRI of a concept node that represents the type of operation, preferably defined within an ontology.

For example, in the domain of bioinformatics, one can use an IRI from the EDAM Ontology's Operation concept nodes, like Alignment, or Clustering; or a more specific Operation concept like Split read mapping.

label string

A short, human-readable label of this object.

permanentFailCodes number[]

Exit codes that indicate the process failed due to a permanent logic error, where executing the process with the same runtime environment and same inputs is expected to always fail. If not specified, all exit codes except 0 are considered permanent failure.

requirements CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this process. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

stderr string

Capture the command's standard error stream to a file written to the designated output directory.

If stderr is a string, it specifies the file name to use.

If stderr is an expression, the expression is evaluated and must return a string with the file name to use to capture stderr. If the return value is not a string, or the resulting path contains illegal characters (such as the path separator /) it is an error.

stdin string

A path to a file whose contents must be piped into the command's standard input stream.

stdout string

Capture the command's standard output stream to a file written to the designated output directory.

If the CommandLineTool contains logically chained commands (e.g. echo a && echo b) stdout must include the output of every command.

If stdout is a string, it specifies the file name to use.

If stdout is an expression, the expression is evaluated and must return a string with the file name to use to capture stdout. If the return value is not a string, or the resulting path contains illegal characters (such as the path separator /) it is an error.

successCodes number[]

Exit codes that indicate the process completed successfully.

If not specified, only exit code 0 is considered success.

temporaryFailCodes number[]

Exit codes that indicate the process failed due to a possibly temporary condition, where executing the process with the same runtime environment and inputs may produce different results.

If not specified, no exit codes are considered temporary failure.

CommandOutputArraySchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandOutputArraySchema

items CommandOutputArraySchema | CommandOutputRecordSchema | CommandOutputEnumSchema | CommandOutputArraySchema | CommandOutputRecordSchema | CommandOutputEnumSchema | string[] | string required

Defines the type of the array elements.

type string required

Must be array

Constant: "array"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

label string

A short, human-readable label of this object.

name string

The identifier for this type

CommandOutputBinding object

Describes how to generate an output parameter based on the files produced by a CommandLineTool.

The output parameter value is generated by applying these operations in the following order:

  • glob
  • loadContents
  • outputEval
  • secondaryFiles
glob string[] | string

Find files or directories relative to the output directory, using POSIX glob(3) pathname matching. If an array is provided, find files or directories that match any pattern in the array. If an expression is provided, the expression must return a string or an array of strings, which will then be evaluated as one or more glob patterns. Must only match and return files/directories which actually exist.

If the value of glob is a relative path pattern (does not begin with a slash '/') then it is resolved relative to the output directory. If the value of the glob is an absolute path pattern (it does begin with a slash '/') then it must refer to a path within the output directory. It is an error if any glob resolves to a path outside the output directory. Specifically this means globs that resolve to paths outside the output directory are illegal.

A glob may match a path within the output directory which is actually a symlink to another file. In this case, the expected behavior is for the resulting File/Directory object to take the basename (and corresponding nameroot and nameext) of the symlink. The location of the File/Directory is implementation dependent, but logically the File/Directory should have the same content as the symlink target. Platforms may stage output files/directories to cloud storage that lack the concept of a symlink. In this case file content and directories may be duplicated, or (to avoid duplication) the File/Directory location may refer to the symlink target.

It is an error if a symlink in the output directory (or any symlink in a chain of links) refers to any file or directory that is not under an input or output directory.

Implementations may shut down a container before globbing output, so globs and expressions must not assume access to the container filesystem except for declared input and output.

loadContents boolean

Only valid when type: File or is an array of items: File.

If true, the file (or each file in the array) must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use by expressions. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

loadListing string

Only valid when type: Directory or is an array of items: Directory.

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

The order of precedence for loadListing is:

  1. loadListing on an individual parameter
  2. Inherited from LoadListingRequirement
  3. By default: no_listing
Values: "deep_listing" "no_listing" "shallow_listing"
outputEval string

Evaluate an expression to generate the output value. If glob was specified, the value of self must be an array containing file objects that were matched. If no files were matched, self must be a zero length array; if a single file was matched, the value of self is an array of a single element. The exit code of the process is available in the expression as runtime.exitCode.

Additionally, if loadContents is true, the file must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use in outputEval. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

If a tool needs to return a large amount of structured data to the workflow, loading the output object from cwl.output.json bypasses outputEval and is not subject to the 64 KiB loadContents limit.

CommandOutputEnumSchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandOutputEnumSchema

symbols string[] required

Defines the set of valid symbols.

type string required

Must be enum

Constant: "enum"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

label string

A short, human-readable label of this object.

name string

The identifier for this type

CommandOutputParameter object

An output parameter for a CommandLineTool.

type CommandOutputArraySchema | CommandOutputRecordSchema | CommandOutputEnumSchema | CommandOutputArraySchema | CommandOutputRecordSchema | CommandOutputEnumSchema | string[] | string required

Specify valid types of data that may be assigned to this parameter.

doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

format string

Only valid when type: File or is an array of items: File.

This is the file format that will be assigned to the output File object.

id string

The unique identifier for this object.

label string

A short, human-readable label of this object.

outputBinding object

Describes how to generate an output parameter based on the files produced by a CommandLineTool.

The output parameter value is generated by applying these operations in the following order:

  • glob
  • loadContents
  • outputEval
  • secondaryFiles
4 nested properties
glob string[] | string

Find files or directories relative to the output directory, using POSIX glob(3) pathname matching. If an array is provided, find files or directories that match any pattern in the array. If an expression is provided, the expression must return a string or an array of strings, which will then be evaluated as one or more glob patterns. Must only match and return files/directories which actually exist.

If the value of glob is a relative path pattern (does not begin with a slash '/') then it is resolved relative to the output directory. If the value of the glob is an absolute path pattern (it does begin with a slash '/') then it must refer to a path within the output directory. It is an error if any glob resolves to a path outside the output directory. Specifically this means globs that resolve to paths outside the output directory are illegal.

A glob may match a path within the output directory which is actually a symlink to another file. In this case, the expected behavior is for the resulting File/Directory object to take the basename (and corresponding nameroot and nameext) of the symlink. The location of the File/Directory is implementation dependent, but logically the File/Directory should have the same content as the symlink target. Platforms may stage output files/directories to cloud storage that lack the concept of a symlink. In this case file content and directories may be duplicated, or (to avoid duplication) the File/Directory location may refer to the symlink target.

It is an error if a symlink in the output directory (or any symlink in a chain of links) refers to any file or directory that is not under an input or output directory.

Implementations may shut down a container before globbing output, so globs and expressions must not assume access to the container filesystem except for declared input and output.

loadContents boolean

Only valid when type: File or is an array of items: File.

If true, the file (or each file in the array) must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use by expressions. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

loadListing string

Only valid when type: Directory or is an array of items: Directory.

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

The order of precedence for loadListing is:

  1. loadListing on an individual parameter
  2. Inherited from LoadListingRequirement
  3. By default: no_listing
Values: "deep_listing" "no_listing" "shallow_listing"
outputEval string

Evaluate an expression to generate the output value. If glob was specified, the value of self must be an array containing file objects that were matched. If no files were matched, self must be a zero length array; if a single file was matched, the value of self is an array of a single element. The exit code of the process is available in the expression as runtime.exitCode.

Additionally, if loadContents is true, the file must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use in outputEval. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

If a tool needs to return a large amount of structured data to the workflow, loading the output object from cwl.output.json bypasses outputEval and is not subject to the 64 KiB loadContents limit.

Only valid when type: File or is an array of items: File.

Provides a pattern or expression specifying files or directories that should be included alongside the primary file. Secondary files may be required or optional. When not explicitly specified, secondary files specified for inputs are required and outputs are optional. An implementation must include matching Files and Directories in the secondaryFiles property of the primary file. These Files and Directories must be transferred and staged alongside the primary file. An implementation may fail workflow execution if a required secondary file does not exist.

If the value is an expression, the value of self in the expression must be the primary input or output File object to which this binding applies. The basename, nameroot and nameext fields must be present in self. For CommandLineTool outputs the path field must also be present. The expression must return a filename string relative to the path to the primary File, a File or Directory object with either path or location and basename fields set, or an array consisting of strings or File or Directory objects. It is legal to reference an unchanged File or Directory object taken from input as a secondaryFile. The expression may return "null" in which case there is no secondaryFile from that expression.

To work on non-filename-preserving storage systems, portable tool descriptions should avoid constructing new values from location, but should construct relative references using basename or nameroot instead.

If a value in secondaryFiles is a string that is not an expression, it specifies that the following pattern should be applied to the path of the primary file to yield a filename relative to the primary File:

  1. If string ends with ? character, remove the last ? and mark the resulting secondary file as optional.
  2. If string begins with one or more caret ^ characters, for each caret, remove the last file extension from the path (the last period . and all following characters). If there are no file extensions, the path is unchanged.
  3. Append the remainder of the string to the end of the file path.
streamable boolean

Only valid when type: File or is an array of items: File.

A value of true indicates that the file is read or written sequentially without seeking. An implementation may use this flag to indicate whether it is valid to stream file contents using a named pipe. Default: false.

CommandOutputRecordField object | CommandOutputArraySchema | CommandOutputRecordSchema | CommandOutputEnumSchema | CommandOutputArraySchema | CommandOutputRecordSchema | CommandOutputEnumSchema | string[] | string[]

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandOutputRecordField

CommandOutputRecordSchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandOutputRecordSchema

type string required

Must be record

Constant: "record"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

fields CommandOutputRecordField[] | object

Defines the fields of the record.

label string

A short, human-readable label of this object.

name string

The identifier for this type

DefaultFetcher object
Dictionary<any> Record<string, object>
Dictionary<string> Record<string, object>
Directory object

Represents a directory to present to a command line tool.

Directories are represented as objects with class of Directory. Directory objects have a number of properties that provide metadata about the directory.

The location property of a Directory is a IRI that uniquely identifies the directory. Implementations must support the file:// IRI scheme and may support other schemes such as http://. Alternately to location, implementations must also accept the path property on Directory, which must be a filesystem path available on the same host as the CWL runner (for inputs) or the runtime environment of a command line tool execution (for command line tool outputs).

A Directory object may have a listing field. This is a list of File and Directory objects that are contained in the Directory. For each entry in listing, the basename property defines the name of the File or Subdirectory when staged to disk. If listing is not provided, the implementation must have some way of fetching the Directory listing at runtime based on the location field.

If a Directory does not have location, it is a Directory literal. A Directory literal must provide listing. Directory literals must be created on disk at runtime as needed.

The resources in a Directory literal do not need to have any implied relationship in their location. For example, a Directory listing may contain two files located on different hosts. It is the responsibility of the runtime to ensure that those files are staged to disk appropriately. Secondary files associated with files in listing must also be staged to the same Directory.

When executing a CommandLineTool, Directories must be recursively staged first and have local values of path assigned.

Directory objects in CommandLineTool output must provide either a location IRI or a path property in the context of the tool execution runtime (local to the compute node, or within the executing container).

An ExpressionTool may forward file references from input to output by using the same value for location.

Name conflicts (the same basename appearing multiple times in listing or in any entry in secondaryFiles in the listing) is a fatal error.

class string required

Must be Directory to indicate this object describes a Directory.

Constant: "Directory"
basename string

The base name of the directory, that is, the name of the file without any leading directory path. The base name must not contain a slash /.

If not provided, the implementation must set this field based on the location field by taking the final path component after parsing location as an IRI. If basename is provided, it is not required to match the value from location.

When this file is made available to a CommandLineTool, it must be named with basename, i.e. the final component of the path field must match basename.

listing Directory | File[]

List of files or subdirectories contained in this directory. The name of each file or subdirectory is determined by the basename field of each File or Directory object. It is an error if a File shares a basename with any other entry in listing. If two or more Directory object share the same basename, this must be treated as equivalent to a single subdirectory with the listings recursively merged.

location string

An IRI that identifies the directory resource. This may be a relative reference, in which case it must be resolved using the base IRI of the document. The location may refer to a local or remote resource. If the listing field is not set, the implementation must use the location IRI to retrieve directory listing. If an implementation is unable to retrieve the directory listing stored at a remote resource (due to unsupported protocol, access denied, or other issue) it must signal an error.

If the location field is not provided, the listing field must be provided. The implementation must assign a unique identifier for the location field.

If the path field is provided but the location field is not, an implementation may assign the value of the path field to location, then follow the rules above.

path string

The local path where the Directory is made available prior to executing a CommandLineTool. This must be set by the implementation. This field must not be used in any other context. The command line tool being executed must be able to access the directory at path using the POSIX opendir(2) syscall.

If the path contains POSIX shell metacharacters (|,&, ;, <, >, (,), $,`, \, ", ', <space>, <tab>, and <newline>) or characters not allowed for Internationalized Domain Names for Applications then implementations may terminate the process with a permanentFailure.

Dirent object

Define a file or subdirectory that must be staged to a particular place prior to executing the command line tool. May be the result of executing an expression, such as building a configuration file from a template.

Usually files are staged within the designated output directory. However, under certain circumstances, files may be staged at arbitrary locations, see discussion for entryname.

entry string required

If the value is a string literal or an expression which evaluates to a string, a new text file must be created with the string as the file contents.

If the value is an expression that evaluates to a File or Directory object, or an array of File or Directory objects, this indicates the referenced file or directory should be added to the designated output directory prior to executing the tool.

If the value is an expression that evaluates to null, nothing is added to the designated output directory, the entry has no effect.

If the value is an expression that evaluates to some other array, number, or object not consisting of File or Directory objects, a new file must be created with the value serialized to JSON text as the file contents. The JSON serialization behavior should match the behavior of string interpolation of Parameter references.

entryname string

The "target" name of the file or subdirectory. If entry is a File or Directory, the entryname field overrides the value of basename of the File or Directory object.

  • Required when entry evaluates to file contents only
  • Optional when entry evaluates to a File or Directory object with a basename
  • Invalid when entry evaluates to an array of File or Directory objects.

If entryname is a relative path, it specifies a name within the designated output directory. A relative path starting with ../ or that resolves to location above the designated output directory is an error.

If entryname is an absolute path (starts with a slash /) it is an error unless the following conditions are met:

  • DockerRequirement is present in requirements
  • The program is will run inside a software container where, from the perspective of the program, the root filesystem is not shared with any other user or running program.

In this case, and the above conditions are met, then entryname may specify the absolute path within the container where the file or directory must be placed.

writable boolean

If true, the File or Directory (or array of Files or Directories) declared in entry must be writable by the tool.

Changes to the file or directory must be isolated and not visible by any other CommandLineTool process. This may be implemented by making a copy of the original file or directory.

Disruptive changes to the referenced file or directory must not be allowed unless InplaceUpdateRequirement.inplaceUpdate is true.

Default false (files and directories read-only by default).

A directory marked as writable: true implies that all files and subdirectories are recursively writable as well.

If writable is false, the file may be made available using a bind mount or file system link to avoid unnecessary copying of the input file. Command line tools may receive an error on attempting to rename or delete files or directories that are not explicitly marked as writable.

DockerRequirement object

Indicates that a workflow component should be run in a Docker or Docker-compatible (such as Singularity and udocker) container environment and specifies how to fetch or build the image.

If a CommandLineTool lists DockerRequirement under hints (or requirements), it may (or must) be run in the specified Docker container.

The platform must first acquire or install the correct Docker image as specified by dockerPull, dockerImport, dockerLoad or dockerFile.

The platform must execute the tool in the container using docker run with the appropriate Docker image and tool command line.

The workflow platform may provide input files and the designated output directory through the use of volume bind mounts. The platform should rewrite file paths in the input object to correspond to the Docker bind mounted locations. That is, the platform should rewrite values in the parameter context such as runtime.outdir, runtime.tmpdir and others to be valid paths within the container. The platform must ensure that runtime.outdir and runtime.tmpdir are distinct directories.

When running a tool contained in Docker, the workflow platform must not assume anything about the contents of the Docker container, such as the presence or absence of specific software, except to assume that the generated command line represents a valid command within the runtime environment of the container.

A container image may specify an ENTRYPOINT and/or CMD. Command line arguments will be appended after all elements of ENTRYPOINT, and will override all elements specified using CMD (in other words, CMD is only used when the CommandLineTool definition produces an empty command line).

Use of implicit ENTRYPOINT or CMD are discouraged due to reproducibility concerns of the implicit hidden execution point (For further discussion, see [https://doi.org/10.12688/f1000research.15140.1](https://doi.org/10.12688/f1000research.15140.1)). Portable CommandLineTool wrappers in which use of a container is optional must not rely on ENTRYPOINT or CMD. CommandLineTools which do rely on ENTRYPOINT or CMD must list DockerRequirement in the requirements section.

Interaction with other requirements

If EnvVarRequirement is specified alongside a DockerRequirement, the environment variables must be provided to Docker using --env or --env-file and interact with the container's preexisting environment as defined by Docker.

class string required

Always 'DockerRequirement'

Constant: "DockerRequirement"
dockerFile string

Supply the contents of a Dockerfile which will be built using docker build.

dockerImageId string

The image id that will be used for docker run. May be a human-readable image name or the image identifier hash. May be skipped if dockerPull is specified, in which case the dockerPull image id must be used.

dockerImport string

Provide HTTP URL to download and gunzip a Docker images using `docker import.

dockerLoad string

Specify an HTTP URL from which to download a Docker image using docker load.

dockerOutputDirectory string

Set the designated output directory to a specific location inside the Docker container.

dockerPull string

Specify a Docker image to retrieve using docker pull. Can contain the immutable digest to ensure an exact container is used: dockerPull: ubuntu@sha256:45b23dee08af5e43a7fea6c4cf9c25ccf269ee113168c19722f87876677c5cb2

EnvVarRequirement object

Define a list of environment variables which will be set in the execution environment of the tool. See EnvironmentDef for details.

class string required

Always 'EnvVarRequirement'

Constant: "EnvVarRequirement"
envDef EnvironmentDef | CWLImportManual | CWLIncludeManual[] required

The list of environment variables.

EnvironmentDef object

Define an environment variable that will be set in the runtime environment by the workflow platform when executing the command line tool. May be the result of executing an expression, such as getting a parameter from input.

envName string required

The environment variable name

envValue string required

The environment variable value

ExpressionTool object

An ExpressionTool is a type of Process object that can be run by itself or as a Workflow step. It executes a pure Javascript expression that has access to the same input parameters as a workflow. It is meant to be used sparingly as a way to isolate complex Javascript expressions that need to operate on input data and produce some result; perhaps just a rearrangement of the inputs. No Docker software container is required or allowed.

class string required
Constant: "ExpressionTool"
expression string required

The expression to execute. The expression must return a plain Javascript object which matches the output parameters of the ExpressionTool.

inputs WorkflowInputParameter[] | object required

Defines the input parameters of the process. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is used to validate the input object. It may also be used to build a user interface for constructing the input object.

When accepting an input object, all input parameters must have a value. If an input parameter is missing from the input object, it must be assigned a value of null (or the value of default for that parameter, if provided) for the purposes of validation and evaluation of expressions.

outputs ExpressionToolOutputParameter[] | object required

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

cwlVersion string

CWL document version. Always required at the document root. Not required for a Process embedded inside another Process.

Values: "draft-2" "draft-3" "draft-3.dev1" "draft-3.dev2" "draft-3.dev3" "draft-3.dev4" "draft-3.dev5" "draft-4.dev1" "draft-4.dev2" "draft-4.dev3" "v1.0" "v1.0.dev4" "v1.1" "v1.1.0-dev1" "v1.2" "v1.2.0-dev1" "v1.2.0-dev2" "v1.2.0-dev3" "v1.2.0-dev4" "v1.2.0-dev5"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

hints CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this process. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

id string

The unique identifier for this object.

Only useful for $graph at Process level. Should not be exposed to users in graphical or terminal user interfaces.

intent string[]

An identifier for the type of computational operation, of this Process. Especially useful for Operation, but can also be used for CommandLineTool, Workflow, or ExpressionTool.

If provided, then this must be an IRI of a concept node that represents the type of operation, preferably defined within an ontology.

For example, in the domain of bioinformatics, one can use an IRI from the EDAM Ontology's Operation concept nodes, like Alignment, or Clustering; or a more specific Operation concept like Split read mapping.

label string

A short, human-readable label of this object.

requirements CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this process. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

ExpressionToolOutputParameter object

Auto-generated class implementation for https://w3id.org/cwl/cwl#ExpressionToolOutputParameter

type OutputRecordSchema | OutputEnumSchema | OutputArraySchema | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | string[] | string required

Specify valid types of data that may be assigned to this parameter. Note that this field just acts as a hint, as the outputs of an ExpressionTool process are always considered valid.

doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

format string

Only valid when type: File or is an array of items: File.

This is the file format that will be assigned to the output File object.

id string

The unique identifier for this object.

label string

A short, human-readable label of this object.

Only valid when type: File or is an array of items: File.

Provides a pattern or expression specifying files or directories that should be included alongside the primary file. Secondary files may be required or optional. When not explicitly specified, secondary files specified for inputs are required and outputs are optional. An implementation must include matching Files and Directories in the secondaryFiles property of the primary file. These Files and Directories must be transferred and staged alongside the primary file. An implementation may fail workflow execution if a required secondary file does not exist.

If the value is an expression, the value of self in the expression must be the primary input or output File object to which this binding applies. The basename, nameroot and nameext fields must be present in self. For CommandLineTool outputs the path field must also be present. The expression must return a filename string relative to the path to the primary File, a File or Directory object with either path or location and basename fields set, or an array consisting of strings or File or Directory objects. It is legal to reference an unchanged File or Directory object taken from input as a secondaryFile. The expression may return "null" in which case there is no secondaryFile from that expression.

To work on non-filename-preserving storage systems, portable tool descriptions should avoid constructing new values from location, but should construct relative references using basename or nameroot instead.

If a value in secondaryFiles is a string that is not an expression, it specifies that the following pattern should be applied to the path of the primary file to yield a filename relative to the primary File:

  1. If string ends with ? character, remove the last ? and mark the resulting secondary file as optional.
  2. If string begins with one or more caret ^ characters, for each caret, remove the last file extension from the path (the last period . and all following characters). If there are no file extensions, the path is unchanged.
  3. Append the remainder of the string to the end of the file path.
streamable boolean

Only valid when type: File or is an array of items: File.

A value of true indicates that the file is read or written sequentially without seeking. An implementation may use this flag to indicate whether it is valid to stream file contents using a named pipe. Default: false.

Fetcher DefaultFetcher
File object

Represents a file (or group of files when secondaryFiles is provided) that will be accessible by tools using standard POSIX file system call API such as open(2) and read(2).

Files are represented as objects with class of File. File objects have a number of properties that provide metadata about the file.

The location property of a File is a IRI that uniquely identifies the file. Implementations must support the file:// IRI scheme and may support other schemes such as <http://> and <https://>. The value of location may also be a relative reference, in which case it must be resolved relative to the IRI of the document it appears in. Alternately to location, implementations must also accept the path property on File, which must be a filesystem path available on the same host as the CWL runner (for inputs) or the runtime environment of a command line tool execution (for command line tool outputs).

If no location or path is specified, a file object must specify contents with the UTF-8 text content of the file. This is a "file literal". File literals do not correspond to external resources, but are created on disk with contents with when needed for executing a tool. Where appropriate, expressions can return file literals to define new files on a runtime. The maximum size of contents is 64 kilobytes.

The basename property defines the filename on disk where the file is staged. This may differ from the resource name. If not provided, basename must be computed from the last path part of location and made available to expressions.

The secondaryFiles property is a list of File or Directory objects that must be staged in the same directory as the primary file. It is an error for file names to be duplicated in secondaryFiles.

The size property is the size in bytes of the File. It must be computed from the resource and made available to expressions. The checksum field contains a cryptographic hash of the file content for use it verifying file contents. Implementations may, at user option, enable or disable computation of the checksum field for performance or other reasons. However, the ability to compute output checksums is required to pass the CWL conformance test suite.

When executing a CommandLineTool, the files and secondary files may be staged to an arbitrary directory, but must use the value of basename for the filename. The path property must be file path in the context of the tool execution runtime (local to the compute node, or within the executing container). All computed properties should be available to expressions. File literals also must be staged and path must be set.

When collecting CommandLineTool outputs, glob matching returns file paths (with the path property) and the derived properties. This can all be modified by outputEval. Alternately, if the file cwl.output.json is present in the output, outputBinding is ignored.

File objects in the output must provide either a location IRI or a path property in the context of the tool execution runtime (local to the compute node, or within the executing container).

When evaluating an ExpressionTool, file objects must be referenced via location (the expression tool does not have access to files on disk so path is meaningless) or as file literals. It is legal to return a file object with an existing location but a different basename. The loadContents field of ExpressionTool inputs behaves the same as on CommandLineTool inputs, however it is not meaningful on the outputs.

An ExpressionTool may forward file references from input to output by using the same value for location.

class string required

Must be File to indicate this object describes a file.

Constant: "File"
basename string

The base name of the file, that is, the name of the file without any leading directory path. The base name must not contain a slash /.

If not provided, the implementation must set this field based on the location field by taking the final path component after parsing location as an IRI. If basename is provided, it is not required to match the value from location.

When this file is made available to a CommandLineTool, it must be named with basename, i.e. the final component of the path field must match basename.

checksum string

Optional hash code for validating file integrity. Currently, must be in the form "sha1$ + hexadecimal string" using the SHA-1 algorithm.

contents string

File contents literal.

If neither location nor path is provided, contents must be non-null. The implementation must assign a unique identifier for the location field. When the file is staged as input to CommandLineTool, the value of contents must be written to a file.

If contents is set as a result of a Javascript expression, an entry in InitialWorkDirRequirement, or read in from cwl.output.json, there is no specified upper limit on the size of contents. Implementations may have practical limits on the size of contents based on memory and storage available to the workflow runner or other factors.

If the loadContents field of an InputParameter or OutputParameter is true, and the input or output File object location is valid, the file must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file and place it in the contents field. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

dirname string

The name of the directory containing file, that is, the path leading up to the final slash in the path such that dirname + '/' + basename == path.

The implementation must set this field based on the value of path prior to evaluating parameter references or expressions in a CommandLineTool document. This field must not be used in any other context.

format string

The format of the file: this must be an IRI of a concept node that represents the file format, preferably defined within an ontology. If no ontology is available, file formats may be tested by exact match.

Reasoning about format compatibility must be done by checking that an input file format is the same, owl:equivalentClass or rdfs:subClassOf the format required by the input parameter. owl:equivalentClass is transitive with rdfs:subClassOf, e.g. if <B> owl:equivalentClass <C> and <B> owl:subclassOf <A> then infer <C> owl:subclassOf <A>.

File format ontologies may be provided in the "$schemas" metadata at the root of the document. If no ontologies are specified in $schemas, the runtime may perform exact file format matches.

location string

An IRI that identifies the file resource. This may be a relative reference, in which case it must be resolved using the base IRI of the document. The location may refer to a local or remote resource; the implementation must use the IRI to retrieve file content. If an implementation is unable to retrieve the file content stored at a remote resource (due to unsupported protocol, access denied, or other issue) it must signal an error.

If the location field is not provided, the contents field must be provided. The implementation must assign a unique identifier for the location field.

If the path field is provided but the location field is not, an implementation may assign the value of the path field to location, then follow the rules above.

nameext string

The basename extension such that nameroot + nameext == basename, and nameext is empty or begins with a period and contains at most one period. Leading periods on the basename are ignored; a basename of .cshrc will have an empty nameext.

The implementation must set this field automatically based on the value of basename prior to evaluating parameter references or expressions.

nameroot string

The basename root such that nameroot + nameext == basename, and nameext is empty or begins with a period and contains at most one period. For the purposes of path splitting leading periods on the basename are ignored; a basename of .cshrc will have a nameroot of .cshrc.

The implementation must set this field automatically based on the value of basename prior to evaluating parameter references or expressions.

path string

The local host path where the File is available when a CommandLineTool is executed. This field must be set by the implementation. The final path component must match the value of basename. This field must not be used in any other context. The command line tool being executed must be able to access the file at path using the POSIX open(2) syscall.

As a special case, if the path field is provided but the location field is not, an implementation may assign the value of the path field to location, and remove the path field.

If the path contains POSIX shell metacharacters (|,&, ;, <, >, (,), $,`, \, ", ', <space>, <tab>, and <newline>) or characters not allowed for Internationalized Domain Names for Applications then implementations may terminate the process with a permanentFailure.

secondaryFiles Directory | File[]

A list of additional files or directories that are associated with the primary file and must be transferred alongside the primary file. Examples include indexes of the primary file, or external references which must be included when loading primary document. A file object listed in secondaryFiles may itself include secondaryFiles for which the same rules apply.

size number

Optional file size (in bytes)

InitialWorkDirRequirement object

Define a list of files and subdirectories that must be staged by the workflow platform prior to executing the command line tool. Normally files are staged within the designated output directory. However, when running inside containers, files may be staged at arbitrary locations, see discussion for Dirent.entryname. Together with DockerRequirement.dockerOutputDirectory it is possible to control the locations of both input and output files when running in containers.

class string required

InitialWorkDirRequirement

Constant: "InitialWorkDirRequirement"
listing Directory | File | Directory | File | CWLImportManual | CWLIncludeManual[] | Dirent | string | CWLImportManual | CWLIncludeManual[] | string

The list of files or subdirectories that must be staged prior to executing the command line tool.

Return type of each expression must validate as ["null", File, Directory, Dirent, {type: array, items: [File, Directory]}].

Each File or Directory that is returned by an Expression must be added to the designated output directory prior to executing the tool.

Each Dirent record that is listed or returned by an expression specifies a file to be created or staged in the designated output directory prior to executing the tool.

Expressions may return null, in which case they have no effect.

Files or Directories which are listed in the input parameters and appear in the InitialWorkDirRequirement listing must have their path set to their staged location. If the same File or Directory appears more than once in the InitialWorkDirRequirement listing, the implementation must choose exactly one value for path; how this value is chosen is undefined.

InlineJavascriptRequirement object

Indicates that the workflow platform must support inline Javascript expressions. If this requirement is not present, the workflow platform must not perform expression interpolation.

class string required

Always 'InlineJavascriptRequirement'

Constant: "InlineJavascriptRequirement"
expressionLib string | CWLImportManual | CWLIncludeManual[]

Additional code fragments that will also be inserted before executing the expression code. Allows for function definitions that may be called from CWL expressions.

InplaceUpdateRequirement object

If inplaceUpdate is true, then an implementation supporting this feature may permit tools to directly update files with writable: true in InitialWorkDirRequirement. That is, as an optimization, files may be destructively modified in place as opposed to copied and updated.

An implementation must ensure that only one workflow step may access a writable file at a time. It is an error if a file which is writable by one workflow step file is accessed (for reading or writing) by any other workflow step running independently. However, a file which has been updated in a previous completed step may be used as input to multiple steps, provided it is read-only in every step.

Workflow steps which modify a file must produce the modified file as output. Downstream steps which further process the file must use the output of previous steps, and not refer to a common input (this is necessary for both ordering and correctness).

Workflow authors should provide this in the hints section. The intent of this feature is that workflows produce the same results whether or not InplaceUpdateRequirement is supported by the implementation, and this feature is primarily available as an optimization for particular environments.

Users and implementers should be aware that workflows that destructively modify inputs may not be repeatable or reproducible. In particular, enabling this feature implies that WorkReuse should not be enabled.

class string required

Always 'InplaceUpdateRequirement'

Constant: "InplaceUpdateRequirement"
inplaceUpdate boolean required
InputArraySchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#InputArraySchema

items InputRecordSchema | InputEnumSchema | InputArraySchema | InputRecordSchema | InputEnumSchema | InputArraySchema | string[] | string required

Defines the type of the array elements.

type string required

Must be array

Constant: "array"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

label string

A short, human-readable label of this object.

name string

The identifier for this type

InputBinding object

Auto-generated class implementation for https://w3id.org/cwl/cwl#InputBinding

loadContents boolean

Use of loadContents in InputBinding is deprecated. Preserved for v1.0 backwards compatibility. Will be removed in CWL v2.0. Use InputParameter.loadContents instead.

InputEnumSchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#InputEnumSchema

symbols string[] required

Defines the set of valid symbols.

type string required

Must be enum

Constant: "enum"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

label string

A short, human-readable label of this object.

name string

The identifier for this type

InputRecordField object | InputRecordSchema | InputEnumSchema | InputArraySchema | InputRecordSchema | InputEnumSchema | InputArraySchema | string[] | string[]

Auto-generated class implementation for https://w3id.org/cwl/cwl#InputRecordField

InputRecordSchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#InputRecordSchema

type string required

Must be record

Constant: "record"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

fields InputRecordField[] | object

Defines the fields of the record.

label string

A short, human-readable label of this object.

name string

The identifier for this type

LoadListingRequirement object

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

class string required

Always 'LoadListingRequirement'

Constant: "LoadListingRequirement"
loadListing string
Values: "deep_listing" "no_listing" "shallow_listing"
LoadingOptions object
fetcher DefaultFetcher required
idx Dictionary%3Cany%3E required
originalDoc required
rvocab Dictionary%3Cstring%3E required
vocab Dictionary%3Cstring%3E required
container string
copyFrom object
11 nested properties
fetcher DefaultFetcher required
idx Dictionary%3Cany%3E required
originalDoc required
rvocab Dictionary%3Cstring%3E required
vocab Dictionary%3Cstring%3E required
container string
copyFrom object
11 nested properties
fetcher DefaultFetcher required
idx Dictionary%3Cany%3E required
originalDoc required
rvocab Dictionary%3Cstring%3E required
vocab Dictionary%3Cstring%3E required
container string
copyFrom object
fileUri string
noLinkCheck boolean
fileUri string
noLinkCheck boolean
fileUri string
noLinkCheck boolean
MultipleInputFeatureRequirement object

Indicates that the workflow platform must support multiple inbound data links listed in the source field of WorkflowStepInput.

class string required

Always 'MultipleInputFeatureRequirement'

Constant: "MultipleInputFeatureRequirement"
NetworkAccess object

Indicate whether a process requires outgoing IPv4/IPv6 network access. Choice of IPv4 or IPv6 is implementation and site specific, correct tools must support both.

If networkAccess is false or not specified, tools must not assume network access, except for localhost (the loopback device).

If networkAccess is true, the tool must be able to make outgoing connections to network resources. Resources may be on a private subnet or the public Internet. However, implementations and sites may apply their own security policies to restrict what is accessible by the tool.

Enabling network access does not imply a publicly routable IP address or the ability to accept inbound connections.

class string required

Always 'NetworkAccess'

Constant: "NetworkAccess"
networkAccess string | boolean required
Operation object

This record describes an abstract operation. It is a potential step of a workflow that has not yet been bound to a concrete implementation. It specifies an input and output signature, but does not provide enough information to be executed. An implementation (or other tooling) may provide a means of binding an Operation to a concrete process (such as Workflow, CommandLineTool, or ExpressionTool) with a compatible signature.

class string required
Constant: "Operation"
inputs OperationInputParameter[] | object required

Defines the input parameters of the process. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is used to validate the input object. It may also be used to build a user interface for constructing the input object.

When accepting an input object, all input parameters must have a value. If an input parameter is missing from the input object, it must be assigned a value of null (or the value of default for that parameter, if provided) for the purposes of validation and evaluation of expressions.

outputs OperationOutputParameter[] | object required

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

cwlVersion string

CWL document version. Always required at the document root. Not required for a Process embedded inside another Process.

Values: "draft-2" "draft-3" "draft-3.dev1" "draft-3.dev2" "draft-3.dev3" "draft-3.dev4" "draft-3.dev5" "draft-4.dev1" "draft-4.dev2" "draft-4.dev3" "v1.0" "v1.0.dev4" "v1.1" "v1.1.0-dev1" "v1.2" "v1.2.0-dev1" "v1.2.0-dev2" "v1.2.0-dev3" "v1.2.0-dev4" "v1.2.0-dev5"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

hints CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this process. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

id string

The unique identifier for this object.

Only useful for $graph at Process level. Should not be exposed to users in graphical or terminal user interfaces.

intent string[]

An identifier for the type of computational operation, of this Process. Especially useful for Operation, but can also be used for CommandLineTool, Workflow, or ExpressionTool.

If provided, then this must be an IRI of a concept node that represents the type of operation, preferably defined within an ontology.

For example, in the domain of bioinformatics, one can use an IRI from the EDAM Ontology's Operation concept nodes, like Alignment, or Clustering; or a more specific Operation concept like Split read mapping.

label string

A short, human-readable label of this object.

requirements CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this process. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

OperationInputParameter object

Describe an input parameter of an operation.

type InputRecordSchema | InputEnumSchema | InputArraySchema | InputRecordSchema | InputEnumSchema | InputArraySchema | string[] | string required

Specify valid types of data that may be assigned to this parameter.

default

The default value to use for this parameter if the parameter is missing from the input object, or if the value of the parameter in the input object is null. Default values are applied before evaluating expressions (e.g. dependent valueFrom fields).

doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

format string[] | string

Only valid when type: File or is an array of items: File.

This must be one or more IRIs of concept nodes that represents file formats which are allowed as input to this parameter, preferably defined within an ontology. If no ontology is available, file formats may be tested by exact match.

id string

The unique identifier for this object.

label string

A short, human-readable label of this object.

loadContents boolean

Only valid when type: File or is an array of items: File.

If true, the file (or each file in the array) must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use by expressions. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

loadListing string

Only valid when type: Directory or is an array of items: Directory.

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

The order of precedence for loadListing is:

  1. loadListing on an individual parameter
  2. Inherited from LoadListingRequirement
  3. By default: no_listing
Values: "deep_listing" "no_listing" "shallow_listing"

Only valid when type: File or is an array of items: File.

Provides a pattern or expression specifying files or directories that should be included alongside the primary file. Secondary files may be required or optional. When not explicitly specified, secondary files specified for inputs are required and outputs are optional. An implementation must include matching Files and Directories in the secondaryFiles property of the primary file. These Files and Directories must be transferred and staged alongside the primary file. An implementation may fail workflow execution if a required secondary file does not exist.

If the value is an expression, the value of self in the expression must be the primary input or output File object to which this binding applies. The basename, nameroot and nameext fields must be present in self. For CommandLineTool outputs the path field must also be present. The expression must return a filename string relative to the path to the primary File, a File or Directory object with either path or location and basename fields set, or an array consisting of strings or File or Directory objects. It is legal to reference an unchanged File or Directory object taken from input as a secondaryFile. The expression may return "null" in which case there is no secondaryFile from that expression.

To work on non-filename-preserving storage systems, portable tool descriptions should avoid constructing new values from location, but should construct relative references using basename or nameroot instead.

If a value in secondaryFiles is a string that is not an expression, it specifies that the following pattern should be applied to the path of the primary file to yield a filename relative to the primary File:

  1. If string ends with ? character, remove the last ? and mark the resulting secondary file as optional.
  2. If string begins with one or more caret ^ characters, for each caret, remove the last file extension from the path (the last period . and all following characters). If there are no file extensions, the path is unchanged.
  3. Append the remainder of the string to the end of the file path.
streamable boolean

Only valid when type: File or is an array of items: File.

A value of true indicates that the file is read or written sequentially without seeking. An implementation may use this flag to indicate whether it is valid to stream file contents using a named pipe. Default: false.

OperationOutputParameter object

Describe an output parameter of an operation.

type OutputRecordSchema | OutputEnumSchema | OutputArraySchema | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | string[] | string required

Specify valid types of data that may be assigned to this parameter.

doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

format string

Only valid when type: File or is an array of items: File.

This is the file format that will be assigned to the output File object.

id string

The unique identifier for this object.

label string

A short, human-readable label of this object.

Only valid when type: File or is an array of items: File.

Provides a pattern or expression specifying files or directories that should be included alongside the primary file. Secondary files may be required or optional. When not explicitly specified, secondary files specified for inputs are required and outputs are optional. An implementation must include matching Files and Directories in the secondaryFiles property of the primary file. These Files and Directories must be transferred and staged alongside the primary file. An implementation may fail workflow execution if a required secondary file does not exist.

If the value is an expression, the value of self in the expression must be the primary input or output File object to which this binding applies. The basename, nameroot and nameext fields must be present in self. For CommandLineTool outputs the path field must also be present. The expression must return a filename string relative to the path to the primary File, a File or Directory object with either path or location and basename fields set, or an array consisting of strings or File or Directory objects. It is legal to reference an unchanged File or Directory object taken from input as a secondaryFile. The expression may return "null" in which case there is no secondaryFile from that expression.

To work on non-filename-preserving storage systems, portable tool descriptions should avoid constructing new values from location, but should construct relative references using basename or nameroot instead.

If a value in secondaryFiles is a string that is not an expression, it specifies that the following pattern should be applied to the path of the primary file to yield a filename relative to the primary File:

  1. If string ends with ? character, remove the last ? and mark the resulting secondary file as optional.
  2. If string begins with one or more caret ^ characters, for each caret, remove the last file extension from the path (the last period . and all following characters). If there are no file extensions, the path is unchanged.
  3. Append the remainder of the string to the end of the file path.
streamable boolean

Only valid when type: File or is an array of items: File.

A value of true indicates that the file is read or written sequentially without seeking. An implementation may use this flag to indicate whether it is valid to stream file contents using a named pipe. Default: false.

OutputArraySchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#OutputArraySchema

items OutputRecordSchema | OutputEnumSchema | OutputArraySchema | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | string[] | string required

Defines the type of the array elements.

type string required

Must be array

Constant: "array"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

label string

A short, human-readable label of this object.

name string

The identifier for this type

OutputEnumSchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#OutputEnumSchema

symbols string[] required

Defines the set of valid symbols.

type string required

Must be enum

Constant: "enum"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

label string

A short, human-readable label of this object.

name string

The identifier for this type

OutputRecordField object | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | string[] | string[]

Auto-generated class implementation for https://w3id.org/cwl/cwl#OutputRecordField

OutputRecordSchema object

Auto-generated class implementation for https://w3id.org/cwl/cwl#OutputRecordSchema

type string required

Must be record

Constant: "record"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

fields OutputRecordField[] | object

Defines the fields of the record.

label string

A short, human-readable label of this object.

name string

The identifier for this type

ResourceRequirement object

Specify basic hardware resource requirements.

"min" is the minimum amount of a resource that must be reserved to schedule a job. If "min" cannot be satisfied, the job should not be run.

"max" is the maximum amount of a resource that the job shall be allocated. If a node has sufficient resources, multiple jobs may be scheduled on a single node provided each job's "max" resource requirements are met. If a job attempts to exceed its resource allocation, an implementation may deny additional resources, which may result in job failure.

If both "min" and "max" are specified, an implementation may choose to allocate any amount between "min" and "max", with the actual allocation provided in the runtime object.

If "min" is specified but "max" is not, then "max" == "min" If "max" is specified by "min" is not, then "min" == "max".

It is an error if max < min.

It is an error if the value of any of these fields is negative.

If neither "min" nor "max" is specified for a resource, use the default values below.

class string required

Always 'ResourceRequirement'

Constant: "ResourceRequirement"
coresMax string | number

Maximum reserved number of CPU cores.

See coresMin for discussion about fractional CPU requests.

coresMin string | number

Minimum reserved number of CPU cores (default is 1).

May be a fractional value to indicate to a scheduling algorithm that one core can be allocated to multiple jobs. For example, a value of 0.25 indicates that up to 4 jobs may run in parallel on 1 core. A value of 1.25 means that up to 3 jobs can run on a 4 core system (4/1.25 ≈ 3).

Processes can only share a core allocation if the sum of each of their ramMax, tmpdirMax, and outdirMax requests also do not exceed the capacity of the node.

Processes sharing a core must have the same level of isolation (typically a container or VM) that they would normally have.

The reported number of CPU cores reserved for the process, which is available to expressions on the CommandLineTool as runtime.cores, must be a non-zero integer, and may be calculated by rounding up the cores request to the next whole number.

Scheduling systems may allocate fractional CPU resources by setting quotas or scheduling weights. Scheduling systems that do not support fractional CPUs may round up the request to the next whole number.

outdirMax string | number

Maximum reserved filesystem based storage for the designated output directory, in mebibytes (2**20)

See outdirMin for discussion about fractional storage requests.

outdirMin string | number

Minimum reserved filesystem based storage for the designated output directory, in mebibytes (2**20) (default is 1024)

May be a fractional value. If so, the actual storage request must be rounded up to the next whole number. The reported amount of storage reserved for the process, which is available to expressions on the CommandLineTool as runtime.outdirSize, must be a non-zero integer.

ramMax string | number

Maximum reserved RAM in mebibytes (2**20)

See ramMin for discussion about fractional RAM requests.

ramMin string | number

Minimum reserved RAM in mebibytes (2**20) (default is 256)

May be a fractional value. If so, the actual RAM request must be rounded up to the next whole number. The reported amount of RAM reserved for the process, which is available to expressions on the CommandLineTool as runtime.ram, must be a non-zero integer.

tmpdirMax string | number

Maximum reserved filesystem based storage for the designated temporary directory, in mebibytes (2**20)

See tmpdirMin for discussion about fractional storage requests.

tmpdirMin string | number

Minimum reserved filesystem based storage for the designated temporary directory, in mebibytes (2**20) (default is 1024)

May be a fractional value. If so, the actual storage request must be rounded up to the next whole number. The reported amount of storage reserved for the process, which is available to expressions on the CommandLineTool as runtime.tmpdirSize, must be a non-zero integer.

ScatterFeatureRequirement object

Indicates that the workflow platform must support the scatter and scatterMethod fields of WorkflowStep.

class string required

Always 'ScatterFeatureRequirement'

Constant: "ScatterFeatureRequirement"
SchemaDefRequirement object

This field consists of an array of type definitions which must be used when interpreting the inputs and outputs fields. When a type field contains a IRI, the implementation must check if the type is defined in schemaDefs and use that definition. If the type is not found in schemaDefs, it is an error. The entries in schemaDefs must be processed in the order listed such that later schema definitions may refer to earlier schema definitions.

  • Type definitions are allowed for enum and record types only.
  • Type definitions may be shared by defining them in a file and then $include-ing them in the types field.
  • A file can contain a list of type definitions
class string required

Always 'SchemaDefRequirement'

Constant: "SchemaDefRequirement"
types CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | CWLImportManual | CWLIncludeManual[] required

The list of type definitions.

SecondaryFileSchema object | string

Secondary files are specified using the following micro-DSL for secondary files:

  • If the value is a string, it is transformed to an object with two fields pattern and required
  • By default, the value of required is null (this indicates default behavior, which may be based on the context)
  • If the value ends with a question mark ? the question mark is stripped off and the value of the field required is set to False
  • The remaining value is assigned to the field pattern

For implementation details and examples, please see this section in the Schema Salad specification.

ShellCommandRequirement object

Modify the behavior of CommandLineTool to generate a single string containing a shell command line. Each item in the arguments list must be joined into a string separated by single spaces and quoted to prevent interpretation by the shell, unless CommandLineBinding for that argument contains shellQuote: false. If shellQuote: false is specified, the argument is joined into the command string without quoting, which allows the use of shell metacharacters such as | for pipes.

class string required

Always 'ShellCommandRequirement'

Constant: "ShellCommandRequirement"
SoftwarePackage object

Auto-generated class implementation for https://w3id.org/cwl/cwl#SoftwarePackage

package string required

The name of the software to be made available. If the name is common, inconsistent, or otherwise ambiguous it should be combined with one or more identifiers in the specs field.

specs string[]

One or more IRIs identifying resources for installing or enabling the software named in the package field. Implementations may provide resolvers which map these software identifier IRIs to some configuration action; or they can use only the name from the package field on a best effort basis.

For example, the IRI https://packages.debian.org/bowtie could be resolved with apt-get install bowtie. The IRI https://anaconda.org/bioconda/bowtie could be resolved with conda install -c bioconda bowtie.

IRIs can also be system independent and used to map to a specific software installation or selection mechanism. Using RRID as an example: https://identifiers.org/rrid/RRID:SCR_005476 could be fulfilled using the above-mentioned Debian or bioconda package, a local installation managed by Environment Modules, or any other mechanism the platform chooses. IRIs can also be from identifier sources that are discipline specific yet still system independent. As an example, the equivalent ELIXIR Tools and Data Service Registry IRI to the previous RRID example is https://bio.tools/tool/bowtie2/version/2.2.8. If supported by a given registry, implementations are encouraged to query these system independent software identifier IRIs directly for links to packaging systems.

A site specific IRI can be listed as well. For example, an academic computing cluster using Environment Modules could list the IRI <https://hpc.example.edu/modules/bowtie-tbb/1.22> to indicate that module load bowtie-tbb/1.1.2 should be executed to make available bowtie version 1.1.2 compiled with the TBB library prior to running the accompanying Workflow or CommandLineTool. Note that the example IRI is specific to a particular institution and computing environment as the Environment Modules system does not have a common namespace or standardized naming convention.

This last example is the least portable and should only be used if mechanisms based off of the package field or more generic IRIs are unavailable or unsuitable. While harmless to other sites, site specific software IRIs should be left out of shared CWL descriptions to avoid clutter.

version string[]

The (optional) versions of the software that are known to be compatible.

SoftwareRequirement object

A list of software packages that should be configured in the environment of the defined process.

class string required

Always 'SoftwareRequirement'

Constant: "SoftwareRequirement"
packages SoftwarePackage | CWLImportManual | CWLIncludeManual[] required

The list of software to be configured.

StepInputExpressionRequirement object

Indicate that the workflow platform must support the valueFrom field of WorkflowStepInput.

class string required

Always 'StepInputExpressionRequirement'

Constant: "StepInputExpressionRequirement"
SubworkflowFeatureRequirement object

Indicates that the workflow platform must support nested workflows in the run field of WorkflowStep.

class string required

Always 'SubworkflowFeatureRequirement'

Constant: "SubworkflowFeatureRequirement"
T object
ToolTimeLimit object

Set an upper limit on the execution time of a CommandLineTool. A CommandLineTool whose execution duration exceeds the time limit may be preemptively terminated and considered failed. May also be used by batch systems to make scheduling decisions. The execution duration excludes external operations, such as staging of files, pulling a docker image etc, and only counts wall-time for the execution of the command line itself.

class string required

Always 'ToolTimeLimit'

Constant: "ToolTimeLimit"
timelimit string | number required

The time limit, in seconds. A time limit of zero means no time limit. Negative time limits are an error.

WorkReuse object

For implementations that support reusing output from past work (on the assumption that same code and same input produce same results), control whether to enable or disable the reuse behavior for a particular tool or step (to accommodate situations where that assumption is incorrect). A reused step is not executed but instead returns the same output as the original execution.

If WorkReuse is not specified, correct tools should assume it is enabled by default.

class string required

Always 'WorkReuse'

Constant: "WorkReuse"
enableReuse string | boolean required
Workflow object

A workflow describes a set of steps and the dependencies between those steps. When a step produces output that will be consumed by a second step, the first step is a dependency of the second step.

When there is a dependency, the workflow engine must execute the preceding step and wait for it to successfully produce output before executing the dependent step. If two steps are defined in the workflow graph that are not directly or indirectly dependent, these steps are independent, and may execute in any order or execute concurrently. A workflow is complete when all steps have been executed.

Dependencies between parameters are expressed using the source field on workflow step input parameters and outputSource field on workflow output parameters.

The source field on each workflow step input parameter expresses the data links that contribute to the value of the step input parameter (the "sink"). A workflow step can only begin execution when every data link connected to a step has been fulfilled.

The outputSource field on each workflow step input parameter expresses the data links that contribute to the value of the workflow output parameter (the "sink"). Workflow execution cannot complete successfully until every data link connected to an output parameter has been fulfilled.

Workflow success and failure

A completed step must result in one of success, temporaryFailure or permanentFailure states. An implementation may choose to retry a step execution which resulted in temporaryFailure. An implementation may choose to either continue running other steps of a workflow, or terminate immediately upon permanentFailure.

  • If any step of a workflow execution results in permanentFailure, then the workflow status is permanentFailure.

  • If one or more steps result in temporaryFailure and all other steps complete success or are not executed, then the workflow status is temporaryFailure.

  • If all workflow steps are executed and complete with success, then the workflow status is success.

Extensions

ScatterFeatureRequirement and SubworkflowFeatureRequirement are available as standard extensions to core workflow semantics.

class string required
Constant: "Workflow"
inputs WorkflowInputParameter[] | object required

Defines the input parameters of the process. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is used to validate the input object. It may also be used to build a user interface for constructing the input object.

When accepting an input object, all input parameters must have a value. If an input parameter is missing from the input object, it must be assigned a value of null (or the value of default for that parameter, if provided) for the purposes of validation and evaluation of expressions.

outputs WorkflowOutputParameter[] | object required

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

steps WorkflowStep[] | object required

The individual steps that make up the workflow. Each step is executed when all of its input data links are fulfilled. An implementation may choose to execute the steps in a different order than listed and/or execute steps concurrently, provided that dependencies between steps are met.

cwlVersion string

CWL document version. Always required at the document root. Not required for a Process embedded inside another Process.

Values: "draft-2" "draft-3" "draft-3.dev1" "draft-3.dev2" "draft-3.dev3" "draft-3.dev4" "draft-3.dev5" "draft-4.dev1" "draft-4.dev2" "draft-4.dev3" "v1.0" "v1.0.dev4" "v1.1" "v1.1.0-dev1" "v1.2" "v1.2.0-dev1" "v1.2.0-dev2" "v1.2.0-dev3" "v1.2.0-dev4" "v1.2.0-dev5"
doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

hints CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this process. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

id string

The unique identifier for this object.

Only useful for $graph at Process level. Should not be exposed to users in graphical or terminal user interfaces.

intent string[]

An identifier for the type of computational operation, of this Process. Especially useful for Operation, but can also be used for CommandLineTool, Workflow, or ExpressionTool.

If provided, then this must be an IRI of a concept node that represents the type of operation, preferably defined within an ontology.

For example, in the domain of bioinformatics, one can use an IRI from the EDAM Ontology's Operation concept nodes, like Alignment, or Clustering; or a more specific Operation concept like Split read mapping.

label string

A short, human-readable label of this object.

requirements CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this process. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

WorkflowInputParameter object

Auto-generated class implementation for https://w3id.org/cwl/cwl#WorkflowInputParameter

type InputRecordSchema | InputEnumSchema | InputArraySchema | InputRecordSchema | InputEnumSchema | InputArraySchema | string[] | string required

Specify valid types of data that may be assigned to this parameter.

default

The default value to use for this parameter if the parameter is missing from the input object, or if the value of the parameter in the input object is null. Default values are applied before evaluating expressions (e.g. dependent valueFrom fields).

doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

format string[] | string

Only valid when type: File or is an array of items: File.

This must be one or more IRIs of concept nodes that represents file formats which are allowed as input to this parameter, preferably defined within an ontology. If no ontology is available, file formats may be tested by exact match.

id string

The unique identifier for this object.

inputBinding object

Auto-generated class implementation for https://w3id.org/cwl/cwl#InputBinding

1 nested properties
loadContents boolean

Use of loadContents in InputBinding is deprecated. Preserved for v1.0 backwards compatibility. Will be removed in CWL v2.0. Use InputParameter.loadContents instead.

label string

A short, human-readable label of this object.

loadContents boolean

Only valid when type: File or is an array of items: File.

If true, the file (or each file in the array) must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use by expressions. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

loadListing string

Only valid when type: Directory or is an array of items: Directory.

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

The order of precedence for loadListing is:

  1. loadListing on an individual parameter
  2. Inherited from LoadListingRequirement
  3. By default: no_listing
Values: "deep_listing" "no_listing" "shallow_listing"

Only valid when type: File or is an array of items: File.

Provides a pattern or expression specifying files or directories that should be included alongside the primary file. Secondary files may be required or optional. When not explicitly specified, secondary files specified for inputs are required and outputs are optional. An implementation must include matching Files and Directories in the secondaryFiles property of the primary file. These Files and Directories must be transferred and staged alongside the primary file. An implementation may fail workflow execution if a required secondary file does not exist.

If the value is an expression, the value of self in the expression must be the primary input or output File object to which this binding applies. The basename, nameroot and nameext fields must be present in self. For CommandLineTool outputs the path field must also be present. The expression must return a filename string relative to the path to the primary File, a File or Directory object with either path or location and basename fields set, or an array consisting of strings or File or Directory objects. It is legal to reference an unchanged File or Directory object taken from input as a secondaryFile. The expression may return "null" in which case there is no secondaryFile from that expression.

To work on non-filename-preserving storage systems, portable tool descriptions should avoid constructing new values from location, but should construct relative references using basename or nameroot instead.

If a value in secondaryFiles is a string that is not an expression, it specifies that the following pattern should be applied to the path of the primary file to yield a filename relative to the primary File:

  1. If string ends with ? character, remove the last ? and mark the resulting secondary file as optional.
  2. If string begins with one or more caret ^ characters, for each caret, remove the last file extension from the path (the last period . and all following characters). If there are no file extensions, the path is unchanged.
  3. Append the remainder of the string to the end of the file path.
streamable boolean

Only valid when type: File or is an array of items: File.

A value of true indicates that the file is read or written sequentially without seeking. An implementation may use this flag to indicate whether it is valid to stream file contents using a named pipe. Default: false.

WorkflowOutputParameter object

Describe an output parameter of a workflow. The parameter must be connected to one or more parameters defined in the workflow that will provide the value of the output parameter. It is legal to connect a WorkflowInputParameter to a WorkflowOutputParameter.

See WorkflowStepInput for discussion of linkMerge and pickValue.

type OutputRecordSchema | OutputEnumSchema | OutputArraySchema | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | string[] | string required

Specify valid types of data that may be assigned to this parameter.

doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

format string

Only valid when type: File or is an array of items: File.

This is the file format that will be assigned to the output File object.

id string

The unique identifier for this object.

label string

A short, human-readable label of this object.

linkMerge string

The method to use to merge multiple sources into a single array. If not specified, the default method is "merge_nested".

Values: "merge_flattened" "merge_nested"
outputSource string[] | string

Specifies one or more names of an output from a workflow step (in the form step_name/output_name with a / separator`), or a workflow input name, that supply their value(s) to the output parameter. the output parameter. It is valid to reference workflow level inputs here.

pickValue string

The method to use to choose non-null elements among multiple sources.

Values: "all_non_null" "first_non_null" "the_only_non_null"

Only valid when type: File or is an array of items: File.

Provides a pattern or expression specifying files or directories that should be included alongside the primary file. Secondary files may be required or optional. When not explicitly specified, secondary files specified for inputs are required and outputs are optional. An implementation must include matching Files and Directories in the secondaryFiles property of the primary file. These Files and Directories must be transferred and staged alongside the primary file. An implementation may fail workflow execution if a required secondary file does not exist.

If the value is an expression, the value of self in the expression must be the primary input or output File object to which this binding applies. The basename, nameroot and nameext fields must be present in self. For CommandLineTool outputs the path field must also be present. The expression must return a filename string relative to the path to the primary File, a File or Directory object with either path or location and basename fields set, or an array consisting of strings or File or Directory objects. It is legal to reference an unchanged File or Directory object taken from input as a secondaryFile. The expression may return "null" in which case there is no secondaryFile from that expression.

To work on non-filename-preserving storage systems, portable tool descriptions should avoid constructing new values from location, but should construct relative references using basename or nameroot instead.

If a value in secondaryFiles is a string that is not an expression, it specifies that the following pattern should be applied to the path of the primary file to yield a filename relative to the primary File:

  1. If string ends with ? character, remove the last ? and mark the resulting secondary file as optional.
  2. If string begins with one or more caret ^ characters, for each caret, remove the last file extension from the path (the last period . and all following characters). If there are no file extensions, the path is unchanged.
  3. Append the remainder of the string to the end of the file path.
streamable boolean

Only valid when type: File or is an array of items: File.

A value of true indicates that the file is read or written sequentially without seeking. An implementation may use this flag to indicate whether it is valid to stream file contents using a named pipe. Default: false.

WorkflowStep object

A workflow step is an executable element of a workflow. It specifies the underlying process implementation (such as CommandLineTool or another Workflow) in the run field and connects the input and output parameters of the underlying process to workflow parameters.

Scatter/gather

To use scatter/gather, ScatterFeatureRequirement must be specified in the workflow or workflow step requirements.

A "scatter" operation specifies that the associated workflow step or subworkflow should execute separately over a list of input elements. Each job making up a scatter operation is independent and may be executed concurrently.

The scatter field specifies one or more input parameters which will be scattered. An input parameter may be listed more than once. The declared type of each input parameter implicitly becomes an array of items of the input parameter type. If a parameter is listed more than once, it becomes a nested array. As a result, upstream parameters which are connected to scattered parameters must be arrays.

All output parameter types are also implicitly wrapped in arrays. Each job in the scatter results in an entry in the output array.

If any scattered parameter runtime value is an empty array, all outputs are set to empty arrays and no work is done for the step, according to applicable scattering rules.

If scatter declares more than one input parameter, scatterMethod describes how to decompose the input into a discrete set of jobs.

  • dotproduct specifies that each of the input arrays are aligned and one element taken from each array to construct each job. It is an error if all input arrays are not the same length.

  • nested_crossproduct specifies the Cartesian product of the inputs, producing a job for every combination of the scattered inputs. The output must be nested arrays for each level of scattering, in the order that the input arrays are listed in the scatter field.

  • flat_crossproduct specifies the Cartesian product of the inputs, producing a job for every combination of the scattered inputs. The output arrays must be flattened to a single level, but otherwise listed in the order that the input arrays are listed in the scatter field.

Conditional execution (Optional)

Conditional execution makes execution of a step conditional on an expression. A step that is not executed is "skipped". A skipped step produces null for all output parameters.

The condition is evaluated after scatter, using the input object of each individual scatter job. This means over a set of scatter jobs, some may be executed and some may be skipped. When the results are gathered, skipped steps must be null in the output arrays.

The when field controls conditional execution. This is an expression that must be evaluated with inputs bound to the step input object (or individual scatter job), and returns a boolean value. It is an error if this expression returns a value other than true or false.

Conditionals in CWL are an optional feature and are not required to be implemented by all consumers of CWL documents. An implementation that does not support conditionals must return a fatal error when attempting to execute a workflow that uses conditional constructs the implementation does not support.

Subworkflows

To specify a nested workflow as part of a workflow step, SubworkflowFeatureRequirement must be specified in the workflow or workflow step requirements.

It is a fatal error if a workflow directly or indirectly invokes itself as a subworkflow (recursive workflows are not allowed).

in WorkflowStepInput[] | object required

Defines the input parameters of the workflow step. The process is ready to run when all required input parameters are associated with concrete values. Input parameters include a schema for each parameter which is used to validate the input object. It may also be used build a user interface for constructing the input object.

out WorkflowStepOutput | string[] required

Defines the parameters representing the output of the process. May be used to generate and/or validate the output object.

run CommandLineTool | ExpressionTool | Workflow | Operation | string required

Specifies the process to run. If run is a string, it must be an absolute IRI or a relative path from the primary document.

doc string[] | string

A documentation string for this object, or an array of strings which should be concatenated.

hints array

Declares hints applying to either the runtime environment or the workflow engine that may be helpful in executing this workflow step. It is not an error if an implementation cannot satisfy all hints, however the implementation may report a warning.

id string

The unique identifier for this object.

label string

A short, human-readable label of this object.

requirements CWLImportManual | CWLIncludeManual | InlineJavascriptRequirement | SchemaDefRequirement | LoadListingRequirement | DockerRequirement | SoftwareRequirement | InitialWorkDirRequirement | EnvVarRequirement | ShellCommandRequirement | ResourceRequirement | WorkReuse | NetworkAccess | InplaceUpdateRequirement | ToolTimeLimit | SubworkflowFeatureRequirement | ScatterFeatureRequirement | MultipleInputFeatureRequirement | StepInputExpressionRequirement[] | object

Declares requirements that apply to either the runtime environment or the workflow engine that must be met in order to execute this workflow step. If an implementation cannot satisfy all requirements, or a requirement is listed which is not recognized by the implementation, it is a fatal error and the implementation must not attempt to run the process, unless overridden at user option.

scatter string[] | string
scatterMethod string

Required if scatter is an array of more than one element.

Values: "dotproduct" "flat_crossproduct" "nested_crossproduct"
when string

If defined, only run the step when the expression evaluates to true. If false the step is skipped. A skipped step produces a null on each output.

WorkflowStepInput object

The input of a workflow step connects an upstream parameter (from the workflow inputs, or the outputs of other workflows steps) with the input parameters of the process specified by the run field. Only input parameters declared by the target process will be passed through at runtime to the process though additional parameters may be specified (for use within valueFrom expressions for instance) - unconnected or unused parameters do not represent an error condition.

Input object

A WorkflowStepInput object must contain an id field in the form #fieldname or #prefix/fieldname. When the id field contains a slash / the field name consists of the characters following the final slash (the prefix portion may contain one or more slashes to indicate scope). This defines a field of the workflow step input object with the value of the source parameter(s).

Merging multiple inbound data links

To merge multiple inbound data links, MultipleInputFeatureRequirement must be specified in the workflow or workflow step requirements.

If the sink parameter is an array, or named in a workflow scatter operation, there may be multiple inbound data links listed in the source field. The values from the input links are merged depending on the method specified in the linkMerge field. If both linkMerge and pickValue are null or not specified, and there is more than one element in the source array, the default method is "merge_nested".

If both linkMerge and pickValue are null or not specified, and there is only a single element in the source, then the input parameter takes the scalar value from the single input link (it is not wrapped in a single-list).

  • merge_nested

    The input must be an array consisting of exactly one entry for each input link. If "merge_nested" is specified with a single link, the value from the link must be wrapped in a single-item list.

  • merge_flattened

    1. The source and sink parameters must be compatible types, or the source type must be compatible with single element from the "items" type of the destination array parameter.
    2. Source parameters which are arrays are concatenated. Source parameters which are single element types are appended as single elements.

Picking non-null values among inbound data links

If present, pickValue specifies how to pick non-null values among inbound data links.

pickValue is evaluated

  1. Once all source values from upstream step or parameters are available.
  2. After linkMerge.
  3. Before scatter or valueFrom.

This is specifically intended to be useful in combination with conditional execution, where several upstream steps may be connected to a single input (source is a list), and skipped steps produce null values.

Static type checkers should check for type consistency after inferring what the type will be after pickValue is applied, just as they do currently for linkMerge.

  • first_non_null

    For the first level of a list input, pick the first non-null element. The result is a scalar. It is an error if there is no non-null element. Examples:

    • [null, x, null, y] -> x
    • [null, [null], null, y] -> [null]
    • [null, null, null] -> Runtime Error

    Intended use case: If-else pattern where the value comes either from a conditional step or from a default or fallback value. The conditional step(s) should be placed first in the list.

  • the_only_non_null

    For the first level of a list input, pick the single non-null element. The result is a scalar. It is an error if there is more than one non-null element. Examples:

    • [null, x, null] -> x
    • [null, x, null, y] -> Runtime Error
    • [null, [null], null] -> [null]
    • [null, null, null] -> Runtime Error

    Intended use case: Switch type patterns where developer considers more than one active code path as a workflow error (possibly indicating an error in writing when condition expressions).

  • all_non_null

    For the first level of a list input, pick all non-null values. The result is a list, which may be empty. Examples:

    • [null, x, null] -> [x]
    • [x, null, y] -> [x, y]
    • [null, [x], [null]] -> [[x], [null]]
    • [null, null, null] -> []

    Intended use case: It is valid to have more than one source, but sources are conditional, so null sources (from skipped steps) should be filtered out.

default

The default value for this parameter to use if either there is no source field, or the value produced by the source is null. The default must be applied prior to scattering or evaluating valueFrom.

id string

The unique identifier for this object.

label string

A short, human-readable label of this object.

linkMerge string

The method to use to merge multiple inbound links into a single array. If not specified, the default method is "merge_nested".

Values: "merge_flattened" "merge_nested"
loadContents boolean

Only valid when type: File or is an array of items: File.

If true, the file (or each file in the array) must be a UTF-8 text file 64 KiB or smaller, and the implementation must read the entire contents of the file (or file array) and place it in the contents field of the File object for use by expressions. If the size of the file is greater than 64 KiB, the implementation must raise a fatal error.

loadListing string

Only valid when type: Directory or is an array of items: Directory.

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

The order of precedence for loadListing is:

  1. loadListing on an individual parameter
  2. Inherited from LoadListingRequirement
  3. By default: no_listing
Values: "deep_listing" "no_listing" "shallow_listing"
pickValue string

The method to use to choose non-null elements among multiple sources.

Values: "all_non_null" "first_non_null" "the_only_non_null"
source string[] | string

Specifies one or more workflow parameters that will provide input to the underlying step parameter.

valueFrom string

To use valueFrom, StepInputExpressionRequirement must be specified in the workflow or workflow step requirements.

If valueFrom is a constant string value, use this as the value for this input parameter.

If valueFrom is a parameter reference or expression, it must be evaluated to yield the actual value to be assigned to the input field.

The self value in the parameter reference or expression must be

  1. null if there is no source field
  2. the value of the parameter(s) specified in the source field when this workflow input parameter is not specified in this workflow step's scatter field.
  3. an element of the parameter specified in the source field when this workflow input parameter is specified in this workflow step's scatter field.

The value of inputs in the parameter reference or expression must be the input object to the workflow step after assigning the source values, applying default, and then scattering. The order of evaluating valueFrom among step input parameters is undefined and the result of evaluating valueFrom on a parameter must not be visible to evaluation of valueFrom on other parameters.

WorkflowStepOutput object

Associate an output parameter of the underlying process with a workflow parameter. The workflow parameter (given in the id field) be may be used as a source to connect with input parameters of other workflow steps, or with an output parameter of the process.

A unique identifier for this workflow output parameter. This is the identifier to use in the source field of WorkflowStepInput to connect the output value to downstream parameters.

id string

The unique identifier for this object.

CWLImportManual object

Represents an '$import' directive that should point toward another compatible CWL file to import where specified. The contents of the imported file should be relevant contextually where it is being imported

$import string required
CWLIncludeManual object

Represents an '$include' directive that should point toward another compatible CWL file to import where specified. The contents of the imported file should be relevant contextually where it is being imported

$include string required
CWLDocumentMetadata object

Metadata for a CWL document

$namespaces object

The namespaces used in the document

$schemas string[]

The schemas used in the document

CommandInputRecordFieldMap object | CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | string[] | string[] | string

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandInputRecordField

InputRecordFieldMap object | InputRecordSchema | InputEnumSchema | InputArraySchema | InputRecordSchema | InputEnumSchema | InputArraySchema | string[] | string[] | string

Auto-generated class implementation for https://w3id.org/cwl/cwl#InputRecordField

CommandOutputRecordFieldMap object | CommandOutputArraySchema | CommandOutputRecordSchema | CommandOutputEnumSchema | CommandOutputArraySchema | CommandOutputRecordSchema | CommandOutputEnumSchema | string[] | string[] | string

Auto-generated class implementation for https://w3id.org/cwl/cwl#CommandOutputRecordField

OutputRecordFieldMap object | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | OutputRecordSchema | OutputEnumSchema | OutputArraySchema | string[] | string[] | string

Auto-generated class implementation for https://w3id.org/cwl/cwl#OutputRecordField

InlineJavascriptRequirementMap object

Indicates that the workflow platform must support inline Javascript expressions. If this requirement is not present, the workflow platform must not perform expression interpolation.

expressionLib string | CWLImportManual | CWLIncludeManual[]

Additional code fragments that will also be inserted before executing the expression code. Allows for function definitions that may be called from CWL expressions.

SchemaDefRequirementMap object

This field consists of an array of type definitions which must be used when interpreting the inputs and outputs fields. When a type field contains a IRI, the implementation must check if the type is defined in schemaDefs and use that definition. If the type is not found in schemaDefs, it is an error. The entries in schemaDefs must be processed in the order listed such that later schema definitions may refer to earlier schema definitions.

  • Type definitions are allowed for enum and record types only.
  • Type definitions may be shared by defining them in a file and then $include-ing them in the types field.
  • A file can contain a list of type definitions
types CommandInputArraySchema | CommandInputRecordSchema | CommandInputEnumSchema | CWLImportManual | CWLIncludeManual[] required

The list of type definitions.

LoadListingRequirementMap object

Specify the desired behavior for loading the listing field of a Directory object for use by expressions.

loadListing string
Values: "deep_listing" "no_listing" "shallow_listing"
DockerRequirementMap object

Indicates that a workflow component should be run in a Docker or Docker-compatible (such as Singularity and udocker) container environment and specifies how to fetch or build the image.

If a CommandLineTool lists DockerRequirement under hints (or requirements), it may (or must) be run in the specified Docker container.

The platform must first acquire or install the correct Docker image as specified by dockerPull, dockerImport, dockerLoad or dockerFile.

The platform must execute the tool in the container using docker run with the appropriate Docker image and tool command line.

The workflow platform may provide input files and the designated output directory through the use of volume bind mounts. The platform should rewrite file paths in the input object to correspond to the Docker bind mounted locations. That is, the platform should rewrite values in the parameter context such as runtime.outdir, runtime.tmpdir and others to be valid paths within the container. The platform must ensure that runtime.outdir and runtime.tmpdir are distinct directories.

When running a tool contained in Docker, the workflow platform must not assume anything about the contents of the Docker container, such as the presence or absence of specific software, except to assume that the generated command line represents a valid command within the runtime environment of the container.

A container image may specify an ENTRYPOINT and/or CMD. Command line arguments will be appended after all elements of ENTRYPOINT, and will override all elements specified using CMD (in other words, CMD is only used when the CommandLineTool definition produces an empty command line).

Use of implicit ENTRYPOINT or CMD are discouraged due to reproducibility concerns of the implicit hidden execution point (For further discussion, see [https://doi.org/10.12688/f1000research.15140.1](https://doi.org/10.12688/f1000research.15140.1)). Portable CommandLineTool wrappers in which use of a container is optional must not rely on ENTRYPOINT or CMD. CommandLineTools which do rely on ENTRYPOINT or CMD must list DockerRequirement in the requirements section.

Interaction with other requirements

If EnvVarRequirement is specified alongside a DockerRequirement, the environment variables must be provided to Docker using --env or --env-file and interact with the container's preexisting environment as defined by Docker.

dockerFile string

Supply the contents of a Dockerfile which will be built using docker build.

dockerImageId string

The image id that will be used for docker run. May be a human-readable image name or the image identifier hash. May be skipped if dockerPull is specified, in which case the dockerPull image id must be used.

dockerImport string

Provide HTTP URL to download and gunzip a Docker images using `docker import.

dockerLoad string

Specify an HTTP URL from which to download a Docker image using docker load.

dockerOutputDirectory string

Set the designated output directory to a specific location inside the Docker container.

dockerPull string

Specify a Docker image to retrieve using docker pull. Can contain the immutable digest to ensure an exact container is used: dockerPull: ubuntu@sha256:45b23dee08af5e43a7fea6c4cf9c25ccf269ee113168c19722f87876677c5cb2

SoftwareRequirementMap object

A list of software packages that should be configured in the environment of the defined process.

packages SoftwarePackage | CWLImportManual | CWLIncludeManual[] required

The list of software to be configured.

InitialWorkDirRequirementMap object

Define a list of files and subdirectories that must be staged by the workflow platform prior to executing the command line tool. Normally files are staged within the designated output directory. However, when running inside containers, files may be staged at arbitrary locations, see discussion for Dirent.entryname. Together with DockerRequirement.dockerOutputDirectory it is possible to control the locations of both input and output files when running in containers.

listing Directory | File | Directory | File | CWLImportManual | CWLIncludeManual[] | Dirent | string | CWLImportManual | CWLIncludeManual[] | string

The list of files or subdirectories that must be staged prior to executing the command line tool.

Return type of each expression must validate as ["null", File, Directory, Dirent, {type: array, items: [File, Directory]}].

Each File or Directory that is returned by an Expression must be added to the designated output directory prior to executing the tool.

Each Dirent record that is listed or returned by an expression specifies a file to be created or staged in the designated output directory prior to executing the tool.

Expressions may return null, in which case they have no effect.

Files or Directories which are listed in the input parameters and appear in the InitialWorkDirRequirement listing must have their path set to their staged location. If the same File or Directory appears more than once in the InitialWorkDirRequirement listing, the implementation must choose exactly one value for path; how this value is chosen is undefined.

EnvVarRequirementMap object

Define a list of environment variables which will be set in the execution environment of the tool. See EnvironmentDef for details.

envDef EnvironmentDef | CWLImportManual | CWLIncludeManual[] required

The list of environment variables.

ShellCommandRequirementMap object

Modify the behavior of CommandLineTool to generate a single string containing a shell command line. Each item in the arguments list must be joined into a string separated by single spaces and quoted to prevent interpretation by the shell, unless CommandLineBinding for that argument contains shellQuote: false. If shellQuote: false is specified, the argument is joined into the command string without quoting, which allows the use of shell metacharacters such as | for pipes.

ResourceRequirementMap object

Specify basic hardware resource requirements.

"min" is the minimum amount of a resource that must be reserved to schedule a job. If "min" cannot be satisfied, the job should not be run.

"max" is the maximum amount of a resource that the job shall be allocated. If a node has sufficient resources, multiple jobs may be scheduled on a single node provided each job's "max" resource requirements are met. If a job attempts to exceed its resource allocation, an implementation may deny additional resources, which may result in job failure.

If both "min" and "max" are specified, an implementation may choose to allocate any amount between "min" and "max", with the actual allocation provided in the runtime object.

If "min" is specified but "max" is not, then "max" == "min" If "max" is specified by "min" is not, then "min" == "max".

It is an error if max < min.

It is an error if the value of any of these fields is negative.

If neither "min" nor "max" is specified for a resource, use the default values below.

coresMax string | number

Maximum reserved number of CPU cores.

See coresMin for discussion about fractional CPU requests.

coresMin string | number

Minimum reserved number of CPU cores (default is 1).

May be a fractional value to indicate to a scheduling algorithm that one core can be allocated to multiple jobs. For example, a value of 0.25 indicates that up to 4 jobs may run in parallel on 1 core. A value of 1.25 means that up to 3 jobs can run on a 4 core system (4/1.25 ≈ 3).

Processes can only share a core allocation if the sum of each of their ramMax, tmpdirMax, and outdirMax requests also do not exceed the capacity of the node.

Processes sharing a core must have the same level of isolation (typically a container or VM) that they would normally have.

The reported number of CPU cores reserved for the process, which is available to expressions on the CommandLineTool as runtime.cores, must be a non-zero integer, and may be calculated by rounding up the cores request to the next whole number.

Scheduling systems may allocate fractional CPU resources by setting quotas or scheduling weights. Scheduling systems that do not support fractional CPUs may round up the request to the next whole number.

outdirMax string | number

Maximum reserved filesystem based storage for the designated output directory, in mebibytes (2**20)

See outdirMin for discussion about fractional storage requests.

outdirMin string | number

Minimum reserved filesystem based storage for the designated output directory, in mebibytes (2**20) (default is 1024)

May be a fractional value. If so, the actual storage request must be rounded up to the next whole number. The reported amount of storage reserved for the process, which is available to expressions on the CommandLineTool as runtime.outdirSize, must be a non-zero integer.

ramMax string | number

Maximum reserved RAM in mebibytes (2**20)

See ramMin for discussion about fractional RAM requests.

ramMin string | number

Minimum reserved RAM in mebibytes (2**20) (default is 256)

May be a fractional value. If so, the actual RAM request must be rounded up to the next whole number. The reported amount of RAM reserved for the process, which is available to expressions on the CommandLineTool as runtime.ram, must be a non-zero integer.

tmpdirMax string | number

Maximum reserved filesystem based storage for the designated temporary directory, in mebibytes (2**20)

See tmpdirMin for discussion about fractional storage requests.

tmpdirMin string | number

Minimum reserved filesystem based storage for the designated temporary directory, in mebibytes (2**20) (default is 1024)

May be a fractional value. If so, the actual storage request must be rounded up to the next whole number. The reported amount of storage reserved for the process, which is available to expressions on the CommandLineTool as runtime.tmpdirSize, must be a non-zero integer.

WorkReuseMap object

For implementations that support reusing output from past work (on the assumption that same code and same input produce same results), control whether to enable or disable the reuse behavior for a particular tool or step (to accommodate situations where that assumption is incorrect). A reused step is not executed but instead returns the same output as the original execution.

If WorkReuse is not specified, correct tools should assume it is enabled by default.

enableReuse string | boolean required
NetworkAccessMap object

Indicate whether a process requires outgoing IPv4/IPv6 network access. Choice of IPv4 or IPv6 is implementation and site specific, correct tools must support both.

If networkAccess is false or not specified, tools must not assume network access, except for localhost (the loopback device).

If networkAccess is true, the tool must be able to make outgoing connections to network resources. Resources may be on a private subnet or the public Internet. However, implementations and sites may apply their own security policies to restrict what is accessible by the tool.

Enabling network access does not imply a publicly routable IP address or the ability to accept inbound connections.

networkAccess string | boolean required
InplaceUpdateRequirementMap object

If inplaceUpdate is true, then an implementation supporting this feature may permit tools to directly update files with writable: true in InitialWorkDirRequirement. That is, as an optimization, files may be destructively modified in place as opposed to copied and updated.

An implementation must ensure that only one workflow step may access a writable file at a time. It is an error if a file which is writable by one workflow step file is accessed (for reading or writing) by any other workflow step running independently. However, a file which has been updated in a previous completed step may be used as input to multiple steps, provided it is read-only in every step.

Workflow steps which modify a file must produce the modified file as output. Downstream steps which further process the file must use the output of previous steps, and not refer to a common input (this is necessary for both ordering and correctness).

Workflow authors should provide this in the hints section. The intent of this feature is that workflows produce the same results whether or not InplaceUpdateRequirement is supported by the implementation, and this feature is primarily available as an optimization for particular environments.

Users and implementers should be aware that workflows that destructively modify inputs may not be repeatable or reproducible. In particular, enabling this feature implies that WorkReuse should not be enabled.

inplaceUpdate boolean required
ToolTimeLimitMap object

Set an upper limit on the execution time of a CommandLineTool. A CommandLineTool whose execution duration exceeds the time limit may be preemptively terminated and considered failed. May also be used by batch systems to make scheduling decisions. The execution duration excludes external operations, such as staging of files, pulling a docker image etc, and only counts wall-time for the execution of the command line itself.

timelimit string | number required

The time limit, in seconds. A time limit of zero means no time limit. Negative time limits are an error.

SubworkflowFeatureRequirementMap object

Indicates that the workflow platform must support nested workflows in the run field of WorkflowStep.

ScatterFeatureRequirementMap object

Indicates that the workflow platform must support the scatter and scatterMethod fields of WorkflowStep.

MultipleInputFeatureRequirementMap object

Indicates that the workflow platform must support multiple inbound data links listed in the source field of WorkflowStepInput.

StepInputExpressionRequirementMap object

Indicate that the workflow platform must support the valueFrom field of WorkflowStepInput.

CWLFile object
$schemas
id
stderr
successCodes
cwlVersion
outputs
label
stdout
requirements
doc
temporaryFailCodes
expression
hints
arguments
stdin
baseCommand
class
permanentFailCodes
$namespaces
steps
inputs
intent
CWLGraph object
$graph CWLFile[] required
cwlVersion string

CWL document version. Always required at the document root. Not required for a Process embedded inside another Process.

Values: "draft-2" "draft-3" "draft-3.dev1" "draft-3.dev2" "draft-3.dev3" "draft-3.dev4" "draft-3.dev5" "draft-4.dev1" "draft-4.dev2" "draft-4.dev3" "v1.0" "v1.0.dev4" "v1.1" "v1.1.0-dev1" "v1.2" "v1.2.0-dev1" "v1.2.0-dev2" "v1.2.0-dev3" "v1.2.0-dev4" "v1.2.0-dev5"
CWLGraphOrFile object
$schemas
id
stderr
successCodes
cwlVersion
outputs
label
stdout
requirements
doc
temporaryFailCodes
expression
hints
$graph
arguments
stdin
baseCommand
class
permanentFailCodes
$namespaces
steps
inputs
intent