GET all tasks and subtasks on a project

I'm trying to get all the tasks and subtasks on a particular project using a GET request in this format:

https://www.wrike.com/api/v4/folders/{folderId}/tasks?descendants=true

where {folderId} is the folder ID of the project.

It's only pulling the top-level tasks and not the subtasks. I'm sure I'm missing something simple but I can't seem to find what it is. What do I need to do to get all the subtasks?

Thanks for the help.

0
6 comentarios
Spot On Innovative Approach Stellar Advice
Avatar

Hi Ryan, welcome to the Community, happy to see you here 🙂

I'm going to raise a Support ticket for you now - the team will be able to advise. You'll get a notification soon 🤝

Lisa Community Team at Wrike Become a Wrike expert with Wrike Discover

0
Acciones de comentarios Permalink
Spot On Innovative Approach Stellar Advice
Avatar

The solution is to use

https://www.wrike.com/api/v4/folders/{folderId}/tasks?subTasks=true

2
Acciones de comentarios Permalink
Spot On Innovative Approach Stellar Advice
Avatar

What is the recommended solution for this? 

0
Acciones de comentarios Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Hi Jim Bradley, welcome to the Community!

Our Advanced Support recommends to include optional parameter "subTasks=true" to your API Tasks query to include Subtasks to the response. You can check the full list of available parameters at https://developers.wrike.com/documentation/api/methods/query-tasks

Hope this helps! 

Lisa Community Team at Wrike Become a Wrike expert with Wrike Discover

0
Acciones de comentarios Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Hi Lisa,

Are there any resources showing these 'optional parameters'? The methods section of the API docs don't even cover the parameter you mentioned.

Thanks!

Daniel 

0
Acciones de comentarios Permalink
Spot On Innovative Approach Stellar Advice
Avatar

Hi Daniel Montoya, welcome to the Community! 

We'll check this and get back to you! 

Lisa Community Team at Wrike Become a Wrike expert with Wrike Discover

1
Acciones de comentarios Permalink

Folllowing List for Post: GET all tasks and subtasks on a project
[this list is visible for admins and agents only]

Didn’t find what you were looking for? Write new post