Add multiple tagas in Asana

Hi There,
in a Scenario, I need to add and remove multiple tags in a Asana task in bulk.

The only way I found to do that is to calculate the lenght of the “tags array”, and repeat the operation once per tag.

This scenario run hundred of times per day and each run use around 7/8 operation only to add/remove tags in Asana.

There is a better way to do this automation reducing the operation needed?

Thanks!

It’s been a while but if I recall correctly Asana’s API needs one request per tag, so although I am sure you could achieve the same thing through HTTP request, it would still require multiple ops. Hopefully someone knows better than me and can help :slight_smile:

1 Like

Hey Mattia,

for some bizarre reason Assana decided to have the endpoint allow one tag at a time and doesn’t accept bulk data.

Usually the way to go through an array is with an Iterator module, not the way you did it. Can you share screenshots of the entire scenario? This way we will get a better overview and see if there are places that can be optimized.

Hi Stoyan thanks! The scenario is really big :slight_smile:

The modules realated to this topic is this:

  1. get variabiles: get the tags value setted in other branches.
  2. router that split the add/remove function
  3. repeater: wher I calculate the number of tags based on a split function.
  4. update asana tags: where I set the add/remove tags.
  5. sleep: to avoid timeouts

I used this way because in the Asana module i need to specify if the tag should be added or removed.

So why not add them or remove them directly when its needed? It looks like you have them separate somewhere, assemble them in a comma separated list and then split the list in an array to process them one by one again.

If you do need to do it your way, you can replace the sleep module with a Break error handler. It will only trigger when a timeout occurs so it will save on some operations at least.

I cannot remove directly because the add/remove is built based on multiple conditions that change based on multiple status.

This was the easiest and clean way to have the final tags ready to be added/removed in Asana.