Apps documentation
Issue Templates for Jira
Cloud Server/Data Center
Issue Templates for Jira

Cloud

Server/Data Center

Documentation
FAQ
Release notes
Articles & Videos
Last updated Oct 17, 2023

Dynamic variables from Jira fields

You can define a dynamic variable using a Jira field key. A variable defined this way has the same name and options as the field on the issue crate screen of the target project.

Tip

You can optionally name a variable, otherwise it’s going to have the same name as the name of the Jira field.

You can find all the keys here - https://{yourjira}.atlassian.net/rest/api/2/field.

Examples

Components=[:components]

Fix versions=[:fixVersions]

Priority=[:priority]

Checkboxes=[:customfield_11602]

Labels=[:labels]

Assignee=[:assignee]

Due date=[:duedate]

Date Picker=[:customfield_11692]

Date Time Picker=[:customfield_11620]

Description:[:description]

Text Field (multi-line)=[My custom name:customfield_11606]

Info

You can create Jira fields with a [:customfield_Id] placeholder. Such a placeholder is converted into a variable of the same type as the field. The field needs to be visible.

This variable isn’t generated on the Create from template screen if a field:

  • has limited context.
  • isn’t added to the Create screen.
  • is hidden in a project.

Supported types

Most common fields are supported, including system and custom fields.

If a field type is a supported dynamic variable type, it’s displayed using a dedicated component, for example, the Due date field (:duedate) has the same type as the :date variable, so it’s displayed as a Date Picker.

Otherwise, it’ll be displayed as a simple text field.

Note

Exceptions:

The labels field is displayed as a text field. You can pass values separated by comas to create new labels.

How to pass values selected in variables to Jira fields

Use Smart defaults. Use a variable accessor with the name of a variable, or the name of the field if it’s not given.

Variable defined as Use
[Release versions:fixVersions] variable("Release versions")
[:duedate] variable("Due date")