I'm trying to query the Opsgenie python API based on time range but I don't see any API that supports the action.
Hi @Ashok Simma ,
Not a Python expert myself, but this is possible via the alert API using something like Postman - so I have to assume it should be possible with Python as well.
You can query between date ranges. For example if you wanted to pull alerts created in the month of November, you might use something like this:
https://api.opsgenie.com/v2/alerts?query=createdAt>31-10-2022 AND createdAt<01-12-2022
I typically use a site like URL Encoder to help, but not sure what the Python format / query might be. I'm not sure if any of that helps, but again leads me to believe it should be possible.
Hi @Nick Haller thank you for the reply. its working for me
It looks like you're new here. Sign in or register to get started.