Extracting comments in bulk for a project or workspace

Hi Asana developers :slight_smile:

Our team is currently building & fine-tuning a new backup app for Asana. To optimize the backup process, we were wondering if it is possible to get comments (a subpart of stories) in bulk for a project or a workspace?

As far as we can tell the only API call is Get stories from a task but this requires us to do 1 API call per task. As some beta users have 200K+ tasks this leads to a huge amount of API calls so we were wondering if there is a short cut possible.

We think it could be done by using Get events on a resource, and then somehow filter on the comment events, but we don’t know how to filter on comments.

Any help is much appreciated!

Thank you :slight_smile:

1 Like

Hey @Willem_Dewulf,

I believe you’re correct. There is currently no way to bulk get stories via the API. I thinkkk an approach that could work is doing an Organization Export, and using it’s data for your backup. You can kick this off from the API at Organization exports.

Events will work, but I suspect this will be the largest chunk of effort. You’ll need to setup a database that tracks all of the data, and use events like PATCHs to the database.

Hope this helps!

2 Likes

Hi Ross,

thanks for highlighting the organization export feature. We offer our backup to Premium and business users too, it’s a pitty that that feature isn’t enabled for them…

Could you maybe check my other comment related question: Total number of comments per tasks . As most likely I’ll need to loop over all tasks, maybe I can be “smart” about it by only looking into tasks that have comments.

And while we are at it, maybe check the Webhooks for comments only thread too? pretty please :wink:

1 Like