Notifying multiple teams in OpsGenie (Same ticket)
Asked by Theis Joergensen:

Hi Community,

I have app. 4 teams in OpsGenie and have setup integrations between the individual teams and JSM. My issue is that when 1 JSM ticket triggers alerts via 4 integrations the 4 teams are not notified. Only the first one, the other 3 are just added to the first.

I only solution i can come up with is to have a dummy group in OpsGenie receiving all requests and then make forwarding rules to each of the 4 teams.

Anyone who have tried this with success? Or anyone having another proposal for this use case.

Thanks in advance.

Theis


Answers:
author: Nick H
body: Hi [@Theis Joergensen](/t5/user/viewprofilepage/user-id/4583235) ,

It *sounds* like all JSM webhooks are triggering to Opsgenie, but only one alert is being created due to [deduplication](https://support.atlassian.com/opsgenie/docs/what-is-alert-de-duplication/). This occurs when the alias of an alert matches an open existing Opsgenie alert. By default the JSM integration parses the {{alias}} into the an alert's alias field - which will parse the issue number (Ex: ABC-123):

![dedcomm1.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/176286iA44BE59F42331AC5/image-size/large?v=v2&px=999 "dedcomm1.jpg")

You can edit what data parses into an integration's alias field under the Advanced tab of the integration. Note this tab is only available on the Standard and Enterprise plans (or the JSM Premium and Enterprise plans):

![jsm1.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/176278i0228F2F41F8BDB7F/image-size/large?v=v2&px=999 "jsm1.jpg")

A somewhat easy fix is keeping {{alias}} in the integration's alias field, but also adding something hardcoded to differentiate the alerts a bit. For example with two integrations:

![jsm2.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/176289i899835C640F562C6/image-size/large?v=v2&px=999 "jsm2.jpg")![jsm3.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/176288i40FC077C29847B04/image-size/large?v=v2&px=999 "jsm3.jpg")

Following, an alert should be created through each integration:

![jsm4.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/176290iADA3FD4B58D5B44E/image-size/large?v=v2&px=999 "jsm4.jpg")![jsm5.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/176291iF0095272824657A0/image-size/large?v=v2&px=999 "jsm5.jpg")

Note that if you adjust what data parses in the alias field of the create alert action(s), it should be adjusted in all other actions such as close, ack, etc. The integration uses the alias to perform these others actions, as the alias is the unique identified of an alert.

Hope this helps. If this is not actually happening in your Opsgenie, let us know!

comments: author: Theis Joergensen
body: [@Nick H](/t5/user/viewprofilepage/user-id/2540930)

Thanks for the well-documented solution.

Unfortunately it seems that I don't have the mentioned license as the advance button is not available to me.

Would it work if I add an additional alias field in the "extra properties" list and use different prefixes for the various integrations?

Thanks


author: Nick H
body: Unfortunately adding an additional alias field in the "extra properties" list would not work. The extra properties are a different field than the alias field entirely.

![jsm11.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/176467i25907C8A970DDD3E/image-size/large?v=v2&px=999 "jsm11.jpg")


author: Theis Joergensen
body: [@Nick H](/t5/user/viewprofilepage/user-id/2540930) Do you know of any alternatives I could try, now I don't have the license allowing me to access advanced?


author: Theis Joergensen
body: [@Nick H](/t5/user/viewprofilepage/user-id/2540930)

Hi Nick,

I have another issue related to the same.

Team A (Active in OpsGenie 08.00-15.30CET)

Team B (Active in OpsGenie 15.30-24.00CET)

Both having an integration to JSM where tickets with request type C3 from project XXX triggers an alert.

No matter what time of the day a C3 tickets is raised, the team A integration runs first. This means that between 08.00-15.30CET they receive the notification as they should. However, when team B is on call the system still use the Team A integration first (Which have no one on call), and then the team B integration end up being a deduplicate.

Can I somehow restrict the integration based on time so the Team A integration is paused after 15.30CET? Or can I manage which of the integrations should be primary and send from JSM to Opsgenie first?

Thanks


author: Theis Joergensen
body: [@Nick H](/t5/user/viewprofilepage/user-id/2540930)

Hi Nick, Are you able to support here or can you direct me to the right place. It's a bit critical as we do not receive alerts during one of our shifts every day.

Thanks

Theis


author: Nick H
body: Hi [@Theis Joergensen](/t5/user/viewprofilepage/user-id/4583235) ,

"*Do you know of any alternatives I could try, now I don't have the license allowing me to access advanced*" on Jan 06 - There is realistically no other alternative besides upgrading your plan.

As for the Team A / B time restriction use case, integrations cannot be restricted to time intervals. But you should be able to send all alerts to Team A. Then configure a routing rule that is restricted to the times of Team B's business hours / days. This routing rule would send to an escalation, and the escalation could send these alerts to Team B (along with notifying members of Team A too):

![rrcomm1.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/178279i86F91C930051FB6D/image-size/large?v=v2&px=999 "rrcomm1.jpg")![rrcomm2.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/178280i7EDA7131412F8F3B/image-size/large?v=v2&px=999 "rrcomm2.jpg")

Again, on other plans like Standard or Enterprise, this is a lot easier/possible with functionality such as Advanced integrations, alert policies, and more.

<https://support.atlassian.com/opsgenie/docs/use-advanced-integration-settings/>

<https://support.atlassian.com/opsgenie/docs/create-and-manage-global-alert-policies/>

<https://support.atlassian.com/opsgenie/docs/create-and-manage-team-alert-policies/#Alert-Policy>


author: Nick H
body: The more I thought about this - "*Do you know of any alternatives I could try, now I don't have the license allowing me to access advanced* " - you *might* be able to control this on the Jira side through each Webhook's JQL.

If each Opsgenie team is going to manage a different projects' issues, then each Webhook could trigger only when that project creates an issue. For example:

![jql1.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/178369i725BD8461B3A350F/image-size/large?v=v2&px=999 "jql1.jpg")![jql2.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/178370iA4749EDB3C9CADAB/image-size/large?v=v2&px=999 "jql2.jpg")


Tags: integration

notification