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 automatically set the assignee of the external issue by putting the same value as in the transitioned issue. Afterwards, we will add in a comment the status of the operation response.


Prerequisites

UI Text Box
typeinfo

For this use case we need a Connection communicating to the external Jira instance and an Action for executing the update Jira issue operation.


UI Expand
titleCreate a connection

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

UI Steps


UI Step

Name

External Jira instance


UI Step

Connection type

Choose External.


UI Step

Base URL

Code Block
http://JIRA_BASE_URL



UI Step

Authentication

Choose Basic.

UI Text Box
sizemedium
typetip

In a Jira Cloud instance the username should be set using the email of the user you want to be authenticated with. Whereas the password is an API token.

The following example considers connecting with a Jira on-prem instance. The input is for the sake of the use-case. Please make sure to use realistic data of an existing user.

Set username.

Code Block
admin

Set password.

Code Block
admin_password





UI Expand
titleCreate an action

Create the action either inside the post function configuration or using the Remote actions (JWT) admin page (the link can be found in the side bar of Apps Menu)  by page in the Manage apps administration by setting the following input:.

UI Steps


UI Step

Name

Update issue


UI Step

Method

Choose PUT.


UI Step

Default connection

Choose External Jira instance.


UI Step

REST path


Code Block
linenumberstrue
/rest/api/2/issue/{issueKey}


Excerpt Include
DECADIS:_snip_execute_remote_action_use_case_values
DECADIS:_snip_execute_remote_action_use_case_values
nopaneltrue

UI Step

Parameters

issueKey

It is the key or ID of the issue in the external Jira instance we want to update. Since there is no automatic way of grabbing the external linked issues we will set it manually as ISSUE-1. 

Code Block
linenumberstrue
ISSUE-1



UI Step

Action body

This is the JSON body required for executing the REST call. We use a field code to get the current assignee.

UI Text Box
sizemedium
typetip

The body data differs based on the platform (cloud or on-prem).

In case of communicating to an external Jira on-prem instance, you should provide the data as follows:

Code Block
linenumberstrue
{"update": {
        "assignee": [
            {
                "set": {
                "name": "%{issue.assignee}"
                }
            }
        ]
     }
 }

In case of communicating to an external Jira Cloud instance, you should provide the data as follows: 

Code Block
linenumberstrue
{"update": {
        "assignee": [
            {
                "set": {
                "accountId": "%{issue.assignee}"
                }
            }
        ]
     }
 }





Configuration

UI Steps


UI Step

Add the Execute remote action post function to the desired transition or create a new transition.


UI Step

Select action

Choose the previous created action which we named Update issue.


UI Step

Select connection

The default connection of the selected action should be preselected, which is the External Jira instance.


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 Description.


UI Step

Set the value.

Choose Response status.










Related 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

Parser functions
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