Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Introduction

The Automation Toolbox for Jira Expression Parser provides over 200 functions and operators to read, manipulate and filter data from Jira issues, users, groups, projects and more. Among others, the functions support setting and/or updating field values, issue filtering, date and time calculations, string manipulation and execute mathematical operations. An extensive set of operators provide the ability to write conditional functions, do validations with corresponding error texts, mathematical operations, and comparison expressions.

The expression parser has been in constant development since 2009 when it was first introduced in Jira Workflow Toolbox. Since that time, the expression parser has seen constant development, improvement, and extended functionality

This page will help you to get familiar with the powerful expression parser. We provide several use cases that will guide you to write simple expressions as well as high complex expression. To understand the expression parser, work through the sections on this page and you will be able to use it like a pro.

Table of Contents

Introduction

The expression parser was written by Fidel Castro Amario starting 2009 for Jira Workflow Toolbox, 2017 acquired by us, Decadis AG. We are continuously improving and extending the parser together with the founder Fidel Castro Amario. We extracted the expression parser that we can now offer the functionality in certain Jira apps.

Main Features

The expression parser has two major core functionalities. We use Virtual Fields to read and write issue fields and offer several :

  • extended accessibility to issue, system, project, version, component, and user data through the use of Virtual Fields 
  • an extensive set of operators and functions to read, filter

...

  • , extract, manipulate, write or update related data

Virtual Fields

...

/ Field Codes

Virtual Fields and their associated Field Codes, were created to a) provide workflows with data accessibility beyond the scope of normal Jira workflow processing and b) to insure data integrity throughout their use. In ATJ you can use Virtual Fields by searching for and picking their associated Field Codes in the dropdowns provided wherever a parser expression can be inserted. 

Please see the pages covering Field Codes and Usage and Virtual Fields for more detailed descriptions.

Below are a few examples of Field Codes. The full list of field codes is available here.

Sample string field codes (always preceded  by a % sign)

The concept behind virtual fields is to make it possible to write several issue fields and virtual fields that are standard fields like the issue summary and fields that are not writable by default. You can for example trigger the execution of a transition using the virtual field "Issue Status" or add a new comment using the virtual field "New Comment".

Reading virtual fields to use their values to update other fields is possible with field codes. We support string and number field values. An example of a string field code is: %{issue.summary} and a number field code is {issue.dueDate}. Every feature in our app supporting expressions provide dropdown fields to search for the available field codes and insert the field code in your expression. So you don't need to remember the field codes. You always can search for the right field code.

...

  • %{issue.key}
  • %{issue.summary}
  • %{issue.description}
  • %{issue.assignee}
  • %{parent.key}
  • %{parent.summary}

...

Number field codes are only available for number fields, date/time fields and countable virtual fields. The full list of field codes is available here.

Functions

...

and Operators


Please use one of the following links for detailed descriptions of functions and operators.

The expression parser provides over 200 functions to read, manipulate and filter data from Jira issues, users, groups and more. The functions support issue filtering, date calculation, string manipulation and more. A great set of operators allows you to write conditional functions, mathematical operations and comparison expressions.

The following list shows the overview of operators and function provided by the parser:

Operator

  • Boolean operator
  • Mathematical operator
  • List operator
  • Logical operator
  • Conditional operator

Functions

  • Issue data functions
  • User, Group & Role functions
  • Version functions
  • Field history functions
  • Selectable fields functions
  • Mathematical functions
  • Date-Time functions
  • String functions
  • String list functions
  • Issue list functions
  • Number list functions
  • Cast functions

You can find all functions here.


The Expression Parser Syntax Specification

...