robotsnoindex
robotsnoindex

Smart values allow you to access issue data within Jira. For example, you can use the following smart values to send a Slack message that includes the issue key and issue summary: {{issue.key}} {{issue.summary}}

To test what a smart value returns, use the Manual trigger with Log action. The result displays in the audit log, as shown below.



The following smart values are available when setting up a rule.

{{issue.[property]}}

The issue smart values are used to access information related to the rule’s active issue, which is the issue the rule is currently acting on.

The information that you can access on the issue are described in the Available properties section below. Some issue properties are more complex, and they’ve been described in their own sections on this page.

 Learn how to use these to interact with Jira’s REST API.

Available properties

Issue fields

  • {{issue.description}} - Returns the content in the issue's Description field.
  • {{issue.key}} - Returns the issue's key, which is a unique identifier comprised of the project key and the issue's number. For example, PROJ-123
  • {{issue.status}} - Returns the issue's status
  • {{issue.status.name}} - Returns the issue's status
  • {{issue.summary}} - Returns the issue's summary
  • {{issue.versions}} - Returns the issue's Affects versions
  • {{issue.issueType}} - Returns the issue's type, for example StoryBug, or Task.
  • {{issue.resolution}} - Returns the issue's resolution.
  • {{issue.updated}} - Returns the date the issue was updated. Can be combined with other date and time smart values. Learn more about date and time smart values.

  • {{issue.Story Points}} - Returns the issue's story point estimate (classic Jira Software Cloud only).

  • {{issue.Story Points estimate}} - Returns the issue's story point estimate (next-gen Jira Software Cloud only).

Issue dates

These can be combined with other date and time smart values. Learn more about date and time smart values.

  • {{issue.created}} - Returns the issue's creation date
  • {{issue.duedate}} - Returns the issue's due date.

Issue users

These can be combined with other user smart values. Learn more about user smart values.

  • {{issue.assignee.displayName}} - Returns the issue's assignee.
  • {{issue.reporter.displayName}} - Returns the issue's reporter. 

{{issue.[Custom Field]}}

Similar to {{issue.[property]}}, you can also access custom field information on your issues.

Available properties

  • {{issue.[Custom Field].id}} - Returns the unique id for the field assigned by Jira. It is better to use this than name as it cannot be changed.

  • {{issue.[Custom Field].description}} - Returns the text displayed below the custom field viewed in the Simple Search column.
  • {{issue.[Custom Field].name}} - Returns the visible label displayed on the left of the field.
  • {{issue.[Custom Field].defaultValue}} - Returns the value displayed on first view of the field.

Example

In the example below, we have a custom field called Team Leader, and the value of the field is currently Alana Grant

{{issue.Team Leader}}


//returns


Alana Grant

{{issue.comments}}

Returns the issue's comments. Because this smart value deals with multiple items (i.e: issues usually have many comments), it can be used with the # symbol to apply the rule to each individual comment. Learn more about using smart values with sections and lists.

Available properties

  • {{issue.comments.last.body}} - Returns the body of the last comment.
  • {{issue.comments.first.body}} - Returns the body of the first comment.
  • {{issue.comments.reverse.body}} - Returns the issue's comments, in reverse order.
  • {{issue.comments.size}} - Returns the number of comments on the issue.
  • {{issue.comments.author.displayName}} - Returns the comment authors.

Example

In the following example, we list each comment that an issue has, and include the author and creation date/time:

