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

On opsgenie, how could I import a list of alert, such as a csv file ?

Gaston Odasso July 8, 2024

 

Good afternoon! I am working on the backup and recovery of all Ospgenie alerts. How can I import all alerts from a csv?

2 answers

1 accepted

1 vote
Answer accepted
John M
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 9, 2024

Hi @Gaston Odasso ,

John from Opsgenie support here, happy to assist. 

We have an import tool but it only imports configurations, not alerts. You would need to write a script to import all alerts from a CSV.

Here is the backup tool:

https://github.com/opsgenie/opsgenie-configuration-backup

Gaston Odasso July 23, 2024

Thanks John! 

Do you have an example script to share with me?

0 votes
Skyler Ataide
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 9, 2024

Hi @Gaston Odasso, are you able to use the Export CSV option available on the Alerts page as shown in the following screenshot: 

Screenshot 2024-07-09 at 4.11.57 PM.png

 

Or, instead are you trying to import a CSV list of alerts into Opsgenie? 

Gaston Odasso July 23, 2024

Hi Skyler!
Thanks for your answer..
I need to do 2 things, export all the alerts to a cvs automatically (to make a backup) and on the other hand, I have to try importing these alerts.

Skyler Ataide
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
July 24, 2024

Hi @Gaston Odasso happy to help! Apart from the Export CSV option shared above, another option here would be to use Alert API to list all alerts. The JSON returned from the API call could then be converted to a CSV. Here is a link to our Alert API documentation: https://docs.opsgenie.com/docs/alert-api#list-alerts 

As far as importing alerts, the only option here would be the import tool that my colleague John linked above, which would require a custom script to import all alerts from a CSV. Our configuration backup tool documentation does not contain an example script for this specific use case, as its primary function is for exporting/importing configurations. 

Like Gaston Odasso likes this

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
STANDARD
TAGS
AUG Leaders

Atlassian Community Events