Is there a way to link service management incident tickets to opsgenie incidents ?
Asked by zeeshan.khan:

I have a Jira Service Management instance and a service management project that has Opsgenie features built in. I want to know

1. If there is a way to link service management incident tickets to opsgenie incidents ?

2. Create a 2-way sync wherein when an incident is updated/closed in service management project it automatcally closes the opsgenie incident and alerts all stakeholders ?


Answers:
author: Cornelius Maximen
body: I have same issue it was logged with heldesk but never resolved !

comments: author: Connor Eyles
body: Hi [@Cornelius Maximen](/t5/user/viewprofilepage/user-id/4136792)

I'm sorry to hear that this was not resolved for you!

I can see that on the ticket we did not hear back from you so we could not further our investigation on the issue.

If you would like this one resolved, I would suggest that you reach back out to our helpdesk and we can take a look at this one for you :smile:

To further help with the investigation, may I ask if you could provide a HAR file on this issue.  

Please go to Opsgenie alert open it scroll to the "Jira Service Management requests" but before clicking on a Jira Service Management request, I would like you to start capturing in the developer console, then save a .HAR file <https://confluence.atlassian.com/kb/generating-har-files-and-analyzing-web-requests-720420612.html>

Thanks,  
Connor


author: Connor Eyles
body: Hi [@zeeshan.khan](/t5/user/viewprofilepage/user-id/4282601)

Hope you are well :)

Yes, Ticket linking JSM incident tickets to Opsgenie incidents as defined in this document here <https://docs.opsgenie.com/docs/jira-service-desk-cloud>

You can also see my screenshots below showing you how it can be done  

![Image 2021-03-12 at 9.47.56 am](https://p-25foddj.b0.n0.cdn.getcloudapp.com/items/nOulx2mW/efc12e30-afe9-49a5-8568-d845f3814197.jpg?v=402cfb4065d3289a9b942120ecf0d81f)  

![Image 2021-03-12 at 9.48.36 am](https://p-25foddj.b0.n0.cdn.getcloudapp.com/items/Jru1RZW4/53396867-2d6e-4512-bdd7-47233ddd8fdf.jpg?v=669683fbd565e40a78188b6c41fd1775)

At the moment there isn't a way to auto-close incidents, We do have a Feature Request for auto-closing incidents (AG-371). The JSM integration between Opsgenie and JSM relates to "Alerts" Please check out this document <https://docs.opsgenie.com/docs/jiraservicedesk-integration>  

The functionality of the integration {#toc-hId--1270366478}
-----------------------------------------------------------

Jira Service Management to Opsgenie:

* When an issue is created in Jira Service Management, an alert is created in Opsgenie.
* When a comment is added to issue in Jira Service Management, the same comment is added as a note to the alert in Opsgenie.
* **When an issue is closed and resolved in Jira Service Management, the alert in Opsgenie is closed.**

Opsgenie to Jira Service Management:

* If **Send Alert Updates Back to Jira Service Management** is enabled, actions for Jira Service Management are executed in Jira Service Management when the chosen action is executed in Opsgenie for alerts which are created by the Jira Service Management integration.
* If **Create Jira Service Management Issues for Opsgenie Alerts** is enabled, actions for Jira Service Management are executed in Jira Service Management when the chosen action is executed in Opsgenie for alerts which have a source other than the Jira Service Management integration.
* This action mapping features are explained in detail in the **Action Mapping Feature** section below.

Thanks,  
Connor

comments: author: zeeshan.khan
body: Hi Connor,

Thanks for your reply mate. I have all the pre-reqauisites met and both my jira service management and opsgenie accounts are under the same tenant.

I have also tried creating a webhook as suggested in the Opsgenie --\> Teams --\> Integrations --\> Jira Service Management section.

Still, I cannot see any of JSM incidents appearing the details section of the Opsgenie incidents. Refer screenshots below;

![Sample-Incident-Tickets-in-JSM.JPG](https://community.atlassian.com/t5/image/serverpage/image-id/134145i5F88185818326B29/image-size/large?v=v2&px=999 "Sample-Incident-Tickets-in-JSM.JPG")

![Opsgenie-not-linking-JSM-Incidents.JPG](https://community.atlassian.com/t5/image/serverpage/image-id/134142i2C330ADE371DAD98/image-size/large?v=v2&px=999 "Opsgenie-not-linking-JSM-Incidents.JPG")

Is it something to do with my Opsgenie offering? I have free/standard tier at the moment. Which tier you have got there ?


author: Connor Eyles
body: Hi [@zeeshan.khan](/t5/user/viewprofilepage/user-id/4282601)

Another requirement is that the Opsgenie instance and Jira Service Management need to live in the same site for the linking to work, this could be the issue you face.  

Another issue I see from your screenshot is that you are searching for "JSM" where your Incident ticket is "JSDACC"

I cant confirm your setup without your details but if this is still an issue for you I suggest raising a support ticket with us and we can take it from there :)

Thanks,  
Connor


author: Rafa? Starzec
body: Hi [@zeeshan.khan](/t5/user/viewprofilepage/user-id/4282601) you need to add request type in jira project settings to Incident Work Categories, then you will see tickets from this request type avaiabel in opsgenie.

Regards,

Rafa?


Tags: jira-service-management