Description from Jira issue to Confluence page single copy

Ruud Ravensbergen May 12, 2023

Hi
I use the option "Create Page in Confluence" from Jira Automation.
How in now get the description from the Jira Issue into a Confluence Template/Page
It only have to do this ones. No active connection

1 answer

0 votes
Thibaut Subra _Elements_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 12, 2023

Hello @Ruud Ravensbergen 

Can you tell us more about how your workflow is set up and your need exactly?

If you want to publish Jira issues to Confluence easily (with post-functions integrated in Jira Automation if needed), our app Publish can help you with that, with synchronization or not. You can try it for free!

Glad to help with your automation anyway. Let me know.

Regards

Ruud Ravensbergen May 12, 2023

I start with a "manual trigger" then I check if it is an epic with "issue type".
The next step is "Create Page in Confluence" in which the title is
"{{triggerissue.summary}} ({{triggerissue.key}})"
Complete the right "space" and the right "parent" page.
At "Template" I refer to an existing confluence template.
The last step is to log the script

This action is performed by the PO if a new epic is put on our board. We work Agile Safe and the epics are created by others. We as a team want our information that is needed for working on the Epic in Confluence. To make it simple, a script seemed to be great  to create a confluence page and then copy the "description" to that page.
Everything works but I don't get the "description" on the Colluence page

Thibaut Subra _Elements_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 12, 2023

Ok I understand.

I'm afraid you can't do that but through REST API by sending web request, it definitely won't be easy.

If you want to do that just by configuring a recipe and adding it to your Jira Automation, I suggest to try our app, it will save you great time an effort. For example you can:

  • insert any Jira issue data in the Confluence page (and keep the value synchronized between the issue and the page if needed)
  • use any Confluence template you need or design the page yourself
  • automatically link the page to the issue

Let me know if you have any question.

Ruud Ravensbergen May 12, 2023

I also tried that. But not a success.
I used this code. No page is made.

code.png

The error {"statusCode":500,"message":"com.fasterxml.jackson.core.JsonParseException: Illegal unquoted character ((CTRL-CHAR, code 10)): has to be escaped using backslash to be included in string value\n at [Source: (com.atlassian.plugins.rest.common.limitrequest.jersey.LimitingRequestFilter$1); line: 8, column: 32]"} is returned
But I can not find the problem there.

Cosmin Soare April 4, 2024

Hi Ruud,

I am in the same situation as you, have you managed to find a way to automate the process?

Ruud Ravensbergen April 15, 2024

Not yet. Bussy with other things right now.

 

Cosmin Soare April 15, 2024

Hi, @Ruud Ravensbergen

I managed to make it work like this, it will create a page on the top level of your space, no parent added in this code:

{
"type": "page",
"title": "{{issue.key}}: {{issue.summary}}",
"space": {
"key": "XX"
},
"body": {
"storage": {
"value": "{{issue.description.htmlEncode}}",
"representation": "storage"
}
}
}

You have to add .htmlEncode at the description to be able to have spaces between description rows.

https://yoursite.atlassian.net/wiki/rest/api/content/

Headers section needs:

Key: Authorization
Value: Basic YourConvertedUser+APIKeyto64BaseString
Ex: youremail+api to 64Base

 

Ruud Ravensbergen April 16, 2024

great @Cosmin Soare 
I going to try that.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events