Hi,
I'm trying to configure e-mail integration in Opsgenie so it will group all alerts matching some criteria in daily "threads".
In Jira there's a way to use smartvalue {{now.shortDate}} to get today's date. Is there any options to get system to add date in Opsgenie Alias?
Hi @Paweł Grams ,
There are some extra fields not included with the Email integration by default, but specifically parse in the headers of the payload - including the date:
Since it's nested under the headers, you could use something like this to extract it into the alert:
{{_headers.DATE}}
As well use some form of string processing or regex to pull only the date, or fine-tune exactly what you need to extract into the alias or other alert fields.
Hi @Nick Haller
Thank you for this response. It's great I can access headers data as it will improve our ways of working with Opsgenie a lot!
Thank You!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Nick Haller
I am trying to do something similar in my opsgenie setup, I am using the below code to get the date but it's somehow always returning null value. I tried to put it in alias and as well in the description. Any idea how I can make it work? I just want current_date or the date in the alias when the alert was created. Thank you in advance.
{{_headers.DATE}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Taha Husain ,
My suggestion above is only related to the Email integration. Are you using an Email integration, or another integration?
If you are using another integration - then you would need to review the Logs tab to see if there is a date field that can be extracted from the payload.
If yes - then you may want to connect with Opsgenie support for assistance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Nick Haller , sorry I forgot to mention about the integration. I have a AWS SNS integration. Do you have any suggestions for that? Thank you!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I would suggest reviewing the Logs tab to see if the date is parsing in a field or the payload so it can be extracted into the alert.
Typically we see customers leveraging string processing or regex to extract fields / data into alerts.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Nick Haller , I tried using string processing functions as well, for eg please see below code. I am still getting null values. If there's something other than this I can talk to the support.
{{ Timestamp.toDate() }}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You can connect with Opsgenie support for assistance. They will be able to review your instance, logs, etc. - and provide suggestions. It will also prevent you from having to share any information or screenshots here you do not want publicly available.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.