I use the “sprint” API to create sprints in a board in our Jira Cloud instance:
I create a new sprint by API with the following data :
name: '24.Q2 IT - S1 - OCA',
The sprint is created just below the current active sprint, and not below all others, even if the dates are after:
Doing the same operation using the UI places the new sprint at the end of the list.
Any idea why the UI and API have different behaviors ? How can I change this using the API request ?
I cannot duplicate that issue. When I create sprints using the REST API, the newly created sprints are always at the bottom of the list, in the exact order I create them, irrespective of their start or end dates or their names, exactly the same as the GUI. I cannot find any way to make a sprint created via the REST API suddenly ‘jump up’ the order of sprints in the GUI as you described.
I think that you’ve not taken the human factor into account Unbeknown to you, someone else is just moving the sprint to a different position in the list once it’s created. I suggest you create a dummy board that only you can access and do your testing there.
It’s not an human factor, I create sprints in my team’s board, check them immediately, and no one in the team modify them.
But you’re right it works fine with a newly created board.
My existing sprints were initially created by a plugin on an “onpremise” instance and then migrated to the cloud: maybe that’s why…
I’ll recreate all of them by API, then delete the existing ones. Should work fine.
Thank you for the help