Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

Opsgenie does not notify slack if there are problems with a Jenkins pipeline

Greetings, I'm integrating Opsgenie with Jenkins from pipelines. I created 2 pipelines with the same code that represents a sample code present in this link:

In the first case use the groovy sandbox to run the pipeline script and in the second case I ran the script from a Jenkinsfile.

Case 1:

Jenkins Pipeline:

Screenshot at Sep 20 15-01-28.png

Jenkins Pipeline Job:

Screenshot at Sep 20 15-03-32.png

Opsgenie notification (via slack):

Screenshot at Sep 20 15-13-55.png

In this case, everything went as it should. I ran the pipeline and gave an error to verify that the failure notification appeared in Opsgenie and is validated.




Screenshot at Sep 20 15-27-55.png

Jenkins Pipeline:

Screenshot at Sep 20 15-28-45.png

Jenkins Pipeline Job:

Screenshot at Sep 20 15-29-51.png
As you can see in the Jenkins pipeline job screenshot, the request for Opsgenie is made. My question or problem is that Opsgenie does not notify slack as it did in the first case, so I would like to have some help here if possible. 

1 answer

1 vote
Justin Sitarz
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Sep 21, 2021

Hi João!


Justin here, from Opsgenie support - happy to help!


There are a few common culprits that can prevent a particular alert from sending out to Slack - it may be that the alert that is created is not assigned to the same team as the Slack integration, or it may be that the Slack integration has some filtering in place that is preventing alerts matching certain criteria from sending outbound. 


For the first - can you check to see that both of these alerts in Opsgenie are assigned to the same team as your Slack integration? You can find the assigned responder teams here on the alert:





You'll want to ensure that this is the same as your Slack integration:





Additionally, you'll want to check if there are any filters here, on the Slack integration, that might be preventing the alert from sending out to Slack:





Those are the most common causes of something like this, but if that doesn't solve the issue, please feel free to respond here, or reach out to us directly at 




Justin S.

Atlassian Cloud Support

Good morning, thanks for the reply. I think I exposed the error incorrectly. The problem isn't in the slack because the alert doesn't reach Opsgenie. What I exposed already worked correctly with the same code by a pipeline script or a pipeline script by scm.


That said, my company only uses scripted pipelines. The code shown above refers to the example of this link :  .This code is declarative and works correctly, the alert is sent to Opsgenie and later to slack. 


But as mentioned above, we only use scripted pipelines and what happens is that when I call the Opsgenie function in this type of pipeline, the output says that the alert is sent but it doesn't reach Opsgenie.


Scripted Pipeline Code:


Screenshot at Sep 22 12-51-49.png


Output of Scripted Pipeline:


Screenshot at Sep 22 12-53-37.png

Supposedly job data is sent to Opsgenie but the alert does not appear in Opsgenie when the command is called within a scripted pipeline.

Is something missing in my code or does Opsgenie only allow in-command invocation in declarative pipelines?


Justin Sitarz
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Sep 22, 2021

Hi João, 


Ah, thanks for the additional information! With that in mind, I *suspect* that the issue has to do with your Opsgenie configuration - it may be that the data is received by Opsgenie, but doesn't match the filter conditions for the rules in the 'Create Alert' action for your integration - see below for a screenshot of where this is found:


Screen Shot 2021-09-22 at 8.43.23 AM.png


The best way to check this is to view the logs (Settings >> Logs), where all incoming requests will be displayed, whether they trigger an alert to be created or not. You can search the logs using the name or ID of the Jenkins integration, and will see all request received by that integration, and can confirm if the specific notification from your scripted pipeline.

You may also want to reach out to us directly at, or through the in-app chat (found in the lower right hand corner of the application - note -i f you don't see the in-app chat option, it may be due to an ad-blocker extension in your browser.)

We may need to gain access to your account to do some additional troubleshooting of the issue, so contacting us directly would be the best way to achieve that. 




Justin S.

Atlassian Cloud Support

Good morning Justin, thanks for your help. I didn't know where I could see the logs and what was happening was that the status always showed up as "Success". So I added this line in my code and it's working correctly.


Screenshot at Sep 23 11-37-58.png

Thanks again for your availability.


Like Steffen Opel _Utoolity_ likes this
Justin Sitarz
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Sep 23, 2021

Hi João, 


Excellent, glad it's working now! Is there anything else we can help with?




Justin S.

Atlassian Cloud Support

I don't think I have any problems for now, thank you so much for your attention.


Like Justin Sitarz likes this

Suggest an answer

Log in or Sign up to answer
AUG Leaders

Atlassian Community Events