Versions Compared

Key

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


Panel

On this page

Table of Contents
maxLevel2
exclude(On this page|Use case).*
stylecircle
typeflat
separatorpipe



UI Text Box
sizemedium
typeinfo

Use case

In this use case we will get the assets (formaly formerly insight objects) of a Jira Cloud issue and write the respective object labels to a custom text field.


Image ModifiedPrerequisites

UI Text Box
typeinfo

For this use case we need a custom action for executing the get assets operation. It should be executed for a Jira Cloud instance.


UI Expand
titleCreate a connection

Configure the connection either inside the post function configuration configuration or using the Remote actions page in the Manage apps administration by setting the following input.

UI Steps


UI Step

Name

Atlassian API


UI Step

Connection type

Choose External.


UI Step

Base URL

Code Block
https://api.atlassian.com



UI Step

Authentication

Choose No authenticationChoose Basic authentication and provide an email as the username and an API token as password.




UI Expand
titleCreate an action

Create the action either inside the post function configuration or in using the Remote actions page in the Manage apps administration by setting the following input.

UI Steps


UI Step

Name

Get assets


UI Step

Method

Choose GET.


UI Step

Default connection

Choose Atlassian API.


UI Step

REST path


Code Block
linenumberstrue
/jsm/insightassets/workspace/{workspaceId}/v1/iqlaql/objects?{iqlqlQuery}


Excerpt Include
DECADIS:_snip_execute_remote_action_use_case_values
DECADIS:_snip_execute_remote_action_use_case_values
nopaneltrue

UI Step

Parameters

workspaceId

The workspaceId is used to identify your individual instance of Insight. It is retrieved through the following endpoint: https://SITE_NAME.atlassian.net/rest/servicedeskapi/insight/workspace.

iql

qlQuery

The qlQuery parameter holds an AQL (Asset Query Language) expression and determines IQL stands for "insight query language" and is the way how to determine which objects should be fetched. In this case we want to get all the objects related to the transitioned issueFor the sake of the example we set the issue key as ISSUE-1.

Code Block
linenumberstrue
object HAVING connectedTickets(key = %{issue.key}ISSUE-1)





Image ModifiedConfiguration

UI Steps


UI Step

Add the Execute remote action post function to the desired transition or create a new transition and choose the Expert mode.


UI Step

Select action

Choose the previous created action which we named Get assets.


UI Step

Select connection

It is automatically preselected with the default connection value of the selected action.


UI Step

Update issue fields (optional)

Excerpt Include
DECADIS:_snip_execute_remote_action_default_responses
DECADIS:_snip_execute_remote_action_default_responses
nopaneltrue

UI Steps


UI Step

Select the field to be set.

Choose the text custom field to hold the object entry labels.


UI Step

Set the value manually by using the following parser expression:

Code Block
%{action.response.
Choose List of object labels
objectEntries[*].label}


UI Text Box
typetip

This parser expression uses the field code Action response details and JMESPath in order to get the information from the response.











Image ModifiedRelated use cases

Page properties report
firstcolumnUse case
headingsJWT feature, Workflow function, Parser function, Label
sortByTitle
cqllabel = "use-case-workflow" and ancestor = "73403011"


Excerpt Include
DECADIS:Contact support
DECADIS:Contact support
nopaneltrue


Page properties
hiddentrue


JWT feature

Workflow function

Execute remote action

Label



Page properties
hiddentrue



Status
Tech review

Status
titletodo

Style guide

Status
titletodo

Status
titletodo
Status
colourYellow
titleReady for review
Status
colourGreen
titledone
Status
colourRed
titleflagged