Automation to share direct links to KB articles with portal users

Platform Notice: Cloud Only - This article only applies to Atlassian products on the cloud platform.

Summary

This article explains the process of copying the Confluence URL using an Automation rule and pasting it into the comment on the issue publicly so that portal customers can view the KB article. This process saves time for agents because they don't have to manually add a comment to the issue.

Here's how the comment will look on issue view:

(Auto-migrated image: description temporarily unavailable)

On portal:

(Auto-migrated image: description temporarily unavailable)

Diagnosis

As this is an automatic process, we'll use an automation rule to accomplish this requirement.

As there is no direct way to get the URL of the Confluence pages linked to an issue, we will use the Send web request action in an Automation rule to execute the Get remote issue links endpoint:

1 https://<yoursitename>.atlassian.net/rest/api/3/issue/<issyekey>/remotelink

This API endpoint returns the remote issue links for an issue. When a remote issue link global ID is provided, the record with that global ID is returned. Otherwise all remote issue links are returned. Where a global ID includes reserved URL characters these must be escaped in the request.

Solution

Step 1:

Start by creating an Automation rule with a Manual trigger:

(Auto-migrated image: description temporarily unavailable)

Select the Groups that can run trigger. If no value is selected, all logged-in users can trigger the rule manually. You can also select to Show manual trigger for a particular Issue type, Assignee or Issue status.

Step 2:

Add the Send web request action:

(Auto-migrated image: description temporarily unavailable)

Enter the endpoint below:

1 https://<yoursitename>.atlassian.net/rest/api/3/issue/{{triggerIssue.key}}/remotelink

Check the flag Delay execution of subsequent rule actions until we've received a response for this web request.

Encode the credentials "<EMAIL>:<API_TOKEN>" with base64. We can do this with any online tool like Base64 encode. Make sure not to include a line break at the end. Add the Headers with Authorization Basic "<EMAIL>:<API_TOKEN>" encoded to base64.

E.g.: Authorization Basic HzxuhHbhzhdjasYTgdjGfrGHzxuhHbhzhdjasYTgdjGfrG

Step 3:

Add the action Comment on issue:

(Auto-migrated image: description temporarily unavailable)

The smart value shown below will be rendered as the URL of the Confluence page:

1 {{webResponse.body.object.url}}

If the need arises, uncheck the flag: Prevent duplicates by only adding this comment once to a particular issue.

Make sure to change the comment visibility to Share with customer.

If there are multiple pages linked, simply edit the rule to include all the links in the comment

To learn more about Jira automation, refer to Jira Cloud automation

Updated on April 8, 2025

Still need help?

The Atlassian Community is here for you.