Hello,
Looking for guidance on how to create a filter that will look for issues for the current month through an automation that would create a new filter each month.
Meaning if it runs in January, the filter would look for tickets explicitly created :
created >= 2025-01-01 AND created < 2025-02-01.
The automation is currently set up below, which is not what we want because the filter needs to look specifically for the month it ran and change each month it runs. If I look at the filter today 2/5 that was created in January, it would show results for this month because of the part "createdDate >= startOfMonth()"
How do we do this in the automation?
Hi @Deborah Wong -- Welcome to the Atlassian Community!
You are correct that this expression is the cause of what you are observing:
createdDate >= startOfMonth()
Instead you would use {{now}} and the startOfMonth() and endOfMonth() functions, formatting the results to work with JQL. For example:
createdDate >= {{now.startOfMonth.jiraDate}}
AND createdDate < {{now.endOfMonth.jiraDate}}
Please note well: I recommend not running this rule within 24 hours of the first / last days of the month or time zone impacts could cause problems with the dates selected. Alternatively, the time zone functions could be used to force {{now}} to your own location before using the start / end functions.
Kind regards,
Bill
Yes that worked!!! Thank you!!
Pasting in final results in case anyone needs it.
Filter created now explicitly searches for that month
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello @Deborah Wong
Welcome to the Atlassian community.
Can you tell us more about your use case?
Is the purpose of this rule to get the output of the filter on a schedule, or to create the filter?
What is the purpose of the Send Web Request action?
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.