youngmon/atlassian-qna huggingface dataset:
opsgenie and alertmanager integration yaml file
Asked by Guillaume Bettayeb:

Hi everyone,

I am trying to get alertmanager to forward alerts to opsgenie.

I have had a look at <https://prometheus.io/docs/alerting/latest/configuration/#opsgenie-receiver-%3Copsgenie_config%3E> - but reading that page didn't help much.

I found the following thread on this forum: <https://community.atlassian.com/t5/Opsgenie-questions/Alert-notification-template-for-alertmanager-prometheus-to-send/qaq-p/1560666>

but then again when I run that code, I get the following error in the alertmanager container:  
**err="yaml: unmarshal errors:\\n line 10: field priority not found in type config.plain"**   

Below is my alertmanager.yml file:  

global:  
resolve_timeout: 1m  
opsgenie_api_url: 'XXXXXXX'  
opsgenie_api_key: 'XXXXXXX'  
receivers:  
- opsgenie_configs:  
- responders:  
- type: team  
name: "TwigOps"  
priority: '{{ range .Alerts }}{{ if eq .Labels.severity "critical"}}P1{{else if eq .Labels.severity "warning"}}P2{{else if eq .Labels.severity "info"}}P3{{else}}P4{{end}}{{end}}'  
name: opsgenie  
route:  
group_by: \['alertname','service'\]  
receiver: opsgenie  
repeat_interval: 5m

Is there a template file I could download? It seems to me that the above code might be missing some declarations which is why "priority" is not found as a field.

Thanks for your help


Answers:
author: Samir
body: Hi [@Guillaume Bettayeb](/t5/user/viewprofilepage/user-id/4727225) ,

Have you tried it with setting priority as just a value of "P1", "P2", etc.?

I am wondering whether the conditional statements you are using for the priority field is are whats causing the issue.

If you could change it to just a hardcoded priority value of P1, P2, P3, P4, or P5, that would help rule out what's causing the issue with the priority field.

Thanks,

Samir
Opsgenie App with Azure SSO configure Only allows app to open with Microsoft Edge.
Asked by Nathan Donnelson:

Configured Azure SSO Identity Provider, SSO works from PC browser, but when we try to use the IOS/Android App, it tries to open the app in MS Edge? How do you bypass this?


Answers:
author: Connor Eyles
body: Hi Nathan,

Connor here from Opsgenie support!

So if I understand this correctly, you have SSO enabled for your Opsgenie and when you attempt to login via a mobile it is using MS Edge to login?

This could be because the end device has MS edge set as the default web browser. Could you try updating your mobile device default web browser to something different?

Thanks,

Connor

comments: author: Michael Sawyer
body: I am seeing the same problem, Jira \& Confluence mobiles apps login fine. But OpsGenie App wants username and password, it doesn't even have an option to use SSO/Atlassian Access.


author: Michael Sawyer
body: This turned out to be security polices on our AzureAD/AzureSSO side, once we allowed AzureAD and AzureSSO to permit authentication from Atlassian Access, Jira, \& Confluence, we were able to authenticate.   

The requirement for Edge is still there, but that is a choice for security purposes, so we'll create a doc for our users on how to change their default browser to Edge. Then authenticate, and change it back. Not ideal, but the only way we can support users accessing Jira/Confluence via the mobile app.


Tags: cloud
Is it possible to have escalations based on alert priority?
Asked by Rodolfo:

For example:

* Immediately for on-call users in the schedule
* If P1, next on-call user in the schedule if not acknowledged in 5 minutes
* If P2 , next on-call user in the schedule if not acknowledged in 10 minutes
* If P3 , next on-call user in the schedule if not acknowledged in 30 minutes
* If P4, next on-call user in the schedule if not acknowledged in 1 hour
* If P5, next on-call user in the schedule if not acknowledged in 4 hours


Answers:
author: John M
body: Hi Rodolfo,

You can accomplish this by using a combination of routing rules and escalations. You would need to set up one rule for each priority and one escalation for each priority. Then, in each routing rule, set the escalation configured for the corresponding priority:

