I'm working on an alert automation that switches based on the integration the alert was created with.
When I log {{alert.integration}} within a rule I get an object like this:
IntegrationBean{id=[UUID removed as I'm not sure if this is safe to share], type=API, name=Jenkins API Service Desk}
I would like to retrieve just the 'name=' portion of this object, I have tried the following...
{{alert.integration.name}}
{{alert.integration.IntegrationBean.name}}
{{alert.integration.asJsonStringArray}}
{{alert.integration.substringBetween("name=","}")}}
None of these log anything, though the rule succeeds it logs an empty string.
Does anyone know how to acces the individual values in the IntegrationBean object?
Hi @Adam Pearson -- Welcome to the Atlassian Community!
Here are the documented smart values for the {{alert}} with the alert-related rule triggers for JSM: https://support.atlassian.com/cloud-automation/docs/jira-smart-values-alerts/
I hypothesize some of these may be dynamically accessed, and so if you need to use them in more complicated expressions they may need to be saved with Create Variable first.
Kind regards,
Bill
Thanks!
after creating a variable I tried the substringBetween method on the variable instead, and this worked!
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.