Hi all,
I'm starting to use the next-gen projects, specifically Kanban. Many of the projects I create have similar tasks, so I've created and use CSV imports to populate new projects.
I can't see any way to assign, within the CSV file, a Task to an Epic. This can be done manually in Jira by using the Add to parent functionality, but when a project has 35+ tasks, running through each and every one isn't ideal.
How can I create a CSV that, upon import, links newly created issues to an already created epic?
Thanks
Hello Patrick,
Unfortunately, the mapping of Epics to child issues using CSV import does not work for next-gen projects. We have a reported bug about this behavior here:
- NextGen - CSV Import - Failed to assign Epic as IssueType
Feel free to vote and watch the bug to increase its priority and also receive any updates about its fix implementation.
For now, you can try one of the workarounds available in this bug:
If you want to edit the Epic link for open issues you can use multi-select on the board or the backlog to bulk assign Stories to Epics;
If you want to update issues that are already in "Done" status instead, you can then use the below workaround. However please keep in mind that it is using an internal endpoint not officially documented/supported and this workaround might stop working without prior notice:Send a POST request to the REST API endpoint https://INSTANCE.atlassian.net/rest/internal/simplified/1.0/projects/PROJECT-ID/issues/EPIC-ID/childrenproviding a list of issue-ids in the request body.
Example:
- IDs of the issues to be updated: 10405, 10203
- Project ID: 10303
- Epic ID: 10519
- Curl command to set the Epic (10519) as a parent to the desired issues (10405 ,10203). Please replace all the things in CAPITAL with the proper values:
curl -D- -u EMAIL:API_TOKEN -H "Accept: application/json" -H "Content-Type: application/json" -d '{ "issueIds" : ["ISSUE-ID-1", "ISSUE-ID-2"] }' -X POST https://INSTANCE.atlassian.net/rest/internal/simplified/1.0/projects/PROJECT-ID/issues/EPIC-ID/childrenIn order to get the list of issue-id to update you can:
- Run a search to get the list of issues to update
- Switch to the list view
- Select to display only the issue-key column and export to CSV current columns only. This way you get a CSV file that only contains issue-key and issue-id. You can parse this file in many different ways to just get a coma separated list of issue-ids surrounded by double quotes
For details on how to authenticate REST API calls using API TOKENS please refer to the API tokens documentation page.
Let me know if this information helps.
Hi Peter,
Excellent response, thank you. I wasn't aware that I could select multiple tasks on the Kanban board, but with your information and a bit of playing around, I've found the workaround works perfectly.
Thanks, happy for this to be closed.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You are welcome, Patrick.
Have a nice weekend. :)
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 the referenced bug addresses Patrick's question. He is trying to auto-assign an Epic as a Parent to a Task or Story during csv import.
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.