{{#issue.comments}}
Comment by: {{author.displayName}} at: {{created}}
{{body}}
{{/}}


//returns


Comment by: Alana at: 2019-05-30T15:36:02.3+0000
Hey team, how are we tracking on this task?


Comment by: Jose at: 2019-05-30T15:40:57.0+0000
We'll be ready to ship at the end of the week.

Comment by: Alana at: 2019-05-30T15:44:15.7+0000
Great, thanks for the update!


In this example, we return the name of the person who added the last comment on an issue:

{{issue.comments.last.author.displayName}} has left a comment on the issue.


//returns


Alana Grant has left a comment on the issue.

{{issue.components}}

Used to access the values in an issue's Components field. Because this smart value deals with multiple items (i.e: issues can have many components), it can be used with the # symbol to apply the rule to each individual component. Learn more about using smart values with sections and lists.

Available properties

  • {{issue.components.name}} - Returns the values in the issue's Component field.

{{issue.epic}}

Used to access information about an issue's epic. This smart value only works for issues that have been added to an epic.

Available properties

  • {{issue.epic.key}} - Returns the epic's key, e.g. PROJ-213

  • {{issue.epic.status.name}} - Returns the epic's status, e.g. In progress

  • {{issue.epic.[Custom Field]}} - Returns the value in an epic's custom field. For example, if the epic has a custom field called Initiative, then {{issue.epic.Initiative}} will return the value in the Initiative field.

{{issue.fixVersions}}

Used to access the values in an issue's Fix Versions field. Because this smart value deals with multiple items (i.e: issues can have many fix versions), it can be used with the # symbol to apply the rule to each individual fix version. Learn more about using smart values with sections and lists.

Available properties

  • {{issue.fixVersions.name}} - Returns the name of the fix version
  • {{issue.fixVersions.description}} - Returns the description of the fix version.
  • {{issue.fix.Versions.archived}} - Returns true if the fix version is archived, and false if not.
  • {{issue.fixVersions.released}} - Returns true if the fix version is released, and false if not.
  • {{issue.fixVersions.releaseDate}} - Returns the fix version's release date. Can be combined with other date and time smart values. Learn more about date and time smart values.

Example

In the below example, we list each fix version that the issue has been added to, followed by the version's release date, in bullet point form.

This issue is part of the following releases:
{{#issue.fixVersions}}
* Fix version: {{name}}, released on {{releaseDate}}
{{/}}


// returns

This issue is part of the following releases:
• Fix version: Version 1.1, released on 2019-08-10T00:00:00.0+0000
• Fix version: Version 1.5, released on 2019-08-02T00:00:00.0+0000

{{issue.latest}}

Prints the issue key and its status (e.g.: To doIn progress, or Done).

Available properties:

  • {{issue.latest.description}} - Returns the status's description.


This smart value requires an expensive reload of issue data and should only be used in situations where subsequent actions need to have visibility of the latest state of an issue, e.g. two Edit issue actions that need to add to the value of a field, instead of overwriting it.

{{issue.parent}}

Accesses the details of a subtask's parent issue. Can only be used when the active issue is a subtask, and can't be used to access a standard issue's parent issue.

Available properties:

  • {{issue.parent.key}} - Returns the issue key of the subtask's parent issue.

  • {{issue.parent.priority.name}} - Returns the priority of the subtasks's parent issue.
  • {{issue.parent.Epic Link}} - Returns the issue key of the parent issue's epic.
  • {{issue.parent.epic.summary}} - Returns the summary of the parent issue's epic.

{{issue.properties}}

Accesses any issue property. Properties are frequently used by add-ons and integrations to store values, e.g.: {{issue.properties.some.value}}.

{{issue.Request Type}}

Accesses information from Service Desk requests.

Available properties:

  • {{issue.Request Type.requestType.name}} - Returns the customer request type.
  • {{issue.Request Type.currentStatus.status}} - Returns the status of the current JSD request.
  • {{issue.Customer Request Type}} - Returns the customer request type for older Jira instances.

{{issue.security}

The text of the security level.

Available properties:

  • {{issue.security.name}} - Returns the security level name.

  • {{issue.security.id}} - Returns the security level ID.

{{issue.url}}

The URL to access the issue. Also provides the customer portal URL for Jira Service Desk issues.

Available properties:

  • {{issue.url}} - Returns the URL of the issue.
  • {{issue.url.customer}} - Returns the customer portal URL (for Jira Service Desk issues)

{{issue.versions}}

Accesses the value in the issue's Affects versions field. Because this smart value deals with multiple items (i.e: issues can have many Affects versions), it can be used with the # symbol to apply the rule to each individual component. Learn more about using smart values with sections and lists.

Available properties:

  • {{versions.name}} - Returns the name of the affects version
  • {{versions.description}} - Returns the description of the affects version.
  • {{versions.archived}} - Returns true if the affects version is archived, and false if not.
  • {{versions.released}} - Returns true if the affects version is released, and false if not.
  • {{versions.releaseDate}} - Returns the affects version's release date. Can be combined with other date and time smart values. Learn more about date and time smart values.

Example

In the example below, the issue's first affects version's release date is printed:

The bug was first discovered in the version released on {{issue.versions.first.releaseDate}}.

{{issue.watchers}}

Accesses the current watchers of an issue. Because this smart value deals with multiple items (i.e: issues can have many watchers), it can be used with the # symbol to apply the rule to each individual component. Learn more about using smart values with sections and lists.

Available properties:

  • {{issue.watchers.displayName}} - Returns the watcher's display name.

  • {{issue.watchers.emailAddress}} - Returns the watcher's email address.

Example

The example below lists each person watching the issue - both their display name and their email address - in bullet point form.

The following people are watching this issue:
{{#issue.watchers}} 
* Name: {{displayName}}, Email: {{emailAddress}}
{{/}}

// returns

The following people are watching this issue:
• Alana, alana@acme.com
• Jose, jose@acme.com

{{lookupIssues}}

Returns a list of issues from a JQL search caused by the Lookup issues action or the Scheduled trigger.

Available properties:

  • {{key}} - Returns the issue key

  • {{url}} - Returns the issue url

  • {{summary}} - Returns the issue summary

  • {{assignee.displayName}} -  Returns the assignee

  • {{reporter.displayName}} -  Returns the reporter

  • {{status}} - Returns the status

  • {{issueType}} - Returns the issue type

  • {{resolution}} - Returns the resolution status

  • {{fixVersion}} - Returns the fix version

  • {{created}} - Returns the date the issue was created

  • {{updated}} - Returns the date the issue was updated

  • {{Story Points}} - Returns the story points for the issue (classic Jira Software)

  • {{Story point estimate}} - Returns the story points for the issue (next-gen Jira Software)

Examples

The following example prints all the issue keys returned from the JQL search, in bullet point form.

Hey team - we've got the following issues left in this sprint:
{{#lookupIssues}}
* {{key}}
{{/}}


The following example sums all of the story points for issues returned from the JQL search.

There are {{lookupIssues.Story Points.sum}} story points remanining.

{{triggerIssue}}

Refers to the original issue that triggered the rule; used when you branch the chain. Used with the Related issues condition. All properties available to {{issue}} are also available on this smart value.

{{attachment}}

Accesses information related to a file attachment on an issue.

Available properties:

  • {{attachment.filename}}: Returns the filename of the attachment.

  • {{attachment.mimeType}}: Returns the file format of the attachment.

  • {{attachment.created}}: Returns the date and time the attachment was added to the issue.

  • {{attachment.size}}: Returns the attachment file size in bytes.

  • {{attachment.author}}: Returns the user who added the attachment. 

    • {{attachment.author.accountId}}: Returns the ID associated with the user name.

    • {{attachment.author.emailAddress}}: Returns the email address associated with the user name.

    • {{attachment.author.displayName}}: Returns the name displayed in your Jira instance.

    • {{attachment.author.active}}: Returns true if their account is active, and false if not.

    • {{attachment.author.timeZone}}: Returns the timezone the user is registered being in; this doesn't change dynamically based upon where the user logs in from, it is the timeZone registered in their user account.

{{baseUrl}}

Prints the url of the Jira instance.

{{changelog}}

  • Used with: any triggers that edit an issue. 

This smart value accesses the changelog, and a list of changes for each field. For example, when an issue is transitioned you can see what status the issue transitioned from.

 Learn more about using smart values with sections and lists.

Available properties

  • {{changelog.summary}} - Changelog information for the Summary field.
  • {{changelog.issuetype}} - Changelog information for the Issue type field. 
  • {{changelog.status}} - Changelog information for the Status field.

Examples

This example returns the new value of an issue's Summary field after it has been changed.

{{#changelog.summary}}
  {{toString}}
{{/}}


This example returns an issue's previous type, after it has been changed.

{{#changelog.issuetype}}
  {{fromString}}
{{/}}


This example shows the previous status for issues that are transitioned.

{{#changelog.status}}{{fromString}}{{/}}


This example shows the previous status id (for use in another Edit action)

{{#changelog.status}}{{from}}{{/}}

{{comment}}

This value won't work for any other trigger, even if a comment was added as a result (e.g. - the Issue transitioned trigger).

Available properties

  • {{comment.body}} - Returns the body of the comment that triggered the rule.
  • {{comment.author}} - Returns the ID of comment's author.
  • {{comment.created}} - Returns the date and time of the comment.
  • {{comment.visibility.type}} - Returns the comment restriction type if any, e.g. role.
  • {{comment.visibility.value}} - Returns the comment restriction label if any, e.g. Developers.
  • {{comment.internal}} - for Jira Service Desk comments, returns false if the comment is visible to customers.
  • {{comment.properties}} - Accesses any comment property. Properties are frequently used by add-ons and integrations to store values.
  • {{comment.properties."sd.public.comment".internal}}

Example

In the below example, we're sending out a notification that someone has added a comment to an issue, perhaps as a Slack message.

Hey team, {{comment.author.displayName}} has left the following comment on {{issue.key}}:
{{comment.body}}


// returns


Hey team, Alana Grant has left the following comment on PROJ-12:
Could I get an urgent update on this please?

{{comment.id}}

Used by triggers that involve adding a comment, such as Issue commented, Issue transitioned, or Issue updated. The comment that triggers the rule is stored in this smart value.

{{createdIssue}}

Accesses the previous issue created in the rule. 

Available properties

Any property used with the {{issue}} smart value can also be used with {{createdIssue}}

{{createdIssues}}

A list of issues that have been created in the rule. 

Available properties

Any property used with the {{issue}} smart value can also be used with {{createdIssue}}.  Learn more about using smart values with sections and lists.

{{#createdIssues}}{{key}}{{/}}

{{eventType}}

The type of event that triggered the rule. For example, jira:issue_updated :issue_commented.


{{fieldChange}}

Available anywhere smart values are supported, to access the value of a field that has changed. For example, if the Assignee of a field changes, you could add a comment to the issue to note who the previous assignee was, and who the new assignee is.

When there are multiple fields that have changed, {{fieldChange}} only contains the first changed value. If multiple values are changed, use # to iterate over these. For example, when setting multiple Fix Versions, then you can iterate over these using {{#changelog.fixVersion}}{{toString}}Learn more about using smart values with sections and lists.

Available properties

  • {fieldChange.fromString}} - Returns the previous value as displayed.
  • {fieldChange.toString}} - Returns the new value as displayed.
  • {{fieldChange.from}} - Returns the previous raw value, e.g. for a select field. 
  • {{fieldChange.to}} Returns the new raw value, e.g. for a select field.

{{rule}}

Accesses information for the current running rule.

Available properties

  • {{rule.name}} - Returns the name of the rule that is currently running.

  • {{rule.actor}} - Accesses the rule actor user.

{{Sprint}}

Accesses information relating to the sprint that triggered the rule.

Available properties

  • {{sprint.id}} - Returns the sprint ID.

  • {{sprint.name}} - Returns the sprint name.
  • {{sprint.isStarted}} - Returns true if the sprint has started, and false if not.
  • {{sprint.isClosed}} - Returns true if the sprint has closed, and false if not.
  • {{sprint.startDate}} - Returns the start date of the sprint.
  • {{sprint.endDate}} - Returns the end date of the sprint.
  • {{sprint.completeDate}} - Returns date the sprint was marked as complete.
  • {{sprint.originBoardId}} - Returns the ID of the board the sprint belongs to.
  • {{sprint.goal}} - Returns the sprint goal.

{{version}}

Accesses information for the version that triggered the rule.

Available properties:

  • {{version.name}} - Returns the version's name.
  • {{version.id}} - Returns the version's ID.
  • {{version.description}} - Returns the version's description.
  • {{version.archived}} - Returns true if the version is archived, and false if not.
  • {{version.startDate}} - Returns the version's start date.
  • {{version.released}} - Returns true if the version is released, and false if not.
  • {{version.releaseDate}} - Returns the version's releae date
  • {{version.project.key}} - Returns the project key of the project the version belongs to.
  • {{issue.versions.first.name}} - 

{{webhookData.[value].[childValue]}}

Allows access to data that was sent along with the incoming webhook, for example, the body of the webhook request.

{{webhookResponse}}

On successful request, you will be able access webhook response data using the available smart values. If you have multiple webhook responses, you can add the # symbol to apply the rule to each individual response. Learn more about using smart values with sections and lists.

Available properties:

  • {{webhookResponse.status}} - response code e.g. 200
  • {{webhookResponse.headers}} - headers that can be accessed with dot nation
  • {{webhookResponse.headers.Content-Type}}
  • {{webhookResponse.body}} - body that can be accessed with dot nation
  • {{webhookResponse.body.name}}
  • {{webhookResponses}} - list of responses made when list operations
  • {{webhookResponses.last.body}}

Example

This is how you would return multiple responses using the smart value:

{{webhookResponses.last.someValue.childValue}}
{{#webhookResponses}}
    Data from response: {{someValue.childValue}}
{{/}}

{{worklog}}

Accesses information for a worklog entry that has just been logged against an issue.

Available properties

  • {{worklog.comment}}
  • {{worklog.started}}
  • {{worklog.timeSpentSeconds}}
  • {{worklog.timeSpent}}
  • {{worklog.visibility}} - available when the worklog is restricted
  • {{worklog.visibility.type}} - available when the worklog is restricted
  • {{worklog.visibility.value}} - available when the worklog is restricted

{{issue.InsightField}}

Accesses an insight field's full name, key, or summary.

Available properties

  • {{issue.InsightField}} - Returns the issue summary and issue key
  • {{issue.InsightField.key}} - Returns the issue key
  • {{issue.InsightField.summary}} - Returns the issue summary

{{issue.TempoAccountField}}

Accesses a Tempo Account field's properties.

Available properties

  • {{issue.TempoAccountField}} - Returns the name of the account
  • {{issue.TempoAccountField.id}} - Returns the ID of the account
  • {{issue.TempoAccountField.name}} - Returns the name of the account
  • {{issue.TempoAccountField.value}} - Returns the name of the account


Last modified on Oct 7, 2020