Title Remapper
Title Remapper empowers you to programmatically change incident title in real-time for better context.
Last updated
Title Remapper empowers you to programmatically change incident title in real-time for better context.
Last updated
Title Remapper empowers you to programmatically change incident title in real-time for better context. More context in alerts means it's easier and faster for responders to understand the incident better.
Let's take Sentry as an example. The incident title is clear but it will do us as incident responders better if we add the project name. Just makes it tad bit clear.
Without Title remapper
With Title remapper
See the difference? it immediately adds more context. So much nicer to get this additional info especially on phone call and sms alerts.
This was achieved by creating a Title remapper with the code below and simply templating your message from the payload your integration sends.
You can read our detailed blog on how we came about building this feature alongside the decision for HandlebarsJS.
You can write parsing logic using HandlebarsJS syntax and formulate incident titles accordingly. Read more here (it's extremely simple to get started)\
From the Alerts menu, go to title remapper and create a new remapper.
Provide a suitable name and description for your title remapper.
Select an integration for which you want to parse the title.
Once you select an integration, a JSON body will be displayed in the preview section.
This payload is the metadata which we receive from the selected integration. Using this payload, you can now write a custom parser in the code editor provided on the left.
Once you have written the parser, press Try Now
to check if the parser works and if the parsed incident title is meeting your requirements. Hit save to continue.
Avoid #each and #unless or basically all for.. loops
Select all the integrations to be connected with the title remapper.
One Title remapper can be linked to multiple integrations.
Ensure to link a remapper created for, say AWS, to only be linked with other AWS integrations. If not, there could be errors and your title will be missing
If you link multiple Title remappers to an integration, only the last linked remapper will be taken into consideration.
All examples below are showcased with the below payload.
Just the message
output - Notification test message triggered from user <richard>
2. Get event
output - Event Definition Test Title
3. Get mode details about the event
output - [test-dummy-v1] has incident => Event Definition Test Title
You can use in-built helpers provided by Handlebars JS. Alongside, we also support a number of helpful helpers on our own fork of Swag.
output - Message: [testkey] - Notification test message triggered from user <richard>
Output NOTIFICATION TEST MESSAGE TRIGGERED FROM USER <RICHARD> with priority 3
Visit our GitHub repo for more examples of Swag.\