Hi Experts.
We Have JIRA Data center (no cloud). And working on integration to CALM.
But have a problem to sync JIRA Sprint to CALM Timebox.
I'm using automation to sync data. Everything working well excepts fields I've mentioned above.
Sync those two properties I've made this way :
- web request to get list of timeboxes from CALM (there is no API to get only one using the name property)
- get ID using name from response :
- create variable timeboxId using smart value
- but there is a problem
1. when I use fixed name it is working fine :
{{#webhookResponse.body}}{{#if(equals(name, "Sprint 1"))}}{{id}}{{/}}{{/}}
In timeboxId is GUID of the timebox from CALM
2. But when I'm using dynamic variable, it is not working :
{{#webhookResponse.body}}{{#if(equals(name, SprintName))}}{{id}}{{/}}{{/}}
SprintName is variable derived from issue.Sprint.name
In this case timeboxId variable is always empty.
Please, How should I use smart value and enter dynamic value (sprint name). I've tried a lot of expressions, but no one working well.
Or, how should I sync Sprint property in Task (JIRA) with Timebox property in CALM.
Thank You.
Hi @Michal Tvrdý ,
In Jira Data Center automation, variables are not resolved automatically inside string comparisons. That’s why the condition works with a hard-coded value but fails when using a variable.
When you use:
{{#if(equals(name, SprintName))}}
SprintName is treated as plain text, not as a resolved smart value, which results in an empty match.
To make this work, reference the smart value directly in the comparison, for example:
{{#webhookResponse.body}}
{{#if(equals(name, issue.Sprint.name))}}
{{id}}
{{/}}
{{/}}
Alternatively, if you are using a variable, it must be resolved explicitly:
{{#webhookResponse.body}}
{{#if(equals(name, "{{SprintName}}"))}}
{{id}}
{{/}}
{{/}}
Using the original smart value (issue.Sprint.name) is the recommended approach in Data Center, as it avoids variable-scope and resolution issues.
This behavior is expected and is a limitation of how Jira Data Center automation evaluates smart values in conditional expressions.
I've already checked those expressions. But the first one returns no value and the second end with error : String must be closed: "{{SprintName: {{#webhookResponse.body}}{{#if(equals(name, "{{SprintName}}"))}}{{id}}{{/}}{{/}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
There is a long-standing limitation / defect for long-format list iteration syntax:
Once inside a long-format list iterator, only data from that scope and lower can be accessed.
Thus, other smart values in the issue and created variables cannot be used inside. This problem exists in Jira Cloud, Server, and Data Center automation rules. Atlassian knows about this limitation and has tried several times to fix it...without success.
Without seeing your entire rule for context, there are two possible solutions:
Kind regards,
Bill
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.