The core idea is that we want to move issues that are linked (blocked by) to a new sprint if the sprint of the issue that's blocking it gets moved. All of our sprint have the following common names: 2025-12...2025-52.
So for example:
Issue A (sprint 2025-15) blocks Issue B (sprint 2025-17)
And Issue A is moved to sprint (2025-17) then subsequently, issue B is moved to sprint (2025-19).
I've been able to parse and calculate the DeltaWeeks appropriatly and stored that in a variable. Similarly, I've been able to get the bNewWeek (2025-19) appropriately and stored it in the variable bNewWeek.
Now the problem is that I need to set the sprint through an ID, not the name. I was thus able to send a web request and retrieve all future sprints. My log at this point is:
DeltaWeeks = 1 | bOldSprintName = 2025-23 | bNewWeek = 2025-24
And the web response looks like this:
{id=628, self=https://gradientwiki.atlassian.net/rest/agile/1.0/sprint/628, state=active, name=2025-15, startDate=2025-04-08T13:37:34.000Z, endDate=2025-04-13T21:27:32.000Z, createdDate=2025-02-14T14:46:49.150Z, originBoardId=10},
{id=656, self=https://gradientwiki.atlassian.net/rest/agile/1.0/sprint/656, state=future, name=2025-16, createdDate=2025-03-17T10:11:46.161Z, originBoardId=10}Now, if I hardcode the sprint name as below, I correctly assign the ID to a variable called 'sprintID'
{{#webResponse.body.values}}{{#if(equals(name,"2025-15"))}}{{id}}{{/}}{{/}}
But when I try to add the bNewWeek variable it fails and doesn't return anything.
{{#webResponse.body.values}}{{#if(equals(name,bNewWeek))}}{{id}}{{/}}{{/}}I've tried a million things to make it work and been using an LLM to help me figure it out, but I just can't do it. Would love to get some help.
Thanks,
Stefan