Extract URL from a link in the Description

Gustavo Moraes
Contributor
January 31, 2025

Good day, guys!

Is there a way to extract the URL inside a link?

E.G.:

Let's say I have, on the issue Description, a text linked to a URL, as below.

It's displayed as "Google" but I need to get the "https://google.com/".

image.png

Is there a way to do that to use in Automation?

Thanks!

2 answers

1 accepted

1 vote
Answer accepted
Atlass Monster
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.
January 31, 2025

@Gustavo Moraes  Hi buddy.

@Marc - Devoteam is probably right, but I'm too stubborn.

 

Can you try this?

Screenshot 2025-01-31 184355.png{{issue.description.match("(\bhttp\b[^\s]*)")}} 

 

It returns: 

Screenshot 2025-01-31 184613.png

Can't get it escape the " ] " but that's your problem, not mine :P

Gustavo Moraes
Contributor
January 31, 2025

Damn, that worked. Some kind of sorcery.

I'll add it to my list of "Jira Tricks"

The only other thing I had to do was split it because I had many URLs through the description.

image.png

{{issue.description.match("(\bhttps\b[^\s]*)").split(",").first}}

Thanks a lot for your help!!

0 votes
Marc - Devoteam
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.
January 31, 2025

Hi @Gustavo Moraes 

Looking at the smart value options that can be used in automation, I don't think this is possible.

Via the API, on retrieving the issue, this will be visible.

Gustavo Moraes
Contributor
January 31, 2025

Good afternoon, @Marc - Devoteam

Somehow @Atlass Monster was able to get it.

Please check his reply.

Thanks for checking, sir!!

Suggest an answer

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

Atlassian Community Events