Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

API REST - How to get subtask list of an issue

Vaclav Jezek October 7, 2013

I need to get list of all subtasks for one given issue. I am using API REST. Is it possible?

3 answers

1 accepted

Comments for this post are closed

Community moderators have prevented the ability to post new answers.

Post a new question

1 vote
Answer accepted
Aleksander Mierzwicki
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 29, 2013

Actually I forgot about one more, simpler solution - use jql (also with /rest/api/2/search): parent = your-issue-key

1 vote
CMV April 15, 2016

Hi! I have a question related from above but I'm using the SDK. I would like to get the Sub-tasks from every issue with a certain project.. Here is my code snippet

 

var issueList = jira.Issues.Where(x=>x.Project == "MYSAMPLEPROJECT");
foreach (var issueItem in issueList)
{
   /*Get the sub-tasks collection of the issue*/ 
}

 

Thank you very much!

 

0 votes
Aleksander Mierzwicki
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
October 7, 2013

Yes it is possible. Use /rest/api/2/search with jql like that: issueKey = your-key AND issuetype in (all-subtask-types-here)

https://docs.atlassian.com/jira/REST/latest/#d2e4074

Vaclav Jezek October 7, 2013

Thanks for your quick response.

TAGS
AUG Leaders

Atlassian Community Events