We have Jira Service Management on Data Center and Opsgenie. I've figured out how to create an incident in Opsgenie and get the Incident ID back from Opsgenie using ScriptRunner and the Opsgenie REST API. What I need to do from here I'm a little lost, how do you create a link to the incident in Opsgenie on the JSM incident?
I know how to create links to Confluence pages using the RemoteIssueLinkBuilder, but there isn't an application type for Opsgenie....
Figured this out with some help from KD at Adapativst. I was looking for a special link type to write the code to, when in actuality this information is stored in new custom field called Linked major incidents, which returns/accepts an array.
Here's an example of the code I was able to use to update the field:
def linkedMajorIncidents = ComponentAccessor.getCustomFieldManager().getCustomFieldObjectsByName("Linked major incidents")
issue.setCustomFieldValue(linkedMajorIncidents[0], [incidentId])
ComponentAccessor.getIssueManager().updateIssue(issue.reporter, issue, EventDispatchOption.DO_NOT_DISPATCH, false)
Journeys is a brand new feature in Jira Service Management that helps you streamline various processes in your organization that may cross multiple departments, such as employee onboarding or off-boarding that require action from different teams. ✨
Join the EAP →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.