Versions Compared

Key

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

...

Below are some example Velocity Scripts that can be used when setting a Dynamic Custom Field Default.

Variable

Description

code

API

Notes

message.getBody()

Get body content of email. Not available for preprocessing task.

message.getSubject()

Gets the Subject content of email.

message.getAllHeaders()

Get all headers of a message.

message.getHeader(name)

Get value of a message header

Parameters

  • name the name of the header to get

issue

If the email being processed has been associated with an existing issue, this contains the issue data. Format is as per the Get Issue response from the Jira REST API.

Code Blockmessage.getSubject

print(str)

Represents the value of the subject header of the email that is being processed.

Code Block
message.getBody()
Represents the value of the resolved body content of the email that is being processed.

Adds output that is recorded during execution and shown in the processing report.

Parameters

  • str (String) the string to be recorded

RegExp

Searches within string values for matching content.RegExp - JavaScript | MDN

Getting the issue ID

Code Block
issue.id

...