YouTrack Standalone 7.0 Help

Sequences

The workflow programming language contains a set of predefined sequences.
These sequences include issues, comments, tags, users, issue links, custom field enumerations, versions, builds, ownedFields, groups, states, static elements for sets of values, and strings.
The workflow language does not let you create your own sequence of elements.

When you reference a sequence, you can check each element in the sequence for additional properties that are available for the sequence type.
For example, issue.comments returns a sequence of IssueComment elements.
You can find the first comment that was added to the issue with the operations added and first.
You can then access the properties of the first IssueComment, such as text or author.
A statement that returns this property would look something like this:

if(comments.added.isNotEmpty){text=comments.added.first.text;

You can also iterate over the elements in a sequence with a for each statement. For example: