I'm trying to see if it's possible to add a tag to a story if the design smart link is populated- is that possible? The goal is to be able to search for tickets that have a link to a figma populated in the 'designs' smart link.
Thanks!
Because I'm not actually a regular Figma OR Jira Cloud user, can you tell me how the Figma smart link is presented in the issue?
I was able to add a Weblink to a Figma I just created, as well as paste that link in a comment, which made it into a Smart Link that I can hover over, preview, etc.
If either of those cases is how you're adding smart links to a Jira story, then I think these are your two options:
Link as Weblink:
You'll have to make a Web Request to Jira's REST API for web links, and see if any of them include "https://www.figma.com/"
Details on making web requests to Jira are here: https://community.atlassian.com/t5/Jira-articles/Automation-for-Jira-Send-web-request-using-Jira-REST-API/ba-p/1443828
You'd want to hit an endpoint like: https://YOURHOST.atlassian.net/rest/api/3/issue/{{triggerIssue.key}}/remotelink
(I'm thinking you'd trigger off of "Issue updated".)
So then you'd do need to use Advanced branching to iterate through all of the weblinks:
Then do an Advanced compare condition to see if any of them contain the Figma URL:
Link in Comment:
If you're looking for links in comments, it's a lot easier. You'd just trigger off of Issue commented and then used the Advanced compare condition to check if {{comment}} contains the Figma URL.
If the comparison succeeds, then you'd use the Edit the issue action to add your label.
Let me know if this makes sense, or if you have any questions.
Oh! Rereading your original post, if "Designs" is actually a URL field, this is even easier.
You would trigger on "Field value changed" for the Designs field and then do an Advanced compare condition to check if {{fieldChange.toString}} contains the Figma URL.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.