![p1 routing.jpeg](https://community.atlassian.com/t5/image/serverpage/image-id/179614i88E7F7CF0BEBDBEA/image-size/large?v=v2&px=999 "p1 routing.jpeg")

![p1_esc.jpeg](https://community.atlassian.com/t5/image/serverpage/image-id/179611iB4B1008CF17E1733/image-size/large?v=v2&px=999 "p1_esc.jpeg")![p_escalations.jpeg](https://community.atlassian.com/t5/image/serverpage/image-id/179612i490488F97316DD19/image-size/large?v=v2&px=999 "p_escalations.jpeg")

![p_routing_rules.jpeg](https://community.atlassian.com/t5/image/serverpage/image-id/179615i00BFBE48B2118ED1/image-size/large?v=v2&px=999 "p_routing_rules.jpeg")

comments: author: Rodolfo
body: Thanks [@John M](/t5/user/viewprofilepage/user-id/4625213)!
Heartbeat settings?
Asked by Victor Tobon:

Good morning, I'm starting to use opsgenie and I would like to know if someone can explain to me how to configure the heartbeats since it has become a bit complicated and in the same way seeing tutorials and I have seen that you can create incidents directly from a jira ticket but the option does not appear and it already links instance and activate the corresponding options within Jira but that option does not appear can someone tell me what steps I should follow thanks


Answers:
author: Rodolfo
body: Hi [@Victor Tobon](/t5/user/viewprofilepage/user-id/4424146), regarding Heartbeats, did you take a look at the documentation at the [official documentation](https://support.atlassian.com/opsgenie/docs/add-heartbeats-to-monitor-external-systems/)?

Basically you define a time threshold to receive a heartbeat from your application, if Opsgenie doesn't receive it, it creates an alert.

You can send the heartbeat in different ways, for example with a simple curl command:

```
curl -X PUT 'https://api.opsgenie.com/v2/heartbeats/HeartbeatName/ping' \
--header Authorization: GenieKey eb243592-faa2-4ba2-a551q-1afdf565c889'
```
Incoming call routing on JSM Premium OpsGenie
Asked by Jay McCarogher:

We currently have OpsGenie standalone and Jira Service Management Premium (we got this especially for the unlimited automation rule executions)

Documentation, I can find, tells me that we can do everything we currently do in OpsGenie standalone on the OpsGenie provided by Premium Service Desk. But the only thing it doesn't provide is something that we desperately need the tool to do. Incoming Call Routing.   

Any idea when this will be given to JSM Premium? We really want to get rid of the standalone we have and just use it all through Atlassian


Answers:
author: Brian Higgins
body: Hi [@Jay McCarogher](/t5/user/viewprofilepage/user-id/4611683),

**Welcome to the Atlassian Community!**

What you've uncovered in your research is correct. JSM premium includes ++*almost*++ all of the capabilities of Opsgenie standalone. At this time, I'm not aware of plans to migrate Incoming Call Routing to JSM. However, you may find a solution that works for your use-case with apps on [Marketplace](https://marketplace.atlassian.com/addons/app/jira-service-management) and third party integrations. We also keep an a public roadmap for Jira Service Management (Cloud) [here](https://www.atlassian.com/roadmap/cloud?selectedProduct=jiraService) should it come on the horizon.

I hope that helps clarify!

**Brian Higgins**

*Product Marketing Manager, Jira Service Management \& Opsgenie*

comments: author: Jay McCarogher
body: Thanks Brian, while a little the answer is a little disappointing, I do appreciated the clarity provided here. Thanks for the swift reply.

I guess it's back to the drawing boards for us :)


author: Rudy Holtkamp
body: For anyone stumbling on this question:

You should use a Twilio account for handling the incoming calls in Opsgenie (integrated with JSM). There is a native integration for incoming calls which connects to the Twilio api. See also this [documentation.](https://support.atlassian.com/opsgenie/docs/integrate-incoming-call-routing/)


Tags: cloud

jira-service-management

premium
How do I find the owner of a saved search in opsgenie Alerts
Asked by Neil Benton:

In my alerts page of opsgenie I have a saved search which has been shared with me. Is there a way to identify which user created the saved search ?

I want to go back to the original creator and suggest a change.


Answers:
author: Nick H
body: Hi [@Neil Benton](/t5/user/viewprofilepage/user-id/4388608) ,

Our Saved Search API will show the owner or creator. You'd first want to list all saved searches to grab the saved search ID: <https://docs.opsgenie.com/docs/alert-api-continued#list-saved-searches>

Then run a GET on the specific saved search which will return the owner: <https://docs.opsgenie.com/docs/alert-api-continued#get-saved-search>

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

\^ Returned only shows the owner ID so you could also run a User API on that as well: <https://docs.opsgenie.com/docs/user-api#get-user>

You should also be able to update the saved search using this request: <https://docs.opsgenie.com/docs/alert-api-continued#update-saved-search>

\^ Note that saved searches cannot be updated in the UI at this time, but can be using the API.

comments: author: Neil Benton
body: [@Nick H](/t5/user/viewprofilepage/user-id/2540930) thanks, it worked a treat.


Tags: cloud
On call schedule for large team with Weekly Rotation
Asked by sudeep PATEL_:

Hi,

I have team of 10 persons and want to schedule on-call among team with one primary and one secondary/24 hours for whole year. How can i automate it to uniformly distribute. i do not want to do it manually.

Please advise if feasible in opsgenie?

Regards

Sudeep


Answers:
author: John M
body: Hi Sudeep,

You can first add your primary and secondary teams to their respective rotations and then toggle the "ends on" option and you will be able to select the year you want the rotation to end. This will fill in the calendar with the team schedule for the entire year. ![download.png](https://community.atlassian.com/t5/image/serverpage/image-id/179523i272C3046A6AA8B5D/image-size/large?v=v2&px=999 "download.png")

comments: author: sudeep PATEL_
body: Thank you
Bad Credentials!
Asked by Fight Dounghirun x3443:

The account is a US instance and correct email account.

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

This account is the same login as confluent Atlassian. but it can't log in on Web and Mobile app


Answers:
author: Stefan Draber
body: Hi [@Fight Dounghirun x3443](/t5/user/viewprofilepage/user-id/4723813) , stumbled upon the same issue today. Reason was that my organization reached its limit of 5 free users, so our Admin would have to kick someone else out or switch to another plan.


author: Wei Wung
body: Hi [@Fight Dounghirun x3443](/t5/user/viewprofilepage/user-id/4723813),

From your screenshot, your account is using Opsgenie login.

If you have been using the "Forgot your password" link that you showed in your screenshot to reset your password, and you are still unable to login, kindly open a ticket at support.atlassian.com, if you haven't already done so.

All the best!


author: Pramodh M
body: Hi [@Fight Dounghirun x3443](/t5/user/viewprofilepage/user-id/4723813)

Welcome to the Community!!

The password for Atlassian Stack of Products such as Jira Software, JSM, Confluence, etc are the same but it's not the same for Opsgenie, try resetting the password and logging in again.

Thanks,  
Pramodh

comments: author: Fight Dounghirun x3443
body: I tried to reset PW many times and not work. it still shows Bad Credentials!


author: Yashar Sultanov
body: the same for me


author: Magnificent Linux
body: the same here.

I have create a new Opsgenie account via here:

<https://www.atlassian.com/software/opsgenie/try>

at Aug 05, 2023. It suggest me to install a Opsgenie mobile app. But I couldn't use the same username and password to login the mobile app (app version should be 3.6.9 base on Apple App Store).

I also tried to resetting the password via Opsgenie's mobile app but I can only use the new credential to login web page. I am still stock at the step to login to mobile app.

I believe I have encounter the same issue. Not sure if there is a solution or work around for me on this?


Tags: cloud
How to use projectKey as variable in OEC
Asked by Oalimerko:

Dear all,

i am using opsgenie ,OEC and Python Script for creating some jira issues with some custom jira fields which are not filled by default,the synchronization opsgenie-jira works fine and the jira tickets are created.In order to use the py script i have to define the projectKey within config.json like below:

{  
"apiKey": "",  
"baseUrl": "",  
"logLevel": "DEBUG",  
"globalArgs": \[\],  
"globalFlags": {  
"url": "<https://jira>....",  
"username": "tec-opsgenie",  
"password": "  
"issueTypeName": "Incident",  
"projectKey": "CFORQ"  
},

Now every alert will create a ticket under Q-Queue but since i have different alerts for different projects i want tickets to be created for project specific queue.Let say i have project which is called BMW and another project wich is called Audi.  

How to create BMWA-123 tickets for all BMW alerts and AUDIA-123 for all Audi alerts?Why the projectKey is hardcoded?Hardcoding the projecKey means that i must have different OEC instances for different projects,but what if i have more than 100 projects.


Answers:
author: Samir
body: Hi [@Oalimerko](/t5/user/viewprofilepage/user-id/4664515) ,

Does the alert in Opsgenie contains some field which indicates which project it should get created in? i.e. does the alert contain "BMW" or "Audi" in one of the fields?

If so - you could step conditional logic using if-then statements in your script to set the projectKey based on the value of the field in the alert.

e.g. if-then statements checking if BMW or Audi is in the **message** field of the alert, and setting the projectKey field accordingly

if **BMW** in queue_message.get("message"):

projectKey = "BMW"

elif **Audi** in queue_message.get("message"):

projectKey = "AUDI"

Thanks,

Samir

comments: author: Oalimerko
body: Hi [@Samir](/t5/user/viewprofilepage/user-id/2168284) ,  

yes the description of alerts contains a field which specifies the name of the project.With regex i can pick out the project ,i.e

projectKey = re.search(r"project:\\s\\'(.\*)\['\]",queue_message.get("description"))  

because using if-then for 100 projects it's not realistic.But what will happen with projectKey defined in config.json?


author: Samir
body: [@Oalimerko](/t5/user/viewprofilepage/user-id/4664515) If there are that many projects, then yeah using regex would probably be better than if-then statements.

The projectKey from the config.json should be overridden by whatever the projectKey is set in the script.


Tags: cloud

jira
Incoming Call Voicemail notification - how get voice call?
Asked by Donna Askew:

Hi,

I'm setting up the alerts for Incoming call - in particular we want to be alerted when a voicemail has been left, (the initial call has been missed).

The choices for the Incoming Call notification are to send notification by SMS, the OpsGenie App and email - there isn't the choice to be called again.

Any way to do this?

Thanks in advance!


Answers:
author: Samir
body: Hi [@Donna Askew](/t5/user/viewprofilepage/user-id/1840702) ,

There isn't a way to get voice notifications for incoming call alerts. This is because the voice notification can interfere with the actual live call routing.

We do have a feature request for incoming call alert notifications to include voice as an option, but at this time there isn't a way to get voice notifications for incoming call alerts.

I will add you to that feature request.

Thanks,

Samir

comments: author: Donna Askew
body: We are just trying a different approach, using an alert generated when the incoming call comes in. We are trying to put a condition as the alert activity notes are updated to say when a voicemail is left. Is there anyway to get that so it can be used in the condition? We tried the below, but this didn't appear to work.

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


author: Samir
body: [@Donna Askew](/t5/user/viewprofilepage/user-id/1840702) is that a routing rule you are setting that filter on? Incoming Call Alerts do not follow routing rules like regular alerts do. They follow the "default" (i.e. the "Else") routing rule on the team the alert goes to.


author: Donna Askew
body: Thanks, we are using the default Else and that works for our purposes.


author: Andrew Parker
body: [@Samir](/t5/user/viewprofilepage/user-id/2168284) Can I be added to this feature request?


author: Samir
body: Hi [@Andrew Parker](/t5/user/viewprofilepage/user-id/4873317) ,

Here is a link to the feature request where you can vote for it and watch it

<https://jira.atlassian.com/browse/OPSGENIE-391>

Thanks,

Samir


Tags: cloud
Opsgenie- JIRA integration issue
Asked by Akanksha Kulshrestha:

Hi Team,

I have got this issue whie forwarding the closed alarm at JIRA from Opsgenie:

"Could not send \[resolveIssue\] action to Jira \[JiraSoftware\]. Reason: 400 Bad Request: \[{"errorMessages":\[\],"errors":{"resolution":"Field 'resolution' cannot be set. It is not on the appropriate screen, or unknown."}}\]"

Alert creation is happening well:When alert is created at Opsgenie, an issue wil be created at JIRA.

However when alert is closed at Opsgenie, this will not RESOLVED the closed alert at JIRA.

Can you please advise.

![Conditionsand Filters at Integration.png](https://community.atlassian.com/t5/image/serverpage/image-id/177777i29FDE2022592FA92/image-size/large?v=v2&px=999 "Conditionsand Filters at Integration.png")


Answers:
author: Connor Eyles
body: Hi [@Akanksha Kulshrestha](/t5/user/viewprofilepage/user-id/3807783)

When Opsgenie attempts to close a Jira ticket and this error occurs it can happen for a range of reasons. Let me go over the possible blockers here:

* Can you confirm that the user that is used in the Jira integration in Opsgenie has the permissions to resolve issues in Jira?
  * You can confirm this by logging in as this user and try to resolve the issue.
* Can you check the workflow for this project/issue type, and ensure that the status 'Resolved' exists, and that all statuses can transition into the 'Resolved' status.
* Do you have any required fields that need to be entered before transitioning to the Resolved status?

If you want to be able to share more information around this case you can go ahead and create a support ticket with us to do a deeper investigation via <https://support.atlassian.com/contact/>

Thanks,

Connor

comments: author: Mason Pan
body: Hi, has the issue been solved? (I know the ticket has been awhile). May I know why? I just met the same issue.


author: Mubeen Mohammed
body: Hello [@Mason Pan](/t5/user/viewprofilepage/user-id/2511460)   
This is Mubeen. As mentioned in the previous response by Connor, this specific issue may occur for various reasons. A few options are discussed above, can you please try validating the mentioned options if that is the reason you are facing a "400 Bad Request" error? I will share the details again for visibility.

* Can you confirm that the user that is used in the Jira integration in Opsgenie has the permissions to resolve issues in Jira?
  * You can confirm this by logging in as this user and trying to resolve the issue.
* Can you check the workflow for this project/issue type, and ensure that the status 'Resolved' exists and that all statuses can transition into the 'Resolved' status.
* Do you have any required fields that need to be entered before transitioning to the Resolved status?

In most cases, the issue will be how the Jira Integration and Jira project is configured. If the issue you are facing is not specific to the options discussed then with exact error details you can create a support ticket with us to do a deeper investigation via <https://support.atlassian.com/contact/>

Thank you

Mohammed Mubeen


Tags: cloud

jira-software

jira-software-cloud
I am having two different instances of Opsgenie for the same site
Asked by Emmanuel Ankrah:

I am trying to set up voice call notification for Jira Service Management and we are using incoming call app from the marketplace which is integrated into Opsgenie. The challenge we are facing is that Serbia country code was not initially supported. However when we contacted Jira support team they have fixed that issue. So I tried to set up the Serbia numbers and it worked but later I realised that the integration for incoming call app is not showing. Further checks showed another instance with the incoming call app showing the integration for the incoming call app but, am getting error for adding Serbia numbers. I think the support team fixed the issue on the other instance which don't have the incoming call app integrated in Opsgenie. Further checks reveals that there are two different URL's.

My question how do i get rid on one of the instances?

here are they: <https://same-site-nameog.app.eu.opsgenie.com/settings/>

<https://same-site-nameoe.app.opsgenie.com/settings/user/profile>


Answers:
author: Howard Nedd
body: Hi Emmanuel,

Do you mean that you are using the Incoming Call Routing feature?  
So the integration for Opsgenie?  

Regards,  
Howard

comments: author: Emmanuel Ankrah
body: Yes we are using the Incoming Call Routing feature but, unfortunately it was configured on another Opsgenie Instance.

W have through our checks realised that the Jira Service Management plan we have do do not support Opsgenie with Incoming Call Routing feature. So the initial setup had to subscribe to Opsgenie Standalone version which supports that incoming call routing feature.

We have now gone back to Jira Support to apply the fix of Serbia Country code on the Opsgenie instance which supports the incoming call routing feature. Initially, we were thinking there was problem with the initial setup which resulted in multiple instances of Opsgenie. But now we have established that the Jira Service management plan does not support that integration and thus we needed a standalone Opsgenie plan which supports that feature.

Thanks for your response.


Tags: cloud
Integrating Opsgenie with Slack
Asked by Mahdi Raza:

Is there any way we get customizable alert notification on slack.  

For instance, if there is alert and 4hrs are passed for that, then through integration we get a message on slack channel #abcde tagging the person to whom the alert is assigned  

something like this in #abcde "@XYZ please check OG alert tinyID: 1234"


Answers:
author: John M
body: Hi Mahdi,

As discussed in our chat, currently this functionality does not exist within our Slack integration. However, we did discuss the option of using Zapier to build more robust workflows and notifications between Opsgenie and Slack. We do also currently have a feature enhancement that has been submitted for your request, which I have added your organization as one of the requesting parties.

comments: author: Mahdi Raza
body: Hi John,   

Yes we do discussed this and I've tried Zapier. I posted this earlier when we discussing hoping that someone might have done it through APIs or any simpler way. Thanks for reaching out again and looking forward to that feature enhancement.