youngmon/atlassian-qna huggingface dataset:
single sign-on for portal-only customers set up
Asked by Andrew Marsh:

We are trying to set up Single sign up for Microsoft accounts to sign into the portal as customers only, allowing them to raise tickets from the portal  

However we keep getting "Need admin approval" we do not seem able to turn this off, guides for how to set up SSO from start to finish are also poor in quality and we are struggling to follow these.  

Is anyone able to support or link me to a thread about how to set these up, please do not link the Jira one: [Configure SAML single sign-on for portal-only customers \| Atlassian Support](https://support.atlassian.com/security-and-access-policies/docs/configure-saml-single-sign-on-for-portal-only-customers/)  

It has not been helpful at all.  

Thanks in advance.


Answers:
author: Andrew Marsh
body: Issue has been found, after having set everything up, that error what it actually means is a Admin has to login first with one of their SSO accounts first, after that everything worked.  

<br />


Tags: cloud

jira-service-management

jira-service-management-cloud
Copy attachments between 2 issue on different projects
Asked by Claire Berry:

I have set up a global automation to copy attachments between 2 types of issues on 2 different projects.  

When an attachment is added to the issue in project A, I want the attachment to copy over to the linked issue on project B.  

The issue I am having with the automation is that it is duplicating the attachments.  

For example, let's say I add one attachments image1.png to the issue in project A. This attachment then gets copied to the linked issue in project B (correct).  
Then I add another attachment image2.png to the issue in project B.  
But instead of just image2.png copying over to the issue in project A, both image1.png AND image2.png copy over.  
So I end up with duplicate attachments on the issue in project A: image1.png, image1.png, image2.png.  

Can anyone help configuring what I am trying to achieve here? I only want to copy over the new attachment added, not all existing attachments.   

Here is the automation:  
![attachment-automation.png](/t5/image/serverpage/image-id/333006i7EEE9D7E16A2C6F0/image-size/large?v=v2&px=999 "attachment-automation.png")


Answers:
author: Claire Berry
body: Ended up getting this working with a custom script (thanks Scriptrunner!)  

![attachment-automation1.png](https://community.atlassian.com/t5/image/serverpage/image-id/333565iAF2181D69BF28EE7/image-size/large?v=v2&px=999 "attachment-automation1.png")  

Full script here:  

```
import com.atlassian.jira.component.ComponentAccessor

def attachmentManager = ComponentAccessor.attachmentManager

def user = Users.getByName('Automated-Jira-User')

def linkedIssues = ComponentAccessor.getIssueLinkManager().getLinkCollection(issue, user).getAllIssues()

def redirectedIssue

// Get the redirected linked issue

linkedIssues.each {

    if(it.getLabels().toString().contains('ukisr-redirected-ticket') || it.getIssueType().name == 'Software Project Redirect v2' || it.getIssueType().name == 'Software Project Redirect - 1 approval'){

        redirectedIssue = it

    }

}

if(!redirectedIssue){ return }


// Get current attachments for both issues

def attachments = issue.attachments

def redirectedAttachments = redirectedIssue.attachments

def redirectedAttachmentsFileNames = []

// Get all file names for attachments in linked issue to compare later

redirectedAttachments.each{ redirectedAttachment ->

    redirectedAttachmentsFileNames += redirectedAttachment.filename

}

attachments.each { attachment ->

    // If attachment doesn't already exist on linked ticket, add it

    if(!redirectedAttachmentsFileNames.contains(attachment.filename)){

        // log.warn('attachment not on linked issue')

        attachmentManager.copyAttachment(attachment, user, redirectedIssue.key)

    }

}
```


author: Bibek Behera
body: Watching this I have some suggestions on the cloud that I have checked on, not for the DC/Server.


Tags: automation

jira-service-desk-data-center

jira-service-management

jira-service-management-data-center

jira-service-management-server

server
Running an App to get a list of all hardware in the office
Asked by Helpdesk:

Does anyone know how to get automatically a list of all laptops, printers, NAS etc... in the office without entering them all in manually.

We are all using MAC.'s.

Is there some application that can do an PORT SCan or something like that.

I am really new at this software.

Thanks again


Answers:
author: Julian Governale
body: If your company is using an asset management software you can attempt the External Asset import which requires a token to be generated and added to the other system. Might not be doable in your setup but here is some documentation:

[Generate a token for importing \| Jira Service Management Cloud \| Atlassian Support](https://support.atlassian.com/jira-service-management-cloud/docs/generate-a-token-for-importing/)

You can also import from a web address, i.e. your assets are in an internal DB, and a developer created an endpoint to expose it

[Import data from a web address \| Jira Service Management Cloud \| Atlassian Support](https://support.atlassian.com/jira-service-management-cloud/docs/import-data-from-a-web-address/)


author: Bibek Behera
body: [@Helpdesk](/t5/user/viewprofilepage/user-id/5534154) ,

Welcome to the community. I would like to get more information on what exactly you are looking for.

Case 1\> Looking for all the hardware, Connected / Offline

Ideally, there should be at least one asset management system in place what I assume for the office space, that can be an excel to start with.

Case 2\> Online Devices

If you are looking to get the list of devices connected to the network,

**For macOS:** In the menu bar, click on the Wi-Fi icon and select Open Network Preferences. Select the Advanced Settings option in the bottom right corner. In the next window, navigate to the TCP/IP option to find the router IP address.

* In the browser tab, enter the login credentials to access your router's administrative panel. Find the login details on the back of your router or the usage guide that comes along with it. Reset the router if you've forgotten the existing password.
* After login, your router's default home page will appear. It will contain the list of all devices accessing your wireless network under the Status, Wireless Client, or similar section.

-[Bibek](https://www.linkedin.com/in/ibibekbehera/)


Tags: cloud

jira-cloud-administration

jira-service-management

jira-service-management-cloud

not-applicable
How do I get the user who deleted the Assets object?
Asked by Aleksandr Derugo:

Hi, maybe someone can help me with this.

I'm trying to get the user who deleted an asset object, and write his username to an object of a different type. I have already tried using the "Object deleted" trigger in Assets automation, but I can't find the correct placeholder for the http request there.

A4J doesn't have the correct trigger.

Any ideas please.

P.S. Groovy script doesn't work for me, because api method "storeObjectBean" doesn't always re-index the object.


Answers:
author: Aleksandr Derugo
body: I'm closing this question. I found an option using ScriptRunner Listener which is completely suitable for me.


Tags: assets

data-center

jira-service-management

jira-service-management-data-center
Can we setup to create Jira tickets automatically for aws connect call center?
Asked by Samudra Lakshani:

I want to setup Jira ticketing system to create tickets automatically when we recieve a call for aws connect call center. Please update me is there any system for my issue. If there is, please guide me for complete it.

Thanks


Answers:
author: Steffen Opel _Utoolity_
body: Hi [@Samudra Lakshani](/t5/user/viewprofilepage/user-id/5533749), and welcome to the Atlassian Community!

I'm afraid there is no readily available solution to integrate [Amazon Connect](https://aws.amazon.com/connect/) with Jira:

1. The question has come up before in [December 2022](https://community.atlassian.com/t5/Jira-Service-Management/can-jira-service-desk-directly-integrat-with-amazon-connect/qaq-p/2209627) and [March 2020](https://community.atlassian.com/t5/Jira-Service-Management/Are-there-any-integrations-for-Service-Desk-to-Amazon-Connect/qaq-p/1332568), to no avail
2. The latter post has a [content free answer](https://community.atlassian.com/t5/Jira-Service-Management/Re-Are-there-any-integrations-for-Service-Desk-to-Amazon/qaq-p/2232666/comment-id/124663#M124663) from an AWS solution partner who claims being able to help you implement one, and they also offers that via the [AWS Marketplace](https://aws.amazon.com/marketplace/pp/prodview-ic7n3pbg5nlm2), but given the resp. press release from [April 2023](https://uk.devoteam.com/news-and-pr/devoteam-can-help-integrate-amazon-connect-and-jiraplatforms-for-a-omnichannel-experience-2/) lacks any details, this amounts to nothing but a consulting offer to implement a custom solution as per 4
3. While [Amazon AppFlow](https://aws.amazon.com/appflow/) automates "data flows between software as a service (SaaS) and AWS services" and conceptually supports both Amazon Connect and Jira, ironically it lacks both required directions, i.e. you can't use it as [data source to transfer data from Amazon Connect](https://docs.aws.amazon.com/appflow/latest/userguide/connectors-amazon-connect.html), and neither as a [data destination to transfer data to Jira Cloud](https://docs.aws.amazon.com/appflow/latest/userguide/connectors-jira-cloud.html)
4. A brief Reddit thread from [January 2024](https://www.reddit.com/r/amazonconnect/comments/19fdl6n/amazon_connect_jira/) confirms the absence of a readily available integration and the ability to implement this yourself by leveraging the [Amazon Connect API](https://docs.aws.amazon.com/connect/latest/APIReference/Welcome.html), e.g. by leveraging an [AWS Lambda](https://aws.amazon.com/lambda/) function or an [AWS Step Functions](https://aws.amazon.com/step-functions/) state machine

Accordingly, you either need to implement a custom solution yourself, or contract with an AWS or Atlassian solution partner who does this for you.

Good luck,  
Steffen


Tags: cloud

jira-service-management

jira-service-management-cloud
Request participants not added when user gets CC'ed in the email
Asked by Nikola Perisic:

Hello community!

Not sure what happened, but it seems that after the new update for adding up to 10 email addresses for a JSM project. We have one custom email address that has been set to reply to address.

Before, this worked fine. Now, when a user raises a request via email and adds another user as CC, they do not get added as request participants anymore. Can you help?


Answers:
author: Dan Breyen
body: Hi [@Nikola Perisic](/t5/user/viewprofilepage/user-id/5166624) I found [this issue](https://jira.atlassian.com/browse/JSDCLOUD-14059) on Atlassian's Jira site. It sounds like what you're looking for.

If it is, feel free to vote for and watch it for updates.

comments: author: Nikola Perisic
body: hI [@Dan Breyen](/t5/user/viewprofilepage/user-id/5086375)

Thanks, this is more geared towards the official email domains for example outlook or gmail ones. For outlook it didn't want to add request participants at all (for a whole day), for gmail it did it right away. I have the second option selected which allows cc'ed users to be added as request participants.

I will use this ticket as the reference for the customers.


author: Nikola Perisic
body: Does this mean that outlook and gmail would be added as domains as well? This is creating a security concern though.


author: Nikola Perisic
body: The workaround by Atlassian was proposed:

* In user access settings (admin.atlassian.com), select Any domain
* Locate the JSM product
* For a role, choose None


Tags: cloud

jira-service-management

jira-service-management-cloud
Send web request, handle response code not equal to 200
Asked by johanzetterlund:

Hi,

I am trying to write an Jira Project Automation that sends a webrequest.

If I get a response code that is NOT 200 I would like to send another webrequest to another url.

I am trying to use:

**If: matches**

**{{webhookResponse.status}} does not equal 200![script.png](/t5/image/serverpage/image-id/126007iDA63D51EA1D63E1B/image-size/large?v=v2&px=999 "script.png")**

But the problem is that Jira Automation stops the execution if the webhook response isn't 200 so it is not event trying to send to my second webserver.

This is the Audit log:

Status: SOME ERRORS

##### **Action details:** {#toc-hId-1904583384}

#### **[Send web request](https://jira.softronic.se/secure/AutomationProjectAdminAction!default.jspa?projectKey=STEST#/rule/303/14864)** {#toc-hId-1894080280}

**Error response HTTP body:Error publishing webhook. Response HTTP status:400**

![auditlog.png](/t5/image/serverpage/image-id/126008i9BFF15BF78E6DF63/image-size/large?v=v2&px=999 "auditlog.png")

Is it possible to read the response.status and send a new webrequest if it's not 200?


Answers:
author: Darryl Lee
body: I'm thinking it's not possible. I had a web request that had a possibility of failing, and I tried to "trap" for unsuccessful requests by checking {{webhookResponse.status}}. It never worked.

Alas, upon closer inspection, you only that smart value that if it's successful:
> On **successful** webhook execution, you would be able access webhook response data using the following smart values:

I think we'll need to ask for a Feature Request. :-}

comments: author: johanzetterlund
body: Thanks for the reply!

Hmm ok, I'll have to work around this in another way, then.


author: Kerrick Cavanaugh
body: Is there an update on this? I am trying to do the same.


author: Kevin Bianchi
body: For information, since version 8.0 from Jira Automation.

The rule now continue even if the response is in error.

This will allow to test this value.

<https://confluence.atlassian.com/automation/send-web-request-action-now-provides-response-data-993924775.htm>

What is strange is that ticket <https://jira.atlassian.com/browse/JIRAAUTOSERVER-180> is still open.


author: Marlene Koh
body: Feature requests:

Cloud: <https://codebarrel.atlassian.net/browse/AUT-1450>

Server: <https://jira.atlassian.com/browse/JIRAAUTOSERVER-180>


Tags: cloud
Copy from linked issue fields not working
Asked by Allen Culpepper:

I have an automation rule which runs when an issue is linked and tries to copies the field values from the linked issue over to the source issue. It seems to run fine and issue keys seem to match what I'm trying to copy from but it just doesn't copy anything.

I use the "If Matches" issue type = task to match the linked issue type (the one to pull data from).

Scope = multiple projects.

Basically I'm just trying to copy a bunch of fields from the linked issue.

![Screen Shot 2021-01-12 at 11.43.21 AM.png](https://community.atlassian.com/t5/image/serverpage/image-id/125252i3C123377F9365B81/image-dimensions/571x460?v=v2 "Screen Shot 2021-01-12 at 11.43.21 AM.png")![Screen Shot 2021-01-12 at 9.19.42 AM.png](https://community.atlassian.com/t5/image/serverpage/image-id/125254i5255D9A59B02126B/image-dimensions/569x377?v=v2 "Screen Shot 2021-01-12 at 9.19.42 AM.png")


Answers:
author: Curt Holley
body: I notice you are using the "Relates" link type, which is an extra confusing one as both the inbound and outbound descriptions are "relates to". Which makes me wonder if it isn't doing it because the linkages are round the wrong way. Have you tried testing with another link type? or doing the opposite link configuration? *I know I get confused as when dealing with links and which is source and which is destination.*

comments: author: Allen Culpepper
body: Hello Curt,

Thank you, I played with directions of link checks and finally got it to work!

Allen
Jira automation "Create issue with "more options""
Asked by Benoit:

Hi everyones,

Is someone can tell me why this is not working?

I use jira automation to create task.

My problem is when I create more than one issuelinks. this solution works for components. so i know that my syntax is ok. please see the bold character for the part that is not working.

Please help

{  
"fields": {  
"Epic Link": "{{#createdIssues.get(4)}}{{key}}{{/}}"  
},  
"update":  
{"issuelinks":\[{  
"add": {  
"type": {"name": "Blocks"},  
"inwardIssue": {"key": "{{#createdIssues.get(8)}}{{key}}{{/}}"}  
} }**,{**   
**"add": {**   
**"type": {"name": "Blocks"},**   
**"inwardIssue": {"key": "{{#createdIssues.get(7)}}{{key}}{{/}}"}**   
**} },{**   
**"add": {**   
**"type": {"name": "Blocks"},**   
**"inwardIssue": {"key": "{{#createdIssues.get(6)}}{{key}}{{/}}"}**   
**} },{**   
**"add": {**   
**"type": {"name": "Blocks"},**   
**"inwardIssue": {"key": "{{#createdIssues.get(5)}}{{key}}{{/}}"}**   
**}**   
**}** \]  
}  
}


Answers:
author: Bill Sheboy
body: Hi [@Benoit](/t5/user/viewprofilepage/user-id/3949050)

Would you please post an image of your rule and audit log for context?

What is happening when you say it is not working? For example, does it show an error, not add the links, or do something unexpected?

Best regards,  
Bill

comments: author: Benoit
body: no error, it keeps only one link.

I think the Automation is based on the rest API and the rest API does not support more than one link at a time...


author: Bill Sheboy
body: Hmmm... Have you tried to add the links one at a time with separate actions? It appears that you have a known number of issues to link.


author: Benoit
body: Your proposed strategy is possible if I modifying the trigger issue, but the current situation is that I am creating a bunch of Epic and Issues. (kind of a template) So I have multiple dependency for all those different issues created.


author: Bill Sheboy
body: Hi Benoit,

Thanks, and I understood that from your JSON snippet. I noted your use of {{createdIssues}} with specific issues, such as get(8), and so I wondered if you could update the target issue with the links one at a time. Apologies if I am misunderstanding your use case.

Thanks,

Bill


author: Benoit
body: simple answer, it happened in some cases, that from one issue, 4 cannot be started before the first issue is done. Then those 4 issues need to be closed before the next one start.

I can do that manually, but with automation I can't figure it out.


author: Bill Sheboy
body: Okay, there could be timing issues. The pieces of an automation rule can execute asynchronously, which certainly causes some problems.

Would you please post an image if the full rule? That will help the community see some context for the symptom you are seeing. Thanks!
Linking Issues From a List to One Another
Asked by Matt Steadman:

Hi,

I am trying to come up with a way to accomplish the following using Automation for Jira:

- Issue is linked to multiple issues. (IE: Issue A links to Issue B, Issue C, and Issue D using as a Ships With Link)

- Issues that were linked to the single issue also link to the other issues as well. (IE: Issue B links to Issue C and Issue D using a Ships With Link. Issue C links to Issue B and Issue D using a Ships With Link. Issue D links to Issue B and Issue C using a Ships With Link.)

Currently I have come up with a way that when a issue is linked with the Ships With Link that a custom field will populate with all of the Issue Keys (the Issue Key of the Trigger Issue as well as all of the Linked Issues). I am then linking the other issues to all of the Issues Keys in the Custom Field.

The problem I am running into now, is that the automation does link the issues as it should, but, it does always throw the error of "You cannot link an issue to itself." (because the Issue Key for the Issue also resides in the list on the Custom Field).

My question is, is there a easier method that anyone has accomplished linking all the issues back to one another? Or, is there a way to ignore the error of "You cannot link an issue to itself." so that I will still receive emails when a rule fails after a success?

Attached are screenshots of the rules and error log

Thanks!

![Screenshot_Rule_Part1.png](https://community.atlassian.com/t5/image/serverpage/image-id/124105iC3EAAF55A46A59F9/image-size/large?v=v2&px=999 "Screenshot_Rule_Part1.png")![Screenshot_Rule_Part2.png](https://community.atlassian.com/t5/image/serverpage/image-id/124106i9AD8769419E965E9/image-size/large?v=v2&px=999 "Screenshot_Rule_Part2.png")![Screenshot_Rule_AuditLog.png](https://community.atlassian.com/t5/image/serverpage/image-id/124107iFF89B21E40305F14/image-size/large?v=v2&px=999 "Screenshot_Rule_AuditLog.png")


Answers:
author: nmenere
body: Hi [@Matt Steadman](/t5/user/viewprofilepage/user-id/752843) ,

I spent an hour trying to come up with a solution around this but it is hard to remove the key from that string and still have it parsed by the link issue component. e.g. using

```
{{triggerIssue.Shipped With Keys.remove(issue.key)}} 
```

results in
> ABC-123, , ABC-234

If we had a "[filter](https://codebarrel.atlassian.net/browse/AUT-1241)" mechanism on lists it could work, but alas, we don't.

Cheers,  
Nick

comments: author: Matt Steadman
body: Thanks for your time Nick.


author: Bill Sheboy
body: Hi [@Matt Steadman](/t5/user/viewprofilepage/user-id/752843)

Please consider posting an image of your rule and the audit log for a case showing the error. This will provide some context for people to help out. Thanks!

I suspect that the solution to your use case will end up being selective about what values you put into that custom field, and so prevent the rule/tree from looping back on the trigger issue.

Best regards,

Bill

comments: author: Matt Steadman
body: Thanks Bill, I have edited the original post to include those screenshots


Tags: jira-cloud
Change Parent Issue status when 2 or more sub-tasks are in a status
Asked by Sarath:

My requirement is, I would like to automate parent issue transition when 2 or more sub-tasks of that parent issue are in a certain status.

Example: If parent issue is in open status, and when two or more of its sub-tasks are changed to "status A", then parent issue should be moved to in-progress.

For this, I have used advanced compare condition in automation for jira.When this condition is met, For parent, status transition to happen.  
![advanced compare condition.PNG](/t5/image/serverpage/image-id/123587i7DFD0D13CEC87685/image-size/large?v=v2&px=999 "advanced compare condition.PNG")  
But when I tested this automation rule, even when there is one sub-task with statusA, the automatic transition is happening. It is considering the condition "greater than".  

I would like to know if it is possible using automation for jira plugin, if so, what should I make changes in my approach.  

Thanks in advance.


Answers:
author: Bill Sheboy
body: Hi [@Sarath](/t5/user/viewprofilepage/user-id/212690)

It seems your advanced compare is only testing the one sub-task and not the others.

Have you considered using JQL and [Lookup Issues](https://support.atlassian.com/jira-software-cloud/docs/automation-actions/#Automationactions-Lookupissues) to find the sub-tasks which are in the status you care about, and then check the size to see if there is more than one: {{lookupIssues.size}}

If more than one, then update the parent.

Best regards,

Bill

comments: author: Sarath
body: Thank you, we're using automation for jira in server version. Seems like lookup issues action is not available in this moment.


author: Bill Sheboy
body: Thanks for that information, Sarath.

That is correct that Lookup Issues is only for cloud version. For server version, JQL result sets are representented by the {{issues}} smart value (note this is plural). So then {{issues.size}} could work for you.

<https://confluence.atlassian.com/automation/smart-values-993924860.html>


Tags: cloud

jira

sub-task

workflow