Hey @wtadmin,
Are you trying to pull every unassigned task in your workspace? If so, that is going to be a lot of data. I recommend narrowing the scope of what you’re trying to pull if possible (e.g. unassigned tasks within a set of projects). Also, make sure to use pagination and be mindful of our various rate limits.
With that said, there are two approaches you could take:
-
Get all of the tasks and then do client-side filtering based on the assignee. You can get all incomplete tasks fairly easily by specifying
completed_since=now
on the tasks query . While you can pass a specifc assignee (e.g.assignee=123456
), the /tasks endpoint doesn’t allow you to filter onassignee.any=null
, so you will need to do that client side. -
Use the search API. For example, you can search for incomplete and unassigned tasks in a workspace like this:
GET /workspaces/123456789/tasks/search?completed=false&assignee.any=null&limit=10
Note that the search endpoint is not designed to get every task in a workspace. The results are not stable, so repeating the same query multiple times may return the data in a different order, even if the data do not change. Because of this, the traditional pagination available elsewhere in the Asana API is not available here. However, you can paginate manually by sorting the search results by their creation time and then modifying each subsequent query to exclude data you have already seen. Page sizes are limited to a maximum of 100 items, and can be specified by the limit
query parameter.