Is there some way to create a sprint in Jira Automations?
What I want to achieve is:
Sprint 23 gets completed
-> Sprint 24 (already existing) will get the Current Sprint
-> New Sprint (Sprint 25) gets created for the week after Sprint 24.
So we always have two sprints the currently active one and the next one for bugs which have to be done in the next sprint.
Hi @Dennis Kugelmann - You should theoretically be able to accomplish this by using the Send web request Action. Once to GET the current Future Sprint info, then POST to Start the future sprint, and another POST to create a new future sprint. Something like this...
I say "theoretically" because I haven't actually tested it. :) However, I do have a similar "Scheduled" Automation that successfully creates two Future Sprints if none exist.
Anyhow, I hope this helps get you (and others) pointed in the right direction. Cheers!
@Guy Anela Can you share the "Automation that successfully creates two Future Sprints if none exist." I am trying to accomplish this but have errors from my URL.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Pfohl Jason - It sounds like your Web request might not be configured correctly. Can you post a screenshot of it?
Here's an example of what my first web request looks like...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Guy Anela , would you be so kind as to share a similar screenshot of your POST that creates the future sprint. The screenshot above is for the GET and I'm having trouble with the body of my POST (405s and 401s).
My POST conforms to the description here https://community.atlassian.com/t5/Jira-Software-questions/set-up-automation-creating-new-sprint/qaq-p/1929573
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Dave Furlani - Here's the screenshot of the POST configuration. I'm guessing it has something to do with your Authorization Header value...
I hope this helps. Cheers!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You may be right. I had my event with a POST formatted like the above, and I get a 401 error about authentication (with a GET using the same token I get a 405 about the HTTP body).
Error response HTTP body:
{"message":"Client must be authenticated to access this resource.","status-code":401}
I'm getting the API token from here - https://id.atlassian.com/manage-profile/security/api-tokens (for those working through similar automations, this is the correct source). Is there a 3rd party parser I'm meant to use to turn it into Base64?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Sorry, @Dave Furlani , I wasn't as clear as I should have been in my previous post. :)
The BASE64 encoded value should include the username (email), a colon, and the API Token (e.g. user@email.com:3nDt7787879wxyz123).
You can use any BASE64 Encoder. If you encode the above example, you should get...
dXNlckBlbWFpbC5jb206M25EdDc3ODc4Nzl3eHl6MTIz
Here's an example using https://www.base64encode.org/...
That's the value you want to put after the "Basic " in your Web Request Header...
I hope this helps to clarify things. :) Cheers!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Guy Anela you have nothing to apologise for - you have been extremely helpful.
Why Atlassian don't provide/use a key in the format they use/provide, not suggest it's needed and advise to add in the automation email address in the UI is a little frustrating, but I digress.
To that end thread will also be useful to people having the same trouble in future - https://community.atlassian.com/t5/Jira-Service-Management/What-is-the-email-address-of-automation/qaq-p/1791176
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
That said, I'm still getting 401 errors.
I created the Base64 key with the email address A4J sends emails from, colon, the API token I created. I also added the A4J user to the permission scheme with Manage Sprints rights, although "All logged on users" was already there.
I can see that the relevant token seems to be being used and accessed by Jira when the web requests are sent. At least I assume I wouldn't see that it had been accessed if the key wasn't correct, so I assume I converted that key to Base64 correctly. This only updates sometimes regardless of the address used (see next para).
I also tried converting the key with each of the email addresses I've received from Jira in the past, just to cover all the user account bases:
I'm not sure what else to try, so I've provided the full error from the logs below in case that provides some useful context.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey @Dave Furlani - Just to confirm, make sure you're using the email address of the account you used to create the API Token.
Also, make sure you put a colon (:) between the email address and Token before you encode it (e.g. user@email.com:3nDt7787879wxyz123). ...nevermind, re-read your response and saw that you did that already. :)
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.
I don't think this will be possible using Automation for Jira.
This is because actions within Automation are project and issue-based. Sprints are neither, these are board-based and can apply to one or multiple projects.
If you were to "create" new sprints via Automation for Jira it would need to be possible to create them from the field itself on an issue, which is not possible - the field is just a representation of all the sprints created on boards.
You'd need to consider whether this is possible via the API or a scripting app instead (but it's not something I've come across before, I'm afraid).
Ste
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.