When I receive results from the JIRA REST API that include issues with subtasks, the returned subtask objects only contain the issuetype, priority, status, and summary fields like this:
{
issues: [{
key: ...,
fields: {
summary: ...,
subtasks: [{
key: ...,
fields: {
issuetype: ...,
priority: ...,
status: ...,
summary: ...
}
}]
}
}]
}
Is it possible for the API to return the duedate field for subtasks as well or do I need to make a subsequent request to see additional fields?
Probably you reach info from parent where in normal view screen you get only some fields. Sub tasks are like normal issues, but maybe it would be better to read and gather sub-tasks keys from a parent and later get info like normal issue using those keys. Then you should get all info including due date (if this field is used in sub-task)
Thank you. So to confirm, the JIRA REST API doesn't have a method to request additional fields in subtasks, i.e. an "expand" option?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
No, it's the opposite. Jira considers sub-tasks to be issues in the same way as their parents, barring the sub-task part (which can be simplified down to "they must have a parent issue"). The expand option in the REST API works the same for sub-tasks, because they're still issues in their own right.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the feedback.
I'm specifically referring to the issue objects contained within the "subtasks" field of a parent issue. These subtask objects only contain the issuetype, priority, status, and summary fields. Is there an expand option that will returns more fields beyond these for subtask objects?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
No, because you're looking at a parent issue, not the subtasks, when you use that. The four fields includede are a convenience to help out a couple of the dashboard gadgets. If you want more, you need to read the sub-tasks.
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.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.