Add the corresponding labels for the parser functions used in the use case. For example, add the label parser_func_previousvalue if the parser function previousValue() has been used.

If the post function is Execute remote action, add also the label use-case-action

On this page

Do not edit this macro

Use case

Translate the description of the issue to English using the DeepL REST API.

  Prerequisites

 In Jira administration > Manage apps > Remote actions > Connections, create a new connection and name it. 

 Set the following base URL.

https://api-free.deepl.com/v2

If you are already have a DeepL API Pro plan, use the following base URL instead.

https://api.deepl.com/v2
 Select No authentication as authentication method.

  Configuration

Add the Execute remote action post function to the transition of your choice.

Action

In Expert mode, create a new action with the following parameters:

Name

Enter Translate description as the name of the new action.

Method

Select the POST method.

Default connection

Select the connection with DeepL.

REST path.

Use the following REST path after replacing nnnnn-nnnnn with the authorization key from your DeepL account.

/translate?auth_key=nnnnn-nnnnn

Action body

Enter this action body.

{
	"text": ["%{{replaceAll(htmlToTxt(wikiToHTML(%{issue.description})), "\"", "'")}}"],
    "target_lang": "EN"
}

The target language of the translation can be edited by changing the value of the "target_lang" key according to the DeepL specifications.

Update issue fields

Update a Text Field (multi-line).

 Select the option Set field value manually (parser expression).

Enter the following expression with the expression editor in General mode.

%{action.response.translations[*].text}

  Related use cases

Select in the filter the parent page in the With ancestor filter

JWT feature

Workflow function

Execute remote action

Parser functionsreplaceAll() wikiToHTML() htmlToTxt()
LabelIf proceeds, use the label staff